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

2 次查看(过去 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 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by