[OS X TeX] Fractional symbols

Manfred Braun manfred.braun at uni-due.de
Thu Sep 1 17:20:01 EDT 2016


Knuth suggests the following macro (The TeXBook, Exercise 11.6): 

\def\fract#1/#2{\leavevmode\kern.1em
  \raise.5ex\hbox{\the\scriptfont0$#1$}\kern-.15em/\kern-.15em
  \lower.25ex\hbox{\the\scriptfont0$#2$}}

It allows to write  \fract 1/2.  This is not exactly what you want, but it is the TeX solution. It allows also to write  \fract 13/5, if needed, and this you will not find on your keyboard.

Manfred

> On 02 Sep 2016, at 00:00, R Martinez <rm.tech at mac.com> wrote:
> 
> All,
> 
> I want to write text in my LaTeX document that includes a fraction, e.g., 3 1/2, but I want to replace the three-character 1/2 with the single character ½. As you can see, I can do it using the Mac keyboard with Mac documents such as this email. I tried inserting it in my LaTeX document but it did not typeset correctly.
> 
> I am using the STIX font package. I have scoured the zillion STIX characters but cannot find ½ with a LaTeX backslash command. 
> 
> The STIX reference document I am using is "The stix package" STI Pub Companies v1.1.1-latex from 2014/07/31. I have attached it to this email. 
> 
> The character  ½ appears in the ts1-stixgeneral table on p. 29 of the STIX reference with coordinates
> 
> 	  ′5
> ′27x |  ½  | ″Bx
>           ″D
> 
> 
> I don’t know how to access this. 
> 
> Does anyone know how to insert a fraction in the text?  
> 
> Thanks for your help.
> 
> Raul Martinez
> 
> <stix.pdf>
> ----------- Please Consult the Following Before Posting -----------
> TeX FAQ: http://www.tex.ac.uk/faq
> List Reminders and Etiquette: https://www.esm.psu.edu/~gray/tex/
> List Archives: http://dir.gmane.org/gmane.comp.tex.macosx
>                https://email.esm.psu.edu/pipermail/macosx-tex/
> TeX on Mac OS X Website: http://mactex-wiki.tug.org/
> List Info: https://email.esm.psu.edu/mailman/listinfo/macosx-tex

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://email.esm.psu.edu/pipermail/macosx-tex/attachments/20160902/f54bc8e1/attachment.html>


More information about the MacOSX-TeX mailing list