Unable to solve a differential equation with dsolve
6 views (last 30 days)
Show older comments
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 Comments
Answers (1)
Tamir Suliman
on 27 Nov 2016
Edited: Tamir Suliman
on 27 Nov 2016
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 Comments
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!