Send As SMS

3/31/2006

insert a matlab matrix into latex automatically

manually writing out matlab matrices in latex is really tedious. here's how to save yourself the time:

assume you have some matrix L

>> s = sym(L);
>> v = vpa(s,5); # assign numerical precision
>> latex(v)
matlab should now spit out the latex source code that you can directly copy into your .tex file.


0 Comments:

Post a Comment

Links to this post:

Create a Link

<< Home

My blog has moved! Redirecting...

You should be automatically redirected. If not, visit http://stinkpot.afraid.org:8080/tricks/ and update your bookmarks.