Math & Scienceflalign - localy ignore tabs

Information and discussion about LaTeX's math and science related features (e.g. formulas, graphs).
Post Reply
elvard
Posts: 2
Joined: Sun May 15, 2011 11:46 am

flalign - localy ignore tabs

Post by elvard »

Hi there,
i'm using flalign environment to typeset definitions of variables with text comments. After definitions, there is one long formula without text.

The problem is, I have layout:

Code: Select all

varible & definition && comment \\
...
result & very long formula which span over whole line \\
As the formula is very long, it stretchs tabs and comments are typeset outside the page. I solve it using \rlap{$formula$}, but it looks awful:)

Is there any better solutions?

Example:

Code: Select all

\begin{flalign*}
	s_k   &= \SI{0.7}{\kilo\pascal} && \text{\ldots pro oblast Plzeň} \\
	C_e   &= \SI{1.0}{} && \text{\ldots typ krajiny normální - stavba výrazně převyšuje ostatní stavby}\\
	C_t   &= \SI{1.0}{} && \text{\ldots prostup tepla pláštěm je zanedbán} \\
	\mu_i &= \SI{0.8}{} && \text{\ldots sklon střechy je zanedbán}
	\smskip
	s     &= \rlap{$\mu_i\, C_e\, C_t\, s_k = 0,8 \cdot 1 \cdot 1 \cdot 0,7 =
		\SI{0.56}{\kilo\pascal}$} &
\end{flalign*}

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

Stefan Kottwitz
Site Admin
Posts: 10345
Joined: Mon Mar 10, 2008 9:44 pm

Re: flalign - localy ignore tabs

Post by Stefan Kottwitz »

Hi elvard,

welcome to the board!

You could use two environments, also regarding that the lines have a different meaning.

\rlap would be a solution, like you did. Perhaps you could use \displaystyle within. Also, \mathrlap from the mathtools package would be an option.

Stefan
LaTeX.org admin
elvard
Posts: 2
Joined: Sun May 15, 2011 11:46 am

Re: flalign - localy ignore tabs

Post by elvard »

Hello Stefan,
I don't want to use two environments simply because of aligment of the equal sign (=). It looks better, if it's aligned.

Thanks for \mathrlap, good to know about it.

Well, I suppose, \(*)rlap looks like solution...
Post Reply