# How would I find the area of a function over a specific interval? [closed]

How would I find the area of a function over a specific interval?

For example: $g(x) = e^{5x}$

Find the area of the function over the interval $[-4, 2]$.

• What does "find the area of the function" mean? Do you mean find the area between the graph of g and the x-axis? In which case, Integrate[g[x], {x, -4, 2}]. But on the face of it, this doesn't seem like a question about the computing software Mathematica. – march Apr 3 '16 at 17:25
• Use Integration on function and then apply limits. – Jagadeesh Gudla Apr 3 '16 at 17:26
• Welcome to Mathematica.SE. Are you sure you are posting on the right site? There is nothing in your question making it clear that it is concerned with Mathematica software. – m_goldberg Apr 3 '16 at 17:54
• The question is not clear, I am fairly certain that it means between the curve and the x-axis. I tried to input Integrate[g[x], {x, -4, 2}], however, I got the output of (-1+e^30)/(5e^20) which doesn't seem to be the correct answer – Nick S. Apr 3 '16 at 18:20
• @NickS. Looks right to me wolframalpha.com/input/?i=integrate+e%5e(5x)+from+-4+to+2 – Jason B. Apr 3 '16 at 18:33

I think you mean you want to calculate the area between a function and the x-axis.

Define the function :

g[x_] := E^(5 x)


Show the area between the function and x-axis over the interval [−4,2] :

Plot[g[x], {x, -4, 2}, PlotRange -> Full, Filling -> Axis, FillingStyle -> Yellow] With the knowledge of Calculus, the area can be computed with the following expression:

area = Integrate[g[x], {x, -4, 2}]


And the result is: $$\frac{e^{30}-1}{5 e^{20}}$$

Numeric result:

 N@Integrate[g[x], {x, 1, 5}]

1.4401*10^10


The question is not clear, I am fairly certain that it means between the curve and the x-axis. I tried to input Integrate[g[x], {x, -4, 2}], however, I got the output of (-1+e^30)/(5e^20) which doesn't seem to be the correct answer – @Nick S.

That maybe the correct answer for the particular problem, however, when I try Integrate[f[x], {x, 1, 5}] I get the output of ((1/5)e^5)(-1+e^20) which I know is incorrect. The answer should come out to be 76/3. – @Nick S.

However, from the plot of the function, the area do be a large number. Maybe either your standard answer or the expression of question is incorrect.

• That should be E instead of e, no? – J. M. will be back soon Apr 4 '16 at 2:06
• @J.M. I will correct the answer. – PureLine Apr 4 '16 at 2:07