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.

A flow loop boundary condition (Transport of Diluted Species)

Please login with a confirmed email address before reporting spam

Hi,
I would like to simulate a problem with a virtual flow loop. The problem consist of two physics; laminar flow and diffusion. The simplified problem looks like this:

- Imagine a box full of liquid with a species C0. There is a laminar flow from the left (flow inlet) to the right (flow outlet) side of the box. I would like the flux of C0 species that exits with the flow from the boundary to the right , appears at the boundary to the left (as the input flux). In this way the liquid virtually circulate in the box.

I am wondering if it is possible to define such a boundary condition for the Transport of Diluted Species.
Please let me know if there is any similar problem, tutorial, thread, etc that I can study as inspiration.

Bests,
Mokhtar

4 Replies Last Post Sep 5, 2012, 1:06 a.m. EDT

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago Sep 3, 2012, 4:23 p.m. EDT
Hi,


There are two options, don't know if they are ideal...but you can try.

Use time discrete solver, this allows use of variable or parameter values from the previous time step via the prev operator. So you create a variable that computes total outward normal flux from the right boundary. Call this variable with the prev operator and use it as a left boundary condition. This may work. Comsol manuals clearly tell you how to use prev operator and I think there are some previous discussions on this in this forum. Of course, if I am right, when you use the time discrete solver the time step size is fixed. So if you have to solve for large times, it is going to be time consuming. Again, I am not so sure, you may check.

The other alternative is to go to matlab and do the same as above, but you will end up with lot of book keeping.


Suresh
Hi, There are two options, don't know if they are ideal...but you can try. Use time discrete solver, this allows use of variable or parameter values from the previous time step via the prev operator. So you create a variable that computes total outward normal flux from the right boundary. Call this variable with the prev operator and use it as a left boundary condition. This may work. Comsol manuals clearly tell you how to use prev operator and I think there are some previous discussions on this in this forum. Of course, if I am right, when you use the time discrete solver the time step size is fixed. So if you have to solve for large times, it is going to be time consuming. Again, I am not so sure, you may check. The other alternative is to go to matlab and do the same as above, but you will end up with lot of book keeping. Suresh

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago Sep 4, 2012, 5:48 a.m. EDT
Thanks for the suggestion. I might be confined to "Time Dependent" solver in my case. Is there any way to implement it with Time Dependent solver instead? Is it possible to use some kind of boundary mapping or model coupling like boundary similarity?
Thanks for the suggestion. I might be confined to "Time Dependent" solver in my case. Is there any way to implement it with Time Dependent solver instead? Is it possible to use some kind of boundary mapping or model coupling like boundary similarity?

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago Sep 4, 2012, 9:04 p.m. EDT
Hi Mukhtar,

I think at each time step u can calculate the input flux by defining it as an "expression" a "function of solution variable" (perhaps a boundary integration variable) and then use this expression as a boundary condition at the left side of your domain. Your problem's boundary condition will then become a function of solution variable itself (a non linear problem with a non linear boundary condition).

Hi Mukhtar, I think at each time step u can calculate the input flux by defining it as an "expression" a "function of solution variable" (perhaps a boundary integration variable) and then use this expression as a boundary condition at the left side of your domain. Your problem's boundary condition will then become a function of solution variable itself (a non linear problem with a non linear boundary condition).

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago Sep 5, 2012, 1:06 a.m. EDT

Hi,
I would like to simulate a problem with a virtual flow loop. The problem consist of two physics; laminar flow and diffusion. The simplified problem looks like this:

- Imagine a box full of liquid with a species C0. There is a laminar flow from the left (flow inlet) to the right (flow outlet) side of the box. I would like the flux of C0 species that exits with the flow from the boundary to the right , appears at the boundary to the left (as the input flux). In this way the liquid virtually circulate in the box.

I am wondering if it is possible to define such a boundary condition for the Transport of Diluted Species.
Please let me know if there is any similar problem, tutorial, thread, etc that I can study as inspiration.

Bests,
Mokhtar


Hi Mokhtar,

It can be done using integration or average model coupling operators.
-Under model/definitions node; create an average coupling operator aveop1 on the outlet flux boundary.
-Set inlet flux boundary condition as aveop1(flux_variable).

This will virtually connect your outlet and inlet boundaries and create a closed loop. However, when you use the average operator, the model will evaluate the average flux at the outlet boundary and then impose it on the inlet boundary as a single value. If you need the flux distribution on the inlet boundary to be exactly the same as the outlet boundary, I honestly don't know how to do it. You should probably look into other operators such as identity mapping, boundary similarity or extrusion. It would be great if someone can explain this, as well.

Hope it helps.

--
Tolga
[QUOTE] Hi, I would like to simulate a problem with a virtual flow loop. The problem consist of two physics; laminar flow and diffusion. The simplified problem looks like this: - Imagine a box full of liquid with a species C0. There is a laminar flow from the left (flow inlet) to the right (flow outlet) side of the box. I would like the flux of C0 species that exits with the flow from the boundary to the right , appears at the boundary to the left (as the input flux). In this way the liquid virtually circulate in the box. I am wondering if it is possible to define such a boundary condition for the Transport of Diluted Species. Please let me know if there is any similar problem, tutorial, thread, etc that I can study as inspiration. Bests, Mokhtar [/QUOTE] Hi Mokhtar, It can be done using integration or average model coupling operators. -Under model/definitions node; create an average coupling operator aveop1 on the outlet flux boundary. -Set inlet flux boundary condition as aveop1(flux_variable). This will virtually connect your outlet and inlet boundaries and create a closed loop. However, when you use the average operator, the model will evaluate the average flux at the outlet boundary and then impose it on the inlet boundary as a single value. If you need the flux distribution on the inlet boundary to be exactly the same as the outlet boundary, I honestly don't know how to do it. You should probably look into other operators such as identity mapping, boundary similarity or extrusion. It would be great if someone can explain this, as well. Hope it helps. -- Tolga

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.