Integration in Python
|
05-08-2021, 04:07 PM
Post: #1
|
|||
|
|||
Integration in Python
Hello, how can i insert an integral in python? For example:
Code:
|
|||
05-08-2021, 04:45 PM
Post: #2
|
|||
|
|||
RE: Integration in Python
In reality, the calculation of the integral, with extremes equal to "xx = 0" and "yy = 3", instead of being equal to 9/2, becomes equal to "yy^2/2 - xx^2/2". How can I express, in the integral, the values given to "xx" and "yy"?
Code:
|
|||
05-08-2021, 05:34 PM
Post: #3
|
|||
|
|||
RE: Integration in Python
(05-08-2021 04:45 PM)robmio Wrote: gg=caseval("int(x,x,xx,yy)") You need to interpolate the string >>> xx, yy = "0", "3" >>> "int(x, x, {0}, {1})".format(xx,yy) 'int(x, x, 0, 3)' |
|||
05-08-2021, 07:16 PM
Post: #4
|
|||
|
|||
RE: Integration in Python
it works! Thanks so much! Another question: the result appears in the "Terminal" screen: how can I get the result in the "CAS" screen?
|
|||
05-08-2021, 07:42 PM
Post: #5
|
|||
|
|||
RE: Integration in Python
Also, why is it an error if I set the extremes "xx = 0" and "yy = 1000"? In fact, if I set the upper extreme to "999", the result is right.
|
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)