How do I write an integral from a to b in latex?

In summary, the conversation discusses how to write an integral and provides tips on using LaTeX to create integrals with subscripts and superscripts. It also mentions a helpful website for learning more about LaTeX and how to use it to create mathematical expressions.
  • #1
phosgene
146
1
As the title suggests, I can only see how to write an integral like:

f295b3970fadc2992246787a7ca45c16.png


But how would I write an integral like the following?

1845918e723ad0b5874fa2fb77870925.png
 
Physics news on Phys.org
  • #2
phosgene said:
As the title suggests, I can only see how to write an integral like:

f295b3970fadc2992246787a7ca45c16.png


But how would I write an integral like the following?

1845918e723ad0b5874fa2fb77870925.png
Put a subscript and a superscript on the \int, e.g. \int_{a}^{b}
 
  • #3
Oh, argh! Why didn't I think of that? Anyway, thanks :)
 
  • #6
Also, if you see an example of what you want to do, just right click on it and select to show math as Tex commands to see the code. You can copy/paste from that.
 
  • #7
phosgene said:
As the title suggests, I can only see how to write an integral like:

f295b3970fadc2992246787a7ca45c16.png


But how would I write an integral like the following?

1845918e723ad0b5874fa2fb77870925.png

how do i make the size and font look like that iwth latex? is that latex or a link to an image?
 
  • #8
whatlifeforme said:
how do i make the size and font look like that iwth latex? is that latex or a link to an image?

It's just an image.
 
  • #9
Here's the actual LaTeX for phosgene's two integrals:

$$F = \int {f(x) dx}$$

$$\int_a^b {f(x) dx}$$

The right-click trick should work on those. Or control-click if you're using a Mac, like I am.
 
  • #10
phosgene said:
As the title suggests, I can only see how to write an integral like:

f295b3970fadc2992246787a7ca45c16.png


But how would I write an integral like the following?

1845918e723ad0b5874fa2fb77870925.png

AlephZero said:
Put a subscript and a superscript on the \int, e.g. \int_{a}^{b}

As long as the subscripts/superscripts are single characters, as in the above, you can omit the braces around the sub-/superscript. The following will render exactly the same:
\int_a^b

When there are two or more characters (e.g. 2x, -3, etc.) you need the braces around the entire expression, as in this example:
\int_{-2}^{3x}
 
  • #11
jtbell said:
Here's the actual LaTeX for phosgene's two integrals:

$$F = \int {f(x) dx}$$

$$\int_a^b {f(x) dx}$$

The right-click trick should work on those. Or control-click if you're using a Mac, like I am.

mine looks smaller for some reason.

[itex]\int_a^b {f(x) dx}[/itex]
 
  • #12
tex [tex] \int_a^b {f(x) dx}[/tex]

itex [itex] \int_a^b {f(x) dx}[/itex]

itex with \displaystyle [itex] \displaystyle\int_a^b {f(x) dx}[/itex]
 

Related to How do I write an integral from a to b in latex?

1. How do I write an integral from a to b in Latex?

To write an integral from a to b in Latex, use the command \int_a^b. This will create an integral symbol with the limits a and b displayed below and above the symbol, respectively.

2. Can I change the limits of integration in Latex?

Yes, you can change the limits of integration in Latex by specifying the new limits after the command \int. For example, \int_c^d will display the integral symbol with the limits c and d.

3. How can I add a function to the integrand in Latex?

To add a function to the integrand in Latex, use the command \int_a^b f(x) dx, where f(x) is the function you want to integrate and dx is the differential element. This will display the function inside the integral symbol with the limits a and b.

4. Is there a way to add multiple integrals in Latex?

Yes, you can add multiple integrals in Latex by using nested \int commands. For example, \iint_a^b \int_c^d f(x,y) dy dx will display a double integral with the limits a and b for the outer integral and c and d for the inner integral.

5. How can I add different types of brackets around the limits in Latex?

To add different types of brackets around the limits in Latex, you can use the \left and \right commands before and after the limits. For example, \int_{\left[a\right]}^{\left\{b\right\}} f(x) dx will display the limits a and b within square brackets and curly brackets, respectively.

Similar threads

  • MATLAB, Maple, Mathematica, LaTeX
Replies
3
Views
882
  • MATLAB, Maple, Mathematica, LaTeX
Replies
12
Views
354
  • MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
5
Views
430
  • MATLAB, Maple, Mathematica, LaTeX
Replies
12
Views
821
  • MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
964
  • MATLAB, Maple, Mathematica, LaTeX
Replies
3
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
3
Views
1K
Back
Top