# Tag Info

5

If you are willing to live under the constraint that all matrix elements occupy the same width (though your question implies that such a constraint may actually be a desirable requirement), then this \sqmatrix[alignment]{content} macro will do the "squaring" automatically. Inter-element spacing (default 0pt) may be specified with \setstacktabbedgap{length}. ...

11


3

Note that $$...$$ shouldn't be used in LaTeX, see Why is $...$ preferable to $$...$$?; also a4wide is a deprecated package. If you want to widen the text area, use geometry. You can obtain what you want with blkarray: \documentclass[12pt]{article} \usepackage{amsmath,blkarray} \begin{document} \[ \begin{blockarray}{cc} \begin{block}{(c@{\rlap{,}}c)} ...

3


7

Here I do it with stacks, setting the indices below the boxes. The primary macro is \matbox{rows}{columns}{row index}{column index}{matrix name}. A helper macro is \raiserows, which is like a \raisebox, except that the "length" is specified in rows, not actual length. Note that in the MWE, because X has 7 rows, while P^T only has 2 rows, P^T must be ...

2

This is one possible solution via amsmath package. Code \documentclass[12pt]{article} \usepackage[margin=1cm,paper size={20cm,5cm}]{geometry} \usepackage{amsmath,amssymb} \thispagestyle{empty} \begin{document} \[ {\begin{pmatrix} & & \\ & X &\\ & & \end{pmatrix} \mkern-10mu}_{I \times J}= {\begin{pmatrix} ...

2

Please always post complete documents which generate the error. In particular it allows you to check that the fragment you are posting does in fact generate an error. The fragment in your question does not generate an error, also the error messages are not complete TeX error messages. However I would guess your real document os something like this, which ...

Top 50 recent answers are included