Evaluate integral at specific value
조회 수: 3 (최근 30일)
이전 댓글 표시
I have the following mathematical function f=5sin(x), I use the int(f) to obtain the integral of my expression. Is there a way for me to evaluate the result of the integral at a specifc value, lets say 4,32,
댓글 수: 3
채택된 답변
Walter Roberson
2021년 6월 7일
syms x
f = 5*sin(x)
fint = int(f,x,0,x)
a = 4.32
fa = subs(fint, x, a)
If you are expecting a decimal value, then you are wanting to get an approximation at the location, rather than the value at the location.
double(fa)
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Symbolic Math Toolbox에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!