So much I'm missing the Emacs power when I (have to) stay inside Mathematica editor. I saw a few mathematicas-mode, but they are all outdated... Any suggestions?
Related
When I plot a figure and type greek letter in the title, it looks like
However, when I save the figure as EPS output, the eps file looks like
It's obviously that the Greek letter \xi_p disappears.
Anyone who knows what happened and solutions, please give me a reply.
It would be much grateful.
Best regards,
mike
First I would like to thank KiW for the help.
I found a solution that works with my MATLAB 2014b.
Solution by specifying the interpreter directly in the code
We can set the interpreter-property directly to latex when calling xlabel or title as shamalaima pointed out in a comment:
xlabel('$\xi_{\textrm{p}}$','Interpreter','latex');
title('$\xi_{\textrm{p}}$','Interpreter','latex');
Solution using the property editor
Another way to do it is by using the property editor as follows:
After making the figure, click the white arrow and click the title (or label).
In the Property Editor, change the Interpreter to latex.
After this, choose the Axes. We can now find the title editor in the left bottom side. Just write the title as you do in latex.
Mine would be $\xi_{_\textrm{p}}=1e$-$4a_{_\textrm{ho}}$ in the font of Times New Roman.
It works now in my EPS output.
Using EPS Viewer the symbol is not lost. As you can see in the picture that works perfectly fine. I used:
plot(x,y)
title('\xi _{P}=1e-4a _{ho}')
So I assume it could be a problem of the program you use to open your .EPS file
I think that the best solution is to set the latex interpreter as default:
set(0,'defaulttextinterpreter','latex')
but of course it depends case by case.
I want to include a script English letter, say \mathscr{T} in the Y-axis label in a Matlab figure. Is there an easy way to do this? Thank you.
Matlab's LaTeX interpreter doesn't seem to recognize \mathscr. But it accepts \mathcal:
ylabel('$\mathcal{T}$','Interpreter','LaTeX','Fontsize',12)
In Emacs I use preview-latex quite heavily for math equations. When I use fill-paragraph command to balance out the words in a paragraph however, I see that Emacs balances according to the LaTeX commands themselves, not images that represent the equations. For example I might have a long command that looks like $\bar{\theta_1},\bar{\theta_2}$ that translate into two characters on the screen. If these commands appear near the middle of a line, fill-paragraph would cut off the line and move the rest to the next, which makes the cut-off line look very short. Is there any way to change this so that fill-paragraph and preview-latex work well together?
Thanks,
In my figure I have a text annotation using the LaTeX interpreter, and it doesn't recognize \checkmark because MATLAB doesn't have the amsmath package.
Are there any ideas for a workaround? Perhaps I can have part of the text box interpreted with LaTeX, and part of it without? In that case I could use this solution.
it's not pretty, but might be good enough:
xlabel('$\surd$','interpreter','latex')
or look here for other things that look like a tick
http://detexify.kirelabs.org
I used once a very nice emacs function that set all my windows (emacs windows, not frames) width evenly.
If you open emacs and do C-x 3 twice in a row, you get three vertical windows. Then running the function I am looking for makes the width of these windows the same.
I can't for the life of me find this function again.
Wouldn't someone help me to:
find the name of the function
give me the keyboard shortcut if any
tell me what I should have done to find the answer by myself
Thanks!
You're looking for M-x balance-windows.