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.

Inserting mathematical expressions under reaction field

Niladri Sekhar Manadal

Please login with a confirmed email address before reporting spam

I want to insert a differential equation in the reaction section as a function of concentration. The physics is "Transport of Dilute Species". The reaction is concentration dependent.

Every time I attempt to do so, I get a message saying syntax error. Can someone please clarify how to insert a mathematical equation under the reaction tab when the reaction is in mol/cm^3.


3 Replies Last Post 20 mag 2020, 11:18 GMT-4
Jeff Hiller COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 5 years ago 14 mag 2020, 11:44 GMT-4

Can you attach your mph file, or at least tell us what expression you tried entering?

Jeff

-------------------
Jeff Hiller
Can you attach your mph file, or at least tell us what expression you tried entering? Jeff

Niladri Sekhar Manadal

Please login with a confirmed email address before reporting spam

Posted: 5 years ago 19 mag 2020, 19:34 GMT-4
Updated: 5 years ago 19 mag 2020, 20:22 GMT-4

I am trying to provide an equation which looks like the following

Can I provide this equation in the global definitions? Or do I need to enter it by defining a PDE using the math module?

Thank you.

I am trying to provide an equation which looks like the following R_2 = K \frac {dc_2}{dt} Can I provide this equation in the global definitions? Or do I need to enter it by defining a PDE using the math module? Thank you.

Jeff Hiller COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 5 years ago 20 mag 2020, 11:18 GMT-4
Updated: 5 years ago 20 mag 2020, 18:19 GMT-4

Yes, you should be able to enter an expression like that for your reaction term. The issue is likely one of syntax or scope of the variables involved. In particular, you mention that you are trying to use global definitions, but I doubt that c2 has a global scope, i.e. c2 is, I presume, defined at the Component level in your file.

Best,

Jeff

-------------------
Jeff Hiller
Yes, you should be able to enter an expression like that for your reaction term. The issue is likely one of syntax or scope of the variables involved. In particular, you mention that you are trying to use global definitions, but I doubt that c2 has a global scope, i.e. c2 is, I presume, defined at the Component level in your file. Best, Jeff

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.