LaTeX forum ⇒ Math & ScienceLinear Programs Alignment Topic is solved

Information and discussion about LaTeX's math and science related features (e.g. formulas, graphs).
Posts: 10
Joined: Tue Aug 16, 2011 12:19 pm

Linear Programs Alignment

Postby GommaFleX » Fri Mar 30, 2012 9:43 am

Hi all.

I'm trying to align an maximization program. I searched everywhere but nothing seems work. I want to have something like this (I use '_' because space is not displayed on this forum):


I use \begin{align}
but i keep getting something like this:
or this:
________max_________ f(x)
This is the code I'm using:
  1. \begin{align}
  2. \max_{\mathcal{V}_{\Theta}^{*},\delta}
  3. &\mathcal{V}_{\Theta}^{*}
  4. \notag \\
  5. \text{s.t.}
  6. &\mathcal{V}_{\Theta}^{*} \leq \mathcal{V}_{\Theta}(\delta,\sigma_{\Psi})
  7. &\forall \sigma_{\Psi} \in \Sigma_{\Psi} \\
  8. &\sum_{\sigma_{\Theta} \in \Sigma_{\Theta}}{\delta(\sigma_{\Theta})}=1\\
  9. &\delta(\sigma_{\Theta}) \in[0,1]
  10. &\forall \sigma_{\Theta} \in \Sigma_{\Theta}
  11. \end{align}

Can somebody help me, please?

User avatar
Stefan Kottwitz
Site Admin
Posts: 9572
Joined: Mon Mar 10, 2008 9:44 pm

Postby Stefan Kottwitz » Fri Mar 30, 2012 5:35 pm


it's not completely clear what alignment do you mean. Perhaps post a screenshot where you shifted some elements to the desired position, with a simple graphics program, if it's hard to explain.

Note that align works with rl columns, which means one column is right aligned, the next one left aligned. More columns can be used, which works like rlrlrl. Sometimes it's good to align at several places. For this, use the alignat environment, described in the amsmath manual. This environment doesn't produce so much space between aligned columns.

For complicated constructions, which is not really aligning at relation symbols, perhaps use an {array} environment.

Stefan admin

Posts: 10
Joined: Tue Aug 16, 2011 12:19 pm

Postby GommaFleX » Sun Apr 01, 2012 9:08 am

Thank you, I resolved using "\begin{aligned}". The strange thing was that sometimes it aligned columns on left and other times on the right. But surfing the web I found that even columns are aligned to left and odd columns to right.

Return to “Math & Science”

Who is online

Users browsing this forum: No registered users and 3 guests