필터 지우기
필터 지우기

How to do symbolic integration

조회 수: 2 (최근 30일)
gourav pandey
gourav pandey 2021년 12월 23일
댓글: Star Strider 2021년 12월 24일
%% I am unable to get the result. Thank you so much in advance
clc;
clear;
syms omega x n m
% assuming omega::real,omega>0,m::integer,m>0,n::integer,n>0;
fun=int(cos(atan(1,x))^m*sin(omega*x)/(1+x^2)^((n)/2+1),x,0,Inf);

답변 (2개)

Star Strider
Star Strider 2021년 12월 23일
It apparently does not have a symbolic solution (this is not uncommon).
It does have a piecewise closed-form solution, at least over some regions, and one option would be to numerically integrate it (although that could have problems as well) —
syms omega x n m real
sympref('AbbreviateOutput',false);
assume(m,'integer')
assumeAlso(m,'positive')
assume(n,'integer')
assumeAlso(n,'positive')
assume(omega,'positive')
% assuming omega::real,omega>0,m::integer,m>0,n::integer,n>0;
integrand = cos(atan(1,x))^m*sin(omega*x)/(1+x^2)^((n)/2+1)
integrand = 
integrand = simplify(integrand, 500)
integrand = 
fun=int(integrand,x,0,Inf)
fun = 
nfun = matlabFunction(integrand) % Anonymous Function Argument To 'integral'
nfun = function_handle with value:
@(m,n,omega,x)x.^m.*sin(omega.*x).*(x.^2+1.0).^(m.*(-1.0./2.0)-n./2.0-1.0)
This likely as good as it gets.
.
  댓글 수: 2
gourav pandey
gourav pandey 2021년 12월 24일
thank you..it helped me
Star Strider
Star Strider 2021년 12월 24일
My pleasure!

댓글을 달려면 로그인하십시오.


KSSV
KSSV 2021년 12월 23일
Try substituing the values of m and n.
syms omega positive real
% syms n m positive integer
syms x
% assuming omega::real,omega>0,m::integer,m>0,n::integer,n>0;
m = 5 ; n = 4 ;
fun=int(cos(atan(1,x))^m*sin(omega*x)/(1+x^2)^((n)/2+1),x,0,Inf)
fun = 
  댓글 수: 1
gourav pandey
gourav pandey 2021년 12월 23일
Hii,
I have some restriction due to which i can't substitute the values on omega, m, and n. Is there any other way to integrate the above expression.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Conversion Between Symbolic and Numeric에 대해 자세히 알아보기

제품


릴리스

R2021b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by