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.
To write a fraction, you use the code \frac{expression in the numerator}{expression in the denominator} . Formulas that appear in text are called inline. Inline formulas are sometimes squashed to avoid altering the height of the lines.
It is also possible to put the equation into the brackets and then use the \middle/ instead of the regular slash. Or if you do not need any visible brackets, you may use the "fake" brackets instead: \left. \int \limits_{a}^{b} \frac{x}{y} \middle/ \int \limits_c^d \frac{x}{y} \right.
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.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With