Fwd: Re: Re: Typing special symbols in text mode?

*To*: mathgroup at smc.vnet.net*Subject*: [mg65492] Fwd: Re: [mg65479] Re: Typing special symbols in text mode?*From*: Paul Abbott <paul at physics.uwa.edu.au>*Date*: Wed, 5 Apr 2006 06:55:34 -0400 (EDT)*Sender*: owner-wri-mathgroup at wolfram.com

Christopher Arthur <pannoniara at aol.com> wrote: >We should note that there is a slight bug with this approach: even >if you inline a simple equation like 3+5x=f(x), then it doesn't get >placed into math environment in LaTeX. For some reason, I guess the >converter only converts to math mode those expressions that >obviously need special formatting, like fractions or subscripts. It >turns out to be a problem because then these simple functions don't >look right in the DVI or final product of your TeX. I agree that this is a problem. For example, here is a cell with an inline equation: Cell[TextData[{"This is an inline equation, ", Cell[BoxData[ FormBox[ RowBox[{ RowBox[{"3", "+", RowBox[{"5", "x"}]}], "=", RowBox[{"f", "(", "x", ")"}]}], TraditionalForm]]], "."}], "Text"] Pasting this into a Notebook and converting to TeX via File | Save As Special... | TeX generates a .tex document with the following line: This is an inline equation, 3+5x=f(x). >The only way that I've figured out how to go around it is to fool >the converter first by placing a framebox around all such >problematic inline cells, then do a global edit of the fbox that is >created in the TeX output. Note that Publicon <http://www.wolfram.com/products/publicon/index.html> gets it right, generating This is an inline equation, $3+5x=f(x)$. Regarding the original question, I was assuming that Rex Eastbourne wanted to use Mathematica Notebooks to produce problem sheets, rather than wanting to convert these Notebooks to TeX. Cheers, Paul >----- Original Message ----- From: "Paul Abbott" <paul at physics.uwa.edu.au> To: mathgroup at smc.vnet.net >Subject: [mg65492] [mg65479] Re: Typing special symbols in text mode? > >>In article <e0llsk$797$1 at smc.vnet.net>, >>"Rex Eastbourne" < > wrote: >> >>>I'm writing a problem set and would like to use special mathematical >>>notation such as vector arrows, the special R for reals, subscripts and >>>superscripts, and so on (both in equations and in English regular text >>>comments). This would be easy to do in LaTeX, but can it be done in >>>Mathematica? (I know about the "export to TeX" feature, but it would be >>>nice not to have to go back and change notation after exporting to >>>TeX.) >> >>This is easy to do in Mathematica. See >> >> Edit | Expression Input >> >>and in particular the items Above, Subscript, and Superscript. The items >> >> Start Inline Cell >> >>and >> >> End Inline Cell >> >>are used for inline equations within text. I always put mathematical >>expressions in inline cells (a la $x$ in LaTeX). >> >>Note that if you write some text into a text cell and then type a >>variable, say x, and then use, say, the Superscript menu item (or its >>keyboard shortcut, indicated in the menu), an inline cell is created >>automatically. >> >>Advantages of Mathematica for typesetting include: >> >>[1] it is WYSIWYG >>[2] you can use the Mathematica kernel to evaluate expressions appearing >>in inline cells and in equations -- anywhere, in fact. >>[3] it has the extra advantage of being meaningful mathematics. >> >>For example, instead of entering a double-struck R to denote reals, if >>you type Reals into an input cell and convert it to TraditionalForm it >>displays as a double-struck R -- but carries meaning with it (via a >>TagBox as Function[{}, Reals]). This symbol can be used (at least in >>TraditionalForm) within commands such as Reduce and Resolve. >> >>If you paste the following cell expression into Mathematica, you will >>see an example of Mathematica's typesetting: >> >>Cell[TextData[{"Here is some text containing special mathematical >>notation such as vector arrows, ", >>Cell[BoxData[FormBox[OverscriptBox["a", "\[RightVector]"], >> TraditionalForm]]], ", the special R for reals, ", >> Cell[BoxData[ FormBox[ TagBox["\[DoubleStruckCapitalR]", >> Function[{}, Reals]], TraditionalForm]]], ", subscripts ", >>Cell[BoxData[ FormBox[ SubscriptBox["a", "i"], TraditionalForm]]], >> " and superscripts, ", Cell[BoxData[ FormBox[ >> SuperscriptBox["b", "j"], TraditionalForm]]], "."}], "Text"] >> >>Cheers, >>Paul >> >>_______________________________________________________________________ >>Paul Abbott Phone: 61 8 6488 2734 >>School of Physics, M013 Fax: +61 8 6488 1014 >>The University of Western Australia (CRICOS Provider No 00126G) >>AUSTRALIA http://physics.uwa.edu.au/~paul