Questions tagged [fractions]

This tag is for questions regarding the display of fractions and related problems.

Filter by
Sorted by
Tagged with
3
votes
1answer
57 views

Extra vertical space in fraction

If I compile this: \documentclass[12pt]{article} \usepackage{amsmath} \begin{document} \[\left\lvert\frac{\displaystyle\int_0^1\frac{\sin t}t\,\mathrm dt}C\right\rvert\] \end{document} what ...
3
votes
3answers
307 views

Index in fraction in exponent in fraction looks wonky

I'm trying to write \[ \frac{1}{1+e^{\frac{\varepsilon-\mu}{k_B T}}} \] but it looks really wonky. In particular the B in the subscript is just as big as everything else. I've seen this written in a ...
0
votes
0answers
50 views

Using amsmath package in elsarticle preprint

I am trying to add a fraction to my manuscript. I am using the elsarticle preprint template. Below you can find the important parts of the preamble. When I put \usepackage{amsmath} directly below \...
0
votes
0answers
30 views

Fraction in siunitx [duplicate]

Some time ago (last year) I had the following code working without errors \documentclass[12pt,a4paper]{article} \usepackage{siunitx} \begin{document} If we have \SI{2/3}{\mole} the reaction \ldots \...
1
vote
1answer
39 views

Ugly fractions including exponents in superscript

Consider typesetting the following expression in LaTeX: \[ a^{\frac{\mathrm{e}^{\lambda x}}{1-\mathrm{e}^{\lambda x}}} \] The output is as follows: This looks quite ugly. I think the issue is that ...
0
votes
2answers
52 views

Vertically align text with display style fraction bar in array environment

I'm typesetting a subsection of exercises using array environment. However, the vertical centers of exercise numbers do not align with the display style fraction bars (see the following figure). Other ...
2
votes
3answers
67 views

How to have a fractional environment number

For kind of a gag, i want to have a theorem with a fractional number. It is perfectly fine if i have to give the number specifically. However, i do not want to define a new environment for this, since ...
0
votes
1answer
36 views

Proper Maths way to write nested fractions

My question concerns more the Maths field rather then the LaTeX one ... in fact it's about writing mathematical equations correctly. I was looking for a way to be able to write a fraction nested in ...
0
votes
0answers
38 views

Problem with displaying brackets in fractions

I need display fraction with multiple levels and brackets in some levels. If i use standart left, right constructions, i have ugly fraction. I have a lot of empty place in brackets. Below you see ...
3
votes
2answers
74 views

Write text next to fractions

I would like to write some text next to fractions with many floors, but I don't know how to do it right. Here is an example of what I want to do: In the red circle, I want to write something like ...
3
votes
1answer
32 views

In Lyx, is there a way to force global use of \cfrac instead of \frac?

I'm currently typing a document with a lot of equations with complex fractions. Is it possible to set the document to use \cfrac instead of \frac everywhere? I'm using Lyx's equation editor so it ...
1
vote
1answer
32 views

Keep summation sign in fraction

In Overleaf, I have the following formula: \[ \frac{sum_{1}^{d_i} P(W_i|T_k) }{sum_{1}^{k}sum_{1}^{d_i} P(W_i|T_k)}\] Which looks as follows: However, instead of the word sum in the numerator and ...
12
votes
4answers
606 views

In math mode, how do I make the fraction bar “invisible”?

I am trying to typeset a "fraction" without the fraction bar. I have tried to do this using the genfrac, but as in the example below, the numerator and denominator in genfrac are farther ...
6
votes
2answers
307 views

Mirrored Cube Rooted Fraction Looks Weird

I was testing something with Overleaf, and then a weird result was output. What's more weird is that I went to a Discord server where a TeX-rendering engine exists. This is its result: It's a really ...
1
vote
2answers
69 views

Problem with doing an equation on LateX

I attached the equation I need to obtain the only change I have is that I am using p and q instead of x and y. Here is what I have done but when I compile I am not obtaining the required equation. \...
2
votes
2answers
42 views

How to make a division line a bit longer than normal?

\documentclass[preview,border=12pt,12pt]{standalone} \usepackage{mathtools} \begin{document} $ \displaystyle \begin{aligned} -\frac{3x}{10} &= 6 \\ -\frac{3}{10}x &= 6\\ x &...
0
votes
2answers
111 views

Mixed number with slanted fraction

I wanted to use some mixed numbers with slanted fraction in my text, so I used \sfrac or \nicefrac, as recommended by S. Kottwitz. \documentclass{article} \usepackage{amsmath} \usepackage{xfrac} \...
2
votes
3answers
78 views

How to fix an ugly fraction with exponent?

Here's a simple fraction that I find extremely ugly. What could I do to get a better looking result (without using a negative exponent) ? \documentclass[11pt,letterpaper,twoside]{book} \usepackage[T1]...
0
votes
1answer
38 views

Align in a fraction, arbitrary part of denominator with part of the numerator

I am trying to align the bottom part of a "fraction" with the top part, but since I am new to this, I am not sure the right way. The goal is for the q in the "denominator" to line ...
4
votes
1answer
62 views

Polynomial long division with fractions

\documentclass{article} \usepackage{amsmath} \begin{document} \begin{align*} &&&&&&&&&&&&&&x&&+&&\frac{x^3}{3}&&+&&...
2
votes
2answers
52 views

Big floor brackets size around fraction with small denominator

i'm having issues with bracket formatting around fractions. For example, this code : \documentclass{article} \usepackage{mathtools} \DeclarePairedDelimiter\floor{\lfloor}{\rfloor} \begin{document} ...
1
vote
1answer
99 views

Typeset a fraction without the fraction bar

I would like to typeset a fraction without the fraction bar. In the following MWE, I try to do this using substack command from the mathtools package. But, as you can see in the output, the spacing is ...
4
votes
4answers
221 views

Arrays with non-inline style formulas in rows in KaTeX

I'm having a hard time trying to get a properly aligned inequations involving fractions in KaTeX. The best output I have got is with the array environment: \begin{array}{crccclc} z\in\Bbb R^+, & 0 ...
2
votes
1answer
74 views

How does \over work?

I don't mean this necessarily in the sense of diving into code, but \over seems to function differently to other commands, which scoop up only following arguments. Instead, 11\over2 gobbles up the ...
1
vote
1answer
24 views

Issue with fraction multiplication, everything being considered as being the denominator

I am working in the Overleaf IDE, and simply trying to write down some fraction multiplications. As a simple example, let's consider the expression to be (a/b)(c/d). Within my \begin{displaymath} ...
3
votes
1answer
36 views

Selective coloration of polynomial parts of rational expressions

I'm teaching high school students how to simplify rational expressions by cancelling factors. The cancelled expressions should be colored red (incl. L /R parenthesis), but not the fraction bar. The ...
3
votes
1answer
44 views

Added whitespace when putting brackets around fractions with splitfrac

I'm using splitfrac from mathtools to break up a particularly long line in the numerator of a fraction. When I put brackets around the fraction, however, they leave a line of whitespace in the ...
2
votes
0answers
51 views

More aesthetic norms, absolute values, parentheses, etc

This is nothing too important, and I've decided to make all three questions into one because they are more or less related. Sometimes when I type math equations, I find them not as beautiful as I ...
1
vote
1answer
34 views

Shifted fractions representing refutational computation trees in LaTeX

I would like to draw a deduction tree in the fractional form shown in the picture, unfortunately I had no luck with frac and over and I was not able to find better images in the literature.  &...
0
votes
2answers
59 views

How to prevent bleeding with fractions in solution environment

I'm generating math worksheets dynamically with pyLaTeX, and stumbled upon a weird behaviour that I don't quite find how to correct. I have a code that puts all the answers for an exercise into a ...
4
votes
3answers
459 views

fraction inside fraction

While using \frac gives me smaller characters, \cfrac almost get what I want, except there is quite large space above the denumerator. I follow this but right now without the $\displaystyle$ because I ...
1
vote
1answer
81 views

Why is a simple fraction not displaying properly? [closed]

This should be pretty basic, but I can't work out what I'm doing wrong here. I'm trying to just write a = 1/6 with the fraction displayed the normal way, 1 over 6. I've tried both a = \frac{1}{6} and ...
5
votes
2answers
503 views

Reason of variation in sizes of fractions?

\sqrt{1 + \left( \tfrac{\partial z}{\partial x} \right)^2 + \left(\tfrac{\partial z}{\partial y} \right)^2} The code above resulted in the second fraction being bigger than the first. Why?
3
votes
2answers
138 views

\cramped in fraction denominator doesn’t line up with regular fraction

In a display, the denominator of a fraction is set in “cramped” \textstyle, which can be emulated with \cramped[\textstyle]{...} from the mathtools package. But sometimes the emulation is perfect, ...
1
vote
1answer
74 views

Why fraction spacing changes and how to get uniform spacing?

I noticed the space between \frac{}{} changes depending on where it shows up in the expression. And also depending on font used. Why does this happen? It does not look very good. Here is an example, ...
3
votes
4answers
260 views

Line spacing in table without using booktabs

I'm having a problem with a table I'm trying to do. This is the code I currently have : \documentclass[12pt,letterpaper,french]{extarticle} \usepackage[margin=.75in]{geometry} \renewcommand{\l}{\left}...
0
votes
1answer
48 views

Problem with numerator on a fraction

When i write the following line of code: $\frac{$\alpha_{n}$}{2}$ = $\frac{\pi}{n}$ , It displays me this: What can I do do have the numerator above the line ? when I remove the "n" index ...
2
votes
3answers
74 views

How to put the numerator in same size as denominator while using brackets [closed]

I would like to know how to put the numerator of a fraction of the same size or at least proportional to the denominator when I use square brackets and fractions, as in the following example: \begin{...
1
vote
1answer
36 views

Size of fractions and spaces in arrays

I have the following code: \documentclass[12pt]{article} \usepackage{amsmath} \begin{document} $$\hat{x}_n(t)=\left\{ \begin{array}{cc} 1 & -1\leq t \leq -\frac{1}{n+1} \\ -(n+1) t &...
1
vote
0answers
73 views

! File ended while scanning use of \frac

I did not change anything since last time, but I am getting the error message: ! File ended while scanning use of \frac Btw I am a total noob when it comes to LATEX! I've already checked the questions ...
3
votes
1answer
42 views

Increase and decrease horizontal overline and the vertical distance

If I have this MWE, \documentclass[12pt]{article} \usepackage{amsmath,amssymb} \begin{document} \[\overline{\left(\frac{a}{b}\right)}\] \end{document} it is possible increase (without to use a rule-...
0
votes
0answers
70 views

How to display overline above a fraction?

I'd like to add a bar / overline above a fractional statement, such as the one in this image: I am using tasks package and this inside a \subparagraph inside a \paragraph.I have tried in some manners:...
5
votes
2answers
127 views

How to add space between variables and fraction lines

In this \documentclass[12pt,a4paper]{article} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage[ngerman]{babel} \usepackage{amsmath} \usepackage{amsfonts} \usepackage{amssymb} \begin{...
5
votes
5answers
1k views

How to reduce the number “0” size to fit fraction “1/2”?

\documentclass{article} \usepackage{amsmath} \usepackage{array} \usepackage{mathtools} \begin{document} \renewcommand{\arraystretch}{1.2} \newcommand{\minus}{\scalebox{0.4}[1.0]{$-$}} \[ \begin{...
1
vote
2answers
35 views

equation environment and large fractions

Hello i am currently using the equation environment and trying to "prettily" write down the probability distribution function of the chi-distribution (https://en.wikipedia.org/wiki/...
9
votes
2answers
670 views

Combinatorial notation (\choose) not working with \frac

I want to display the following $p_N= \frac{{200 \choose 11}{ 200 \choose {N-189}}}{200 \choose N}$ However, texmaker gives me this error: Does anybody know why is that? I have tried replacing the ...
4
votes
2answers
211 views

How to type a formula as below? [duplicate]

The plus operator is not center aligned. Please help.
4
votes
1answer
285 views

Minus sign and fraction line perfectly aligned

The minus sign and the fraction line aren't perfectly aligned, probably due to the presence of brackets. So I've found a way to make them be, using \parbox \documentclass[12pt]{article} \usepackage{...
1
vote
2answers
63 views

Make all fraction bars have the same lenght in a set of equations

I am a begginer at LaTex Bassically i want every fraction bar to have the same lenght as the natural lenght of the biggest one I dont know if it would be better to use other command instead of ...
2
votes
2answers
408 views

How to split this into two lines

This is my code: \begin{equation} \text{Diluted EPS}=\frac{\text{Net Income}}{\text{Weighted average number of shares outstanding + New common shares that would have been issued at conversion}} \end{...

1
2 3 4 5
10