Note: This discussion is about an older version of the COMSOL Multiphysics® software. The information provided may be out of date.
Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.
chemical reaction, concentration reaches zero
Posted 8 dic 2009, 10:50 GMT-5 Version 3.5a 10 Replies
Please login with a confirmed email address before reporting spam
I'm new to this forum, but I hope that anyone of you can help me... :) Because I'm a chemical engineer I might be
using expressions which some of you don't understand. But since PDE's are the same in different branches of sciences
feel free to ask if you don't understand any of it. I'll explain them.
I'm trying to model a single channel where the wall is covered by a small layer of a porous washcoat (Al2O3). In the
washcoat there's a catalyst deposited. So the reaction only takes place in the washcoat. My problem is the rate of
reaction.
As you can see it's an 'advanced' type of expression (Hougen-Watson type, not a simple power law; please ignore the dots in nom and denom):
........k*K1*K2^2*p1^0.5*p2
r = -----------------------------------
.....(1+K1*p1^0.5+K2*p2^0.5)^3
where: k: temperature dependent constant
K1: temperature dependent constant
K2: temperature dependent constant
p1: partial pressure component 1
p2: partial pressure component 2
I get an error when an educt-concentration reaches zero. I have tried a lot of things (e.g. multiplied the reaction
rate with a constant, compute the solution, raise the constant, recompute with actual solution as initial value; or
refining the mesh; or adding certain types of artificial diffusion; or logical operators (c>0)....)
Additionally the reaction is very exothermic, which imposes some effects like acceleration of the reaction with
Temperature and limitation of the conversion due to thermodynamical reasons at higher temperatures.
Has anyone any idea how to manage this? I'll tell Santa Clause some good words for the one with the crucial tip to
solve this! ;)
Thanks for any help!
Thilo Henrich
Hello Thilo Henrich
Your Discussion has gone 30 days without a reply. If you still need help with COMSOL and have an on-subscription license, please visit our Support Center for help.
If you do not hold an on-subscription license, you may find an answer in another Discussion or in the Knowledge Base.
Please login with a confirmed email address before reporting spam
I have also tried the use of logical operators but they will result in convergence issues. I was suggested to use the smoothing functions built into comsol, but found that in the limit of very low concentrations (i.e. high consumption) that the smoothing functions can have discontinuities.
so I would start by checking that you don't have negative concentrations -- in the very small range of say -1e-10 to 1e-10. as I generally find mine fail in that range -- with other cases becoming much more negative ...even with the smoothing being used (which should have moved my consumption term to zero).
Hope this helps.
Dave
Please login with a confirmed email address before reporting spam
I have a general question, as I see many people are fighting with low concetrations (or very large ranges), as well as unphysical negative concentrations.
Isn't there a way to do a variable change and work in log(C) mode ?
OK you need to change the formuals in several places but for chemistry I get the feeling that you need more resolution than what normal binary number give you, and that the precision remains still OK for your models in a log scale.
Or am I wrong here?
--
Good luck
Ivar
Please login with a confirmed email address before reporting spam
Thanks for the response. Yes, I have tried the log(C) transformation with success -- as to the avoidance of negative concentrations.
However -- if one wanted to look at diffusion from the standpoint of a multi-component perspective (which I need to, for the systems of interest), does this not breakdown here or at the very least become unecessarily complicated?
Also -- there are many other similar transport scenarios in modelling the chemical reaction that involve needing to account for convection, ion migration, etc. that are no longer straightforward with the use of a log transformation.
I definitely welcome your thoughts here?
on a side note -- I am suprised that this is something that comsol support refuses to properly address (and yes I went through a very long and drawn out email exchange with them -- with an extremely unsatisfactory result that has prompted me to begin switching software)
Regards
David
Please login with a confirmed email address before reporting spam
Hi Ivar,
Thanks for the response. Yes, I have tried the log(C) transformation with success -- as to the avoidance of negative concentrations.
However -- if one wanted to look at diffusion from the standpoint of a multi-component perspective (which I need to, for the systems of interest), does this not breakdown here or at the very least become unecessarily complicated?
Also -- there are many other similar transport scenarios in modelling the chemical reaction that involve needing to account for convection, ion migration, etc. that are no longer straightforward with the use of a log transformation.
I definitely welcome your thoughts here?
on a side note -- I am suprised that this is something that comsol support refuses to properly address (and yes I went through a very long and drawn out email exchange with them -- with an extremely unsatisfactory result that has prompted me to begin switching software)
Regards
David
I totally feel for you. I have spent last 10 months of my work on this part (which was supposed to take 1 month at most). The limitation is coming from the finite-element nature of the software I assume (opposed to locally conservative FVM). Whatever you do- unless using extremely fine mesh- you will have oscillations at high Pe_MT. So, one way comsol can handle is using artificial diffusion, with have-to-have streamline diffusion, and if necessary X-wind diffusion. Not to mention that meshing is also very critical. Your tolerances are also very important, which I noticed it must go as small as 10^-9 for me, for c_inlet =1mol. So, when I didn't have mass transfer I could solve my model with 200k DOF, but now I am struggling with 6M DOF, taking a week on 48 core for 1 sec of simulation.
Overall, it is a lot of frustration and no solution but lots of trial and error. For me there is no other choice of software unfortunately. Comsol is the only one that can solve my case problem at the moment (AFAIK).
Also, I highly recommend you to use 4.1 version, which has solved many problems, specially in case of artificial diffusion bugs compared to 3.5a.
TL;DR based on my experience (and hopefully I am wrong) comsol is not the best solution for high Pe mass transfer. Look for a conservative scheme if you can.
--
Comsol 4.1
Ubuntu 10.04.1
Please login with a confirmed email address before reporting spam
Well have you discussed this with the COMSOL developpers ? At the conference or via "support" ?
Because , I find them rather responsive for my main chapters (structural, mems, HT, ACDC ...), so I'm sure if they learn enough about your issues, failures and success, they can then adapt the tool to better cover your cases too, you should just not expect a response the next day for such major adaptations
--
Good luck
Ivar
Please login with a confirmed email address before reporting spam
Ivar -- Sadly, I spent 3 months dealing with comsol support on this issue -- they suggested to relook at my boundary conditions and increasing my mesh resolution -- (as to Daniel's point, if the mesh resolution required becomes that demanding I should just solve in a FV software) -- they also suggested using the smoothing terms built in to comsol. But in looking at the smoothing I found that they have oscillations in the range of interest say -10^-12 to 10^-12 -- although you may need to plot on a finer scale to see them -- result: model doesn't converge.
Nonetheless -- it would seem that if comsol is to be used for chemical/electrochemical reaction modelling -- this is something the developers should tackle with a higher priority.
David
Please login with a confirmed email address before reporting spam
if you have ripples in the 1E-12 compared to 1 it's normal: that is the binary representsation of real number it's numerical noise, we all tend to forget (today) that the binary number scheme is of limited precision (as well as non uniform over R), 20 year ago and more with 4-8 bit FPus we were more concerned about this. And still "eps" today is around 1E-12 and most physical equations are based on 2nd order formulas so its rather sqrt(eps) that is governing and that is in the 1E-6 range ! The limit here is not COMSOL but the HW
This means that carefull rescaling is required, or variable changes BEFORE we launch our FPU as these are still of limited precision, you are in fact saying that today, 64bit FPU even in "double precision" are even not enough
So its up to us to be intelligent with the rescaling variable changes etc, even if it means less general fomulations
--
Good luck
Ivar
Please login with a confirmed email address before reporting spam
Daniel -- have you investigated open foam, it is what I am migrating to.
David, I have tried several codes/softawres already. Openfoam i.e. does not have a strong coupling for fluid-structure interaction yet implemented. Oomph-lib has a very high learning curve and needs occasional code changes. Both are extremely well-coded and strong, but to be honest I don't want to spend time dwelling inside the source code for my phd (as much as possible). So, if I want to do something that is a bit tricky and not-out-of-the-box, then I am out of luck with current open-source softwares, unless I do it myself. This is valid for any opensource framework, even forums which I was developing once.
Danial
--
Comsol 4.1
Ubuntu 10.04.1
Please login with a confirmed email address before reporting spam
I do agree -- the issue is that the movement of the floating point to the negative space causes a good deal of grief for anyone modelling chemical kinetics due to reactions orders that are not unity. In order to model the full range of the chemical kinetics it is of interest to study the cases of near zero concentrations in distributed catalysts.
The perspective I had on this was behaviour around eps -- and once comsol diverges on the negative side it follows that with ever increasing negative concentration solutions for subsequent solutions.
I am curious though why this is an issue with FEM, but not apparently with my FVM solvers.
thoughts?
Dave
Please login with a confirmed email address before reporting spam
I suppose that working with only R>0 requires some specific tweaking of the solvers to also systematically respect this condition. As COMSOL is set up for highly general solving of "any physics" it might be that this particular case is not treated the best today.
That is why one should gently, but regularly, update "support" with examples where COMSOL is not behaving as well as expected. As there are several chemists in the comsol team they should be sensitive to your arguments
--
Good luck
Ivar
Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.
Suggested Content
- FORUM Cheamical Reaction Not Proceeding
- FORUM electrolytic reaction
- BLOG Protein Adsorption: Batch and Space-Dependent Modeling
- KNOWLEDGE BASE Wrong Number of DOFs in Linearization Point
- KNOWLEDGE BASE Avoiding Negative Concentrations