Unable to solve a differential equation with dsolve
조회 수: 4 (최근 30일)
이전 댓글 표시
Hello, I am attempting to use the dsolve command to solve the following equation:
dC/dt = (1/V)(AFDe^(-At)-EVC
( with the known constants, the equation looks like this)
dC/dt = (1/10500)(0.215*0.68*1*e^(-0.215*t)-(2.772*10500*C)
This is what I have in my script:
dsolve('DCa = (1/10500)*(0.215*0.68*1*exp(-0.215*t) - 2.772*10500*C)','C(0)=0')
The issue is that the answer that dsolve gives me is not even close to what the answer should be when I solve it using a different platform like wolfram alpha. I also can't pinpoint what I did wrong. Any help would be must appreciated! Thank you!
댓글 수: 0
답변 (1개)
Tamir Suliman
2016년 11월 27일
편집: Tamir Suliman
2016년 11월 27일
you probably need to check the parenthesis and the equation you used with dsolve you might to organize it
v=10500;a=0.215;f=0.68;d=1;e=2.72;
syms a v f d e C(t)
cond = C(0) ==0;
eqn = diff(C,t) == (1/v)*(a*f*d)*(exp(-a*t))-e*v*C;
Csol(t)=dsolve(eqn,cond)
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Equation Solving에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!