[comp.text.tex] Formulas in captions

BRONWEN@SBCCVM.BITNET (Bronwen Heuer) (04/17/91)

I am helping a user who is using LaTeX and has a lot of mathematical
characters in his captions.   Regardless of how many `protects' he
inserts, there are some characters that will always bomb, eg. square
root, cube root and two mathematical characters (curly brackets, etc)
abutting  each  other.
 
Has anyone figured out a way around this fragile environment?
Somethings will still crack even if you manually edit the LOF file.
 
Any suggestions?
 
bronwen heuer                        ECC-117        phone(516)632-8054
user services/computing srv, state university of ny     bronwen@sbccvm
stony brook, ny 11794-2640                     bronwen@ccvm.sunysb.edu

dfr@usna.NAVY.MIL (Prof. David F. Rogers) (04/18/91)

In article <3B22F630B801102A@Post-Office.UH.EDU> BRONWEN@SBCCVM.BITNET (Bronwen Heuer) writes:
!I am helping a user who is using LaTeX and has a lot of mathematical
!characters in his captions.   Regardless of how many `protects' he
!inserts, there are some characters that will always bomb, eg. square
!root, cube root and two mathematical characters (curly brackets, etc)
!abutting  each  other.
! 
!Has anyone figured out a way around this fragile environment?
!Somethings will still crack even if you manually edit the LOF file.
! 
!Any suggestions?

Yes, use Plain TeX! Works fine. LaTeX is way to fragile for real work.

Dave Rogers

anita@brahms.udel.edu (Anita Marie Hoover) (04/19/91)

In article <3B22F630B801102A@Post-Office.UH.EDU> BRONWEN@SBCCVM.BITNET (Bronwen Heuer) writes:
=>I am helping a user who is using LaTeX and has a lot of mathematical
=>characters in his captions.   Regardless of how many `protects' he
=>inserts, there are some characters that will always bomb, eg. square
=>root, cube root and two mathematical characters (curly brackets, etc)
=>abutting  each  other.
=>Has anyone figured out a way around this fragile environment?
=>Somethings will still crack even if you manually edit the LOF file.
=> 
=>Any suggestions?


Well my understanding is that any fragile command that is used as
an argument to another command must be protected.  If you get
an error and are unsure what should be protected -- look up the
command and go to its explaination in Appendix C.  There is
will say whether or not a command is fragile and must be protected
when used as an argument to another command (like caption).
Here is an example that works.

---------------------------------
\documentstyle [12pt] {report}
\begin{document}

\listoffigures

\chapter{Testing Math in Captions}
\begin{figure}
\caption{Testing with $\protect\sqrt[3]{2}\cdot\protect\sqrt{5}$
as mathematics $z = \left\{\frac{x}{y}\right.$}
\end{figure}

\begin{figure}
\caption{More Testing with $\protect\sqrt[3]{2}\cdot\protect\sqrt{5}$
as mathematics $z = \left\{\frac{x}{y}\right.$}
\end{figure}

\begin{figure}
\caption{More Testing with $\protect\sqrt[3]{2}\cdot\protect\sqrt{5}$
as mathematics $z = \left\{\frac{x}{y}\right.$}
\end{figure}
\end{document}
--------------------------------

If I didn't cover a specific problem let me know.

anita