필터 지우기
필터 지우기

How to calculate integral of these complicated functions?

조회 수: 2 (최근 30일)
Jamal
Jamal 2016년 11월 7일
댓글: Jamal 2016년 11월 10일
I have two difficult functions with symbolic parameters (x(1),x(2),x(3),t). I tried to use 'integral'. I tried 'int', but the integral is too complicated and even after 30 mins I get no result- 'busy'. Is there any other method for integral solving? I attach my code here. Would you recommend me how to claculate Integral I and II.
2- then, after calculating integrals, I am trying to fit these integrals to experimental data and acquire those parameteres ( x(1), x(2) ,x(3)). I want to help me to curve fit with experiment data.
Thanks.
clc;
clear all;
%%Analytical solution
beta=0.002;
alfa=0.004;
nu=0.49;
del=0.010;
t0=1.35;
syms eta G1 G2 A s t taw
x=sym('x',[1 3]);
p1=(eta)/(G1+G2);
q1=(2*G1*eta)/(G1+G2);
q0=(2*G1*G2)/(G1+G2);
B1=(2*G1*(1+nu))/(3*(1-2*nu));
B2=(2*G2*(1+nu))/(3*(1-2*nu));
B3=(2*eta*(1+nu))/(3*(1-2*nu));
q2=3*B1*B2/(B1+B2);
q3=B3/(B1+B2);
q4=3*B1*B3/(B1+B2);
Pc1=1+p1*A;
Qc1=q0+q1*A;
Pc2=1+q3*A;
Qc2=q2+q4*A;
f1=Pc1*Qc2*Pc1+2*Pc1*Pc2*Qc1;
c1 = coeffs(f1, A);
c1=simplify(c1);
f2=2*Pc1*Qc1*Qc2+Qc1*Pc2*Qc1;
c2=coeffs(f2,A);
c2=simplify(c2);
GG1= ilaplace((4*beta/(3*t0*sqrt(alfa)))*del*(c2(1,3)*s^2+c2(1,2)*s+c2(1,1))/((c1(1,3)*s^4+c1(1,2)*s^3+c1(1,1)*s^2)), t);
GG2=ilaplace((4*beta/(3*t0*sqrt(alfa)))*del*(c2(1,3)*s^2+c2(1,2)*s+c2(1,1))/((c1(1,3)*s^3+c1(1,2)*s^2+c1(1,1)*s)), t);
GGs1=subs(GG1, t, t-taw);
GGs2=subs(GG2, t, t-taw);
GGss1=subs(GGs1, {G1,G2,eta}, {x(1),x(2),x(3)});
GGss2=subs(GGs2, {G1,G2,eta}, {x(1),x(2),x(3)});
assume(x(1) > 0)
assume(x(2)> 0)
assume(x(3) > 0)
assume(x(1),'real')
assume(x(2),'real')
assume(x(3),'real')
% I want to caluculte Integral I
force1=int(GGss1*diff(taw^1.5,taw),taw,0,t,'IgnoreSpecialCases',true);
% I want to calculate integral II
force2=int(GGss2*diff(taw^1.5,taw),taw,0,t0,'IgnoreAnalyticConstraints',true);
  댓글 수: 2
Jan
Jan 2016년 11월 7일
Please, Jamaleddin , post your code in a readable format, when you want others to read it. Use the "{} Code" button to apply the formatting automatically.
Jamal
Jamal 2016년 11월 10일
Thanks. I did it. Also, I attach the m file too.

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

답변 (0개)

카테고리

Help CenterFile Exchange에서 Least Squares에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by