Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Scale an equation to fit exact page width

Tags:

latex

I have an equation that is only a tiny bit too wide for one line. I'd really like to avoid having the equation number on the next line. How do you achieve this? Currently I'm using \small, but this is overkill.

Please note. I have tried scalebox and fittowidth but get errors about missing \endgroup. I have also used \! to its full extent. I am hoping for a solution that will allow me to scale the proper one-line equation to the width of the page.

Here is an example (not my actual equation): Long equation

like image 242
Geoff Avatar asked Jun 24 '10 00:06

Geoff


People also ask

How do you fit an equation in latex?

Another option is to use \resizebox . This will automatically shrink the size of the equation to make it fit.

How do I change the size of an equation in latex?

Just put \small before the equation and \normalsize after it if you want to shrink the font, but it's usually better to use an ams multi-line equation environment than to change font size.

How do you fit long equations in overleaf?

Displaying long equations For equations longer than a line use the multline environment. Insert a double backslash to set a point for the equation to be broken. The first part will be aligned to the left and the second part will be displayed in the next line and aligned to the right.


1 Answers

\begin{equation} \resizebox{.9\hsize}{!}{$A+B+C+D+E+F+G+H+I+J+K+L+M+N+O+P+Q+R+S+T+U+V+W+X+Y+Z$} \end{equation} 

or

\begin{equation} \resizebox{.8\hsize}{!}{$A+B+C+D+E+F+G+H+I+J+K+L+M+N+O+P+Q+R+S+T+U+V+W+X+Y+Z$} \end{equation} 
like image 158
Alexey Malistov Avatar answered Sep 22 '22 13:09

Alexey Malistov