Stack Overflow is a community of 4.7 million programmers, just like you, helping each other.

Join them; it only takes a minute:

Sign up
Join the Stack Overflow community to:
  1. Ask programming questions
  2. Answer and help your peers
  3. Get recognized for your expertise

Is it possible to force latex to use the slash notation for a fraction (i.e., separating the numerator and denominator with a slash instead of stacking them on top of one another)? Just using a slash (/) instead of \frac looks bad because the slash does not size itself properly.

share|improve this question
up vote 12 down vote accepted

Here is a command that might work for you:

\newcommand{\slfrac}[2]{\left.#1\middle/#2\right.}

It sizes the slash based on the size of the numerator and denominator.

share|improve this answer

Try the nicefrac package

share|improve this answer
    
Thanks for the reply... this is close to what I want, but shrinks large symbols unnecessarily (everything becomes small enough so that the slash looks reasonable). Occasionally \frac uses the slash even in display mode, and when it does, large symbols stay the same but the slash grows to accommodate them. Is there a way to force it to always use the slash for a given fraction? – Dan Sep 17 '09 at 3:52

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.