Ideal Gas Equation
- October 14, 2013
- 5 replies
- 5382 views
Good morning,
Right now I am working in a small project (just for curiosity, not work related at this stage), and my purpose is to get the final pressure of gas, based on the time elapsed. I have been working with MathCad for several years, but I am not comfortable dealing with differential models. Instead, I always use some numerical methods and/or matrices to get an approx. solution. This time however, I really would like to use the "Odesolver" fuction. so I am using the ideal gas equation (P*Vmol=R*Temp),the initial volume and the temperature,to evaluate the pressure and the pressure profile after 10 sec.
I defined the two functions (Pressure based on molar vol, and molar vol based on initial volume and time), and now I am trying to put them together to get and expression, but I was not able to do it right. Any comment / suggestion at this point would be really appreciated.
I have already finished the mathcad worksheet using a matrix and dt=0.001 sec, but if possible I would like to use the odesolver for this project.
Attached you can find the few lines with the issue.
Additional Question: Does Odesolver support units?
Thanks a lot,
Oscar J.
