Message Boards Message Boards

0
|
9755 Views
|
4 Replies
|
4 Total Likes
View groups...
Share
Share this post:

[?] Integrate a given symbolic limit of integration?

Posted 6 years ago

Hi, I am new to Mathematica. Please advise how I can obtain the symbolic result of the following integral, where n is a positive integer and a is a real number. Thank you.

enter image description here

POSTED BY: Aidan Droogan
4 Replies
Posted 6 years ago

Thank you very much for your help, now solved. I had placed the assumptions inside the Integrate command [ ] and was getting the error message "Invalid integration variable or limit(s) in n "is a member of" Z". This error message did not clarify the situation for me!

POSTED BY: Aidan Droogan

"I had placed the assumptions inside the Integrate command [ ] and ..."

Which raises the question: Why was this code not indicated in the original post? If you do not provide actual code then (i) Nobody can diagnose for possible mistakes and (ii) everyone who wishes to work on the problem has to retype the input for themselves.

POSTED BY: Daniel Lichtblau

With correct syntax:

In[2]:= Integrate[(2 x^2/a) Sin[n Pi x/a]^2, {x, 0, a}]

Out[2]= (a^2 (4 n^3 \[Pi]^3 - 
   6 n \[Pi] Cos[2 n \[Pi]] + (3 - 6 n^2 \[Pi]^2) Sin[
     2 n \[Pi]]))/(12 n^3 \[Pi]^3)
POSTED BY: S M Blinder

You can use Simplify:

Simplify[Integrate[(2 x^2)/a Sin[n*Pi*x/a]^2, {x, 0, a}], 
 Element[n, Integers]]

or Assuming:

Assuming[Element[n, Integers], 
 Integrate[(2 x^2)/a Sin[n*Pi*x/a]^2, {x, 0, a}]]

Assumptions inside Integrate has no particular effect:

Integrate[(2 x^2)/a Sin[n*Pi*x/a]^2, {x, 0, a}, 
 Assumptions -> Element[n, Integers]]
POSTED BY: Gianluca Gorni
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract