LaTeX forum ⇒ Graphics, Figures & TablesMatrix exported from matlab is too wide Topic is solved

Information and discussion about graphics, figures & tables in LaTeX documents.
ciema7
Posts: 6
Joined: Sat Nov 10, 2018 2:31 am

Matrix exported from matlab is too wide

Postby ciema7 » Sun Nov 11, 2018 12:53 am

Hello Friends,

I have some problems with my matrix (12x12) exported from MATLAB. It's too wide. I have only code from MATLAB. Is there any possibility to adjust matrix size to my page size ? I attach picture with my too big matrix from PDF file and the matrix code from MATLAB:
  1. $\left(\begin{array}{cccccccccccc} 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0\\ 0 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0\\ 0 & 0 & \frac{1671153339071845}{1073741824} & \frac{2055353511997015}{4294967296} & -\frac{269758378125}{2097152} & 0 & -\frac{1189696292006337}{4294967296} & \frac{2599810130852047}{4294967296} & -\frac{2936489563481043}{4294967296} & -\frac{1699791507824531}{2147483648} & 0 & 0\\ 0 & 0 & \frac{2055353511997015}{4294967296} & \frac{650019116160445}{134217728} & \frac{912289096875}{2097152} & 0 & \frac{2599810130852047}{4294967296} & -\frac{5681292580211669}{4294967296} & -\frac{1699791507824531}{2147483648} & -\frac{7871415464245139}{8589934592} & 0 & 0\\ 0 & 0 & -\frac{269758378125}{2097152} & \frac{912289096875}{2097152} & \frac{3443443378604069}{2147483648} & 0 & 0 & 0 & -\frac{3167210799404069}{2147483648} & \frac{3687495141785513}{8589934592} & 0 & 0\\ 0 & 0 & 0 & 0 & 0 & 1 & 0 & 0 & 0 & 0 & 0 & 0\\ 0 & 0 & -\frac{1189696292006337}{4294967296} & \frac{2599810130852047}{4294967296} & 0 & 0 & \frac{1721732332442765}{536870912} & -\frac{3564322313582629}{2147483648} & -\frac{3288402253125}{2097152} & \frac{29296471875}{131072} & -\frac{2325066192018903}{68719476736} & \frac{247160269585745}{1073741824}\\ 0 & 0 & \frac{2599810130852047}{4294967296} & -\frac{5681292580211669}{4294967296} & 0 & 0 & -\frac{3564322313582629}{2147483648} & \frac{6855664687416803}{2147483648} & \frac{29296471875}{131072} & -\frac{261003125}{8192} & \frac{247160269585745}{1073741824} & -\frac{6726079008965945}{4294967296}\\ 0 & 0 & -\frac{2936489563481043}{4294967296} & -\frac{1699791507824531}{2147483648} & -\frac{3167210799404069}{2147483648} & 0 & -\frac{3288402253125}{2097152} & \frac{29296471875}{131072} & \frac{4977792359666131}{1073741824} & \frac{999752201175799}{1073741824} & -\frac{1952805230987671}{2147483648} & -\frac{6806320300693781}{8589934592}\\ 0 & 0 & -\frac{1699791507824531}{2147483648} & -\frac{7871415464245139}{8589934592} & \frac{3687495141785513}{8589934592} & 0 & \frac{29296471875}{131072} & -\frac{261003125}{8192} & \frac{7998017609406393}{8589934592} & \frac{3787276868542221}{2147483648} & -\frac{3403160150346891}{4294967296} & -\frac{5930698476801751}{8589934592}\\ 0 & 0 & 0 & 0 & 0 & 0 & -\frac{2325066192018903}{68719476736} & \frac{247160269585745}{1073741824} & -\frac{1952805230987671}{2147483648} & -\frac{6806320300693781}{8589934592} & \frac{8101854197953047}{8589934592} & \frac{4829038144007821}{8589934592}\\ 0 & 0 & 0 & 0 & 0 & 0 & \frac{247160269585745}{1073741824} & -\frac{6726079008965945}{4294967296} & -\frac{3403160150346891}{4294967296} & -\frac{5930698476801751}{8589934592} & \frac{2414519072003911}{4294967296} & \frac{2422857061841705}{1073741824} \end{array}\right)$
Attachments
matrix.png
matrix.png (47.42 KiB) Viewed 139 times

User avatar
Johannes_B
Site Moderator
Posts: 3883
Joined: Thu Nov 01, 2012 4:08 pm

Postby Johannes_B » Sun Nov 11, 2018 8:21 am

Alright, i did the proper markup for your code. Turns out, Matlab exports only one single line (might have been a copy/paste thing though).

This is a classical case of elephant in a suitcase. It just doesn't fit. I would normally recommend to either decrease font size, or increase paper size, or split the material ... Not in your case. I don't know the science behind it or what it describes, but the matrix right now looks nearly impossible to read to me. All those big fractions.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.

ciema7
Posts: 6
Joined: Sat Nov 10, 2018 2:31 am

Postby ciema7 » Mon Nov 12, 2018 11:56 am

Thank You very much Johannes_B - I've decreased my matrix size, spacing between rows and columns and it works now.

JonathanHall
Posts: 2
Joined: Sat Nov 17, 2018 12:31 pm

Postby JonathanHall » Sat Nov 17, 2018 12:44 pm

Thank you very much. I had the same problem, but everything was safely resolved. Solved a problem for this site https://writingpeak.co.uk/homework-help-online. Therefore, problems should not be.


Return to “Graphics, Figures & Tables”

Who is online

Users browsing this forum: Bing [Bot] and 8 guests