Solution dependent material coefficient? How to use specifyCoefficients in pdetool (for a time dependnet PDE solution)

조회 수: 3 (최근 30일)
Hi, I have set up a time-dependnet PDE (Fick's law of difusion) in pdetool (v2017) which appears to give me expected results.
Now, I want to make a material property (diffusion ceoffincent) solution dependent (concentration).
I scanned through the documentation and but I am finding it difficult to understand.
How do I use specifyCoefficients
(e.g. specifyCoefficientsspecifyCoefficients(model,'m',0,'d',1,'c',2.3e-3,'a',0,'f',0,'Face',1) is currently set, where 2.3e-3 is the concentration independent diffusion coeff)
when material parameter (in my case the diffusion coefficent) solution dependent
(i.e 2.3e-3 is now 2.3e-3*u*u, where u(x,y) is the solutiion)?

채택된 답변

Ravi Kumar
Ravi Kumar 2020년 2월 10일
Define a function or a anonymous function handle as per the prescribed format. For example you can define:
cFcn = @(region,state) 2.3E-3*state.u.* state.u;
Then use it in specifyCoefficients as:
specifyCoefficients(model,'m',0,'d',1,'c',cFcn,'a',0,'f',0,'Face',1)
Regards,
Ravi

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Geometry and Mesh에 대해 자세히 알아보기

제품


릴리스

R2017b

Community Treasure Hunt

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

Start Hunting!

Translated by