I am trying to solve Maxwell Stefan's equation over a membrane to get the transient mole fraction distribution over the membrane thickness 'z'. But somehow I am not able to code it using ODE45, more likely I am not able to write the system to solve using ODE45. It will be really great if someone can help me with the primary syntaxes and function. The equation I am trying to solve is
where c is concentration and is binary diffusion coefficient and z varies from 0 to 2.5e-4 cm.
Thank you in advance.

댓글 수: 2

darova
darova 2020년 4월 17일
Anantrao Vijay Shirsath
Anantrao Vijay Shirsath 2020년 4월 20일
Hello, @darova, Sorry for the mistake, I have corrected it. Cheers!

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

답변 (1개)

darova
darova 2020년 4월 20일

0 개 추천

Here is the solution:
f = @(t,y) 1/c/D*(y*(NH2+NH2O)-NH20);
[t,y] = ode45(f,[0 2.5e-4],1);

댓글 수: 2

Anantrao Vijay Shirsath
Anantrao Vijay Shirsath 2020년 4월 20일
The only problem in this anwer is that the value of y should decrease over z, but here it increases!
darova
darova 2020년 4월 20일
impossible. can you show?

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

카테고리

제품

릴리스

R2019a

질문:

2020년 4월 16일

댓글:

2020년 4월 20일

Community Treasure Hunt

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

Start Hunting!

Translated by