Math & ScienceChange apostrophe character in math mode

Information and discussion about LaTeX's math and science related features (e.g. formulas, graphs).
Post Reply
sgotcb
Posts: 1
Joined: Thu May 07, 2009 11:12 am

Change apostrophe character in math mode

Post by sgotcb »

Dear,

I am using the classicthesis package. It sets by default the Palatino fonts in normal mode and the Euler font for maths. That looks _great_. However, apostrophes ( ' ) are very similar to commas ( , ) and it causes some confusion in case commas and apostrophes are mixed and there are apostrophes in a subindex and so on.

I had a wonderful idea (although hard core typographers will like to kill me) that is to replace the apostrophe character in math mode, so that it looks like the (very different) apostrophe in the default math font.

Is there any way to redefine the apostrophe character?

I achieved the best results (so far) using this filthy trick:

\DeclareSymbolFont{mycmr} {U}{cmr}{m}{n}
\DeclareMathSymbol{'}{\mathalpha}{mycmr}{"27}

However, in case I have an apostrophe and a subindex in the same character, the subindex is aligned right after the apostrophe (and thus a bit far from the character).

Any help will be greatly appreciated,

Best regards,
Sergio

Recommended reading 2024:

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

Learn LaTeX easily with newest books:

The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis

The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more

LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis

Post Reply