Document ClassesMetric (TFM) file not found. (stmary)

Information and discussion about specific document classes and how to create your own document classes.
phi
Posts: 577
Joined: Tue Oct 21, 2008 8:10 pm

Metric (TFM) file not found. (stmary)

Post by phi »

I have some hints regarding your PhysNote file:
  • If it is supposed to be used like a package, then turn it into a package so that you can benefit from the LaTeX support for packages (options, versioning, preventing double inclusion...). This is very easy, see the clsguide file.
  • You could use siunitx instead of siunits. Then you get all benefits of siunits, plus much more, for example the ability to use exponential notation in the usual ASCII way: \SI{1.23e4}{\meter\per\second}.
  • Contrary to your description, changing the \delimitershortfall actually works, but only for delimiters. ( and ) aren't delimiters but simple symbols that are placed without any special treatment. \left( and \right) are "real" delimiters. Try \left( \left( a \right) \right).
  • It is generally not a good idea to simply redefine text-mode commands like \c or \d. Other packages could rely on their standard meaning, and packages like hyperref overwrite them anyway. To be able to use one-letter commands properly, you have to go a bit further: Load the package fixltx2e and distinguish between math and text mode using \TextOrMath:

    Code: Select all

    \renewcommand*\c{\TextOrMath\caccent\mathundertilde}\newcommand*\mathundertilde[1]{\underaccent{\tilde}{#1}}
    . If you want these changes to survive hyperref, you have to perform them at the beginning of the document or after loading hyperref.
  • Don't just save meanings with \let, it doesn't check if you overwrite something. (For example, you overwrite the existing \SS command, which can lead to unexpected behaviour, try \MakeUppercase{\ss}.) Test for existing command names with an empty \newcommand.
  • Output error messages with \PackageError, not by typesetting them.
  • You cannot use \verb inside an argument, nowhere. Using illegal parameter values in \acoord and so on produces a bunch of silly error messages because of that. Try this: $\acoord[2]{2}$.
  • Why do you start using \providecommand instead of \newcommand somewhere in the middle? \providecommand is intended for cases where at some point it is unknown whether a command was defined and a definition has to be available in every case, but without overwriting a potential previous definition. In packages, this is usually not the case.
  • \ifinner is unreliable because it doesn't take the right branch in most amsmath environments. Furthermore, it's unnecessary because \frac already distinguishes between inline and display mode. Compare:

    Code: Select all

    $\od12 \qquad \frac{\d1}{\d2}$
    \[ \od12 \qquad \frac{\d1}{\d2} \] \begin{gather*} \od12 \qquad \frac{\d1}{\d2} \end{gather*}
  • You don't have to use constructions like \left< #2 \vphantom{#3} \right| \left. #3 \vphantom{#2} \right> because e-TeX provides the \middle primitive: \left<#2\middle|#3\right>
  • Use \DeclareMathOperator to declare functions like \asint to get the spacing right. Compare: $2\sin(1) \quad 2\asint12$
  • Please don't rename internal commands like \sp, this inevitably leads to package clashes.
  • Include the bm package and then use \bm for "better" bold symbols.
Last edited by cgnieder on Sat Sep 07, 2013 10:35 am, edited 1 time in total.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

pstallinga
Posts: 1
Joined: Thu Sep 05, 2013 11:48 am

Re: Metric (TFM) file not found. (stmary)

Post by pstallinga »

I had the same problem (Ubuntu 13.04, TeXmaker). Managed to sovle it with going to Synaptic Package Manager and install texlive-fonts-recommended
Post Reply