simulkade / FVTool

Finite volume toolbox for Matlab/Octave
http://fvt.simulkade.com
BSD 2-Clause "Simplified" License
99 stars 56 forks source link

diffusion equation #12

Closed jominkyung closed 5 years ago

jominkyung commented 7 years ago

Hello! I was desperate to find this tool.

It will be very helpful to me. Thank you!

I have to solve the PDE systems and the thing I want to know is that FVTool can solve this kind of problem. (d means gradient and Dc means the diffusion coefficient(constant) of concentration C B means the concentration of B) -> dCdt = d/dx((Dc-C) heaviside(Dc-C) dC/dx) + k1 B C

That is, can FVTool solve not only "dCdt=d^2U/dx^2" but also "dCdt=d/dx(A(C)*dC/dx)" ?

Please share your wisdom with me.

simulkade commented 7 years ago

Hi @jominkyung

Yes you can solve your nonlinear diffusion equation in FVTool, but you need to iterate. I have written a blog post about it previously: http://fvt.simulkade.com/posts/2015-04-06-solving-nonlinear-pdes-with-fvm.html

jominkyung commented 7 years ago

Thank you for your quick reply. I cannot grasp the code in your post because there are so many unknown functions. Is there any other posts about the topic? I want to study more. And can FVTool solve the nolinear PDE systems also?

simulkade commented 7 years ago

Unfortunately, The post on nonlinear diffusion is done with Julia and JFVM.jl (which is a clone of FVTool. I'll add the matlab code when I find free time. You can go through my blog: http://fvt.simulkade.com for more examples. You can also solve nonlinear PDE systems. I have described the procedure here: http://fvt.simulkade.com/posts/2015-09-28-coupled-nonlinear-pdes-two-phase-flow-in-porous-media.html This one is in Matlab!

jominkyung commented 7 years ago

Thank you very much. I have to study more about your posts.