I want to achieve the following effect in a new enviornment I'm defining where the stuff inside what's supposed to be delimeters is a \begin{aligned} \end{aligned} block.


                  /    math math math math math     (outside aligned)|               \lor            |
                 \     math math                 /

This is all straightforward except I want to center the \lor inside the aligned equations, i.e., center it between the two delimiters. How do I do this in a macro (no hand setting alignment characters)?

Do I need to make the \lor a middle delimiter or something? Note sometimes the outside delimiters may need to be invisible if not absent entirely but \lor should still be centered inside the aligned environment.


I'm not totally positive, but are you looking for something like this? alt text


        \rlap{\hbox to\wd0{\hfill$\m@th#1\lor$\hfill}}%
\text{(outside aligned)}

The \addlor macro takes an optional first argument that can be one of \displaystyle, \textstyle, \scriptstyle, or \scriptscriptstyle. Without the optional argument, it just uses the surrounding style.

  • That's great but could you explain a bit what is going on with the \setbox0 and \wd0 stuff since I kinda need to know what is going on so I can take it apart and modify stuff for my own macros. – Peter Gerdes Jan 2 '11 at 22:40
  • 1
    @Peter: Sure. \setbox0 is putting the following box (which I construct with \hbox) into box register 0. The \hbox to\wd0 is constructing an \hbox that has the same width as box 0 (that's what \wd0 means). So what's going on is the \begin{aligned} ... \end{aligned} is going into box 0, then I measure the width, create a new box of that width, center \lor in it, and then overlap that with \box0. – TH. Jan 3 '11 at 0:04

I do not understand what exactly should be in the new environment.



\text{(outside aligned)}
        f(x) &= g(x)+h(x)\\
        f(x) &= x

alt text

  • I think the text "outside aligned" is supposed to be, well, outside the align environment. – Tyson Williams Jan 18 '14 at 22:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.