5

Hi I was wondering how to resize matrices in a beamer environment. Currently I am writing the following code:

\begin{align*}
\left( \begin{array}{ccccccc}
 0 & 1 &    &   &        &    &   \\
-1 & 0 &    &   &        &    &   \\
   &   &  0 & 1 &        &    &   \\
   &   & -1 & 0 &        &    &   \\
   &   &    &   & \ddots &    &   \\
   &   &    &   &        & 0  & 1 \\
   &   &    &   &        & -1 & 0
\end{array} \right)
\end{align*}

and the matrix takes up almost a whole page. I would like it to be about half a page in height.

Rob Hyndman
  • 30,301
  • 7
  • 73
  • 85
John Jiang
  • 53
  • 1
  • 1
  • 3
  • Thanks for the readability editing! – John Jiang Apr 28 '10 at 05:58
  • 1
    This isn't what you want to hear, but don't forget that text on a slide needs to be bigger than you expect -- you may not be able to shrink it as much as you want and maintain legibility. – Etaoin Apr 28 '10 at 06:57

2 Answers2

7

There is the \resizebox command in the graphicx package:

\resizebox{.5\textwidth}{!}{  (your array here)  }

I've never tried it, but it looks as it is made exactly for this kind or problem.

Of course, you can choose different widths (first argument) or different height (second argument) parameters.

topskip
  • 16,207
  • 15
  • 67
  • 99
1

See this answer for how to change font dimensions in LaTeX's math mode.

Edit

Specifying font sizes in beamer is no different from specifying them in other LaTeX documents. To e.g. change the size of your array you would switch the size by adding the command inside your align environment.

Valid commands are \tiny, \scriptsize, \footnotesize, \small, \normalsize, \large, \Large, \huge, and \Huge (there could be more).

Community
  • 1
  • 1
Benjamin Bannier
  • 55,163
  • 11
  • 60
  • 80
  • That doesn't apply to Beamer, I think. Beamer uses its own font sizes (AFAIK), and if you try to use one of the sizes in the answer you linked, the results would be rather too small. – ShreevatsaR Apr 28 '10 at 06:06
  • I think you are right that these sizing commands work the same as in general latex docs. But I didn't know how to use them in latex before either :-) – John Jiang Apr 28 '10 at 08:30