Math & ScienceDraw a box around two aligned equations

Information and discussion about LaTeX's math and science related features (e.g. formulas, graphs).
Post Reply
bsb233
Posts: 5
Joined: Thu Nov 27, 2008 11:31 pm

Draw a box around two aligned equations

Post by bsb233 »

Dear Community,

I am using the amsmath package, and am working in its align environment, viz

Code: Select all

\begin{align*}
H_T^0(G,Z) &= Z/|G|Z \\ \\
H_T^1(G,Z) &=  0.
\end{align*}
I wish to draw a box around both of these equations - i have tried \boxed{...}, which doesn't seem to work for arrays, and looked at the amsmath manual, which makes no mention of this.

Any comments would be welcome,

Barinder

Recommended reading 2024:

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

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

localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Draw a box around two aligned equations

Post by localghost »

Take a look at the empheq package from the mh bundle.


Best regards and welcome to the board
Thorsten¹
bsb233
Posts: 5
Joined: Thu Nov 27, 2008 11:31 pm

Re: Draw a box around two aligned equations

Post by bsb233 »

Hi localghost,

Thanks for your reply. I've got hold of the mh package, but TeXnicCenter requires empheq.sty, and I only have empheq.dtx.

How can I generate the sty file from the dtx file? I'm still rather new to LaTeX.

Many thanks,

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

Draw a box around two aligned equations

Post by Stefan Kottwitz »

Hi Barinder,

have a look into the dtx file, there are instructions at the beginning:

Code: Select all

% Unpacking:
%    (a) If empheq.ins is present:
%           tex empheq.ins
%    (b) Without empheq.ins:
%           tex empheq.dtx
%    (c) If you insist on using LaTeX
%           latex \let\install=y\input{empheq.dtx}
%        (quote the arguments according to the demands of your shell)
Stefan
LaTeX.org admin
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Draw a box around two aligned equations

Post by localghost »

bsb233 wrote:[...] I've got hold of the mh package, but TeXnicCenter requires empheq.sty, and I only have empheq.dtx.

How can I generate the sty file from the dtx file? I'm still rather new to LaTeX. [...]
It's much easier to install the package (or bundle respectively) with the package manager of your LaTeX distribution. You don't have to generate it manually. If you want to do so, see the post of Stefan.
Post Reply