CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > CFX

Thermal Two Fluid (Not Interacting with Each Other) in CFX

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   December 13, 2017, 10:01
Default Thermal Two Fluid (Not Interacting with Each Other) in CFX
  #1
New Member
 
Abid Khan
Join Date: Dec 2017
Posts: 23
Rep Power: 5
abidkhan is on a distinguished road
Hello,

Consider the case portrayed in the image, is it possible to analyse (thermal analysis) two fluid (nitrogen and air) which are not interacting with each other (not in direct contact with each other) in CFX? I'm having trouble in assigning material to the fluid domains.

When I assign material air to the domain air, it automatically changed the material of domain nitrogen to material air. When I correct it by changing the material to nitrogen, it changes the material of domain air to material oxygen. It look like these two fluids are interconnected and changing material of one domain updates the material of other fluid domain by itself. I doubt that only one independent fluid can be analyzed in CFX. Is it true?

abidkhan is offline   Reply With Quote

Old   December 13, 2017, 15:14
Default
  #2
Senior Member
 
Join Date: Jun 2009
Posts: 1,441
Rep Power: 27
Opaque will become famous soon enough
ANSYS CFX definitely can model two disconnected fluid domains, but it is not a mainstream setup.

You must enable beta features. For an existing case, open the Case Options , Enable Beta Features, Disable Constant Domain Physics.

At this point, you must be careful since the software may not be completely stable (beta mode). Alternatively, you can set up the case with the same material, different fluid name until most of the setup is done, then enable beta features and try it.
Opaque is offline   Reply With Quote

Old   December 13, 2017, 16:38
Default
  #3
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 16,820
Rep Power: 132
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
The officially supported method to do this is to use a multicomponent mixture and define the mass fractions to make one region air and the other nitrogen. multicomponent mixtures are not very CPU intensive so this might be a practical option for you.

An alternate approach is to use the beta feature option described by Opaque, but as he says, it is a beta feature so you use it at your own risk.
ghorrocks is offline   Reply With Quote

Old   December 13, 2017, 20:35
Default
  #4
New Member
 
Abid Khan
Join Date: Dec 2017
Posts: 23
Rep Power: 5
abidkhan is on a distinguished road
I'll try this today.
abidkhan is offline   Reply With Quote

Old   December 13, 2017, 20:37
Default
  #5
New Member
 
Abid Khan
Join Date: Dec 2017
Posts: 23
Rep Power: 5
abidkhan is on a distinguished road
Quote:
Originally Posted by Opaque View Post
ANSYS CFX definitely can model two disconnected fluid domains, but it is not a mainstream setup.

You must enable beta features. For an existing case, open the Case Options , Enable Beta Features, Disable Constant Domain Physics.

At this point, you must be careful since the software may not be completely stable (beta mode). Alternatively, you can set up the case with the same material, different fluid name until most of the setup is done, then enable beta features and try it.

I'll try this method today.
abidkhan is offline   Reply With Quote

Old   December 13, 2017, 20:41
Default
  #6
New Member
 
Abid Khan
Join Date: Dec 2017
Posts: 23
Rep Power: 5
abidkhan is on a distinguished road
Quote:
Originally Posted by ghorrocks View Post
The officially supported method to do this is to use a multicomponent mixture and define the mass fractions to make one region air and the other nitrogen. multicomponent mixtures are not very CPU intensive so this might be a practical option for you.

An alternate approach is to use the beta feature option described by Opaque, but as he says, it is a beta feature so you use it at your own risk.
In multicomponent method, how will I create SS cylinder in separating the two fluid? By multicomponent method, I took I've to add two fluids in fluid domain setup. Then in this case do I've to model the cylinder separating two fluids?
abidkhan is offline   Reply With Quote

Old   December 14, 2017, 00:17
Default
  #7
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 16,820
Rep Power: 132
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
The SS (which I assume is stainless steel) which separates the two gasses is a solid domain and can be given the properties of stainless steel. This is a conjugate heat transfer (CHT) simulation between the two fluid domains and the solid domain between them.
ghorrocks is offline   Reply With Quote

Old   December 14, 2017, 08:25
Default
  #8
New Member
 
Abid Khan
Join Date: Dec 2017
Posts: 23
Rep Power: 5
abidkhan is on a distinguished road
Quote:
Originally Posted by ghorrocks View Post
The SS (which I assume is stainless steel) which separates the two gasses is a solid domain and can be given the properties of stainless steel. This is a conjugate heat transfer (CHT) simulation between the two fluid domains and the solid domain between them.
Thank you very much for you reply. I'll google for tutorial on conjugate heat transfer using multicomponent method. And yes, SS is stainless steel.
abidkhan is offline   Reply With Quote

Old   December 14, 2017, 15:29
Default
  #9
Senior Member
 
Join Date: Jun 2009
Posts: 1,441
Rep Power: 27
Opaque will become famous soon enough
If you follow Glenn's suggestion of using multicomponent approach (which is limited and you will find out later if you need additional functionality) be certain you set the material components as algebraic; therefore, no need to solve any equations nor boundary conditions.

You must initialize these expressions to be 1 in the domain the material exists, and 0 in the other. Similarly for the second material component. How do you do it?

COMPONENT: Material 1
Mass Fraction = inside()@Domain 1

COMPONENT: Material 2
Mass Fraction = inside()@Domain 2

Done!!
Opaque is offline   Reply With Quote

Old   December 15, 2017, 00:15
Default
  #10
New Member
 
Abid Khan
Join Date: Dec 2017
Posts: 23
Rep Power: 5
abidkhan is on a distinguished road
Quote:
Originally Posted by Opaque View Post
If you follow Glenn's suggestion of using multicomponent approach (which is limited and you will find out later if you need additional functionality) be certain you set the material components as algebraic; therefore, no need to solve any equations nor boundary conditions.

You must initialize these expressions to be 1 in the domain the material exists, and 0 in the other. Similarly for the second material component. How do you do it?

COMPONENT: Material 1
Mass Fraction = inside()@Domain 1

COMPONENT: Material 2
Mass Fraction = inside()@Domain 2

Done!!
I've turned off the constant domain in the beta feature and tried to solve it and it solved. What are the risks in beta features? Are these the results (i.e. results are not accurate) or the stability of the software?
abidkhan is offline   Reply With Quote

Old   December 15, 2017, 00:20
Default
  #11
New Member
 
Abid Khan
Join Date: Dec 2017
Posts: 23
Rep Power: 5
abidkhan is on a distinguished road
Quote:
Originally Posted by ghorrocks View Post
The SS (which I assume is stainless steel) which separates the two gasses is a solid domain and can be given the properties of stainless steel. This is a conjugate heat transfer (CHT) simulation between the two fluid domains and the solid domain between them.
I've tried to learn the multicomponents but this method seems to be for mixtures (two fluids interacting with each other) whereas in my case there is no such case of mixing. I'm unable to understand to procedure. If you can spare some time, can you setup the above case (with coarse mesh) and send it to me for my understanding so that I can apply the same methodology in my case.
abidkhan is offline   Reply With Quote

Old   December 15, 2017, 00:39
Default
  #12
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 16,820
Rep Power: 132
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
The risks of beta software is that the software provider (ie ANSYS) does not guarantee the stability, robustness and accuracy of the results. It is not fully tested, and might have physics options which are not compatible with it. So weird things might happen. Also it is not included in the documentation so you don't know much background about it.

So in short: You use beta features at your own risk, and you have to keep an eye out for strange behaviour and incorrect results. If you don't have enough experience to be able to identify strange behaviour and incorrect results then you probably should not be using beta features.

Yes, the multicomponent mixture model was designed to model two gas species which are mixed. But it can be used in your situation by simply setting the mass fractions to pure one species in one domain and pure the other species in the other domain (opaque's suggestion is an example of how to do this). So even though you have to define diffusivities and related mixing parameters, if the species aren't mixing then they don't come into it. So you can define anything you like for diffusivity.

Sorry, I do not have time to set up a case for you. Have a look at the CFX tutorial examples which use multicomponent mixtures for examples on how to set this up. Make sure you do not get confused with multiphase flows - multiphase is completely different. You are looking for multicomponent mixtures.
ghorrocks is offline   Reply With Quote

Old   December 15, 2017, 06:25
Default
  #13
New Member
 
Abid Khan
Join Date: Dec 2017
Posts: 23
Rep Power: 5
abidkhan is on a distinguished road
Quote:
Originally Posted by ghorrocks View Post
The risks of beta software is that the software provider (ie ANSYS) does not guarantee the stability, robustness and accuracy of the results. It is not fully tested, and might have physics options which are not compatible with it. So weird things might happen. Also it is not included in the documentation so you don't know much background about it.

So in short: You use beta features at your own risk, and you have to keep an eye out for strange behaviour and incorrect results. If you don't have enough experience to be able to identify strange behaviour and incorrect results then you probably should not be using beta features.

Yes, the multicomponent mixture model was designed to model two gas species which are mixed. But it can be used in your situation by simply setting the mass fractions to pure one species in one domain and pure the other species in the other domain (opaque's suggestion is an example of how to do this). So even though you have to define diffusivities and related mixing parameters, if the species aren't mixing then they don't come into it. So you can define anything you like for diffusivity.

Sorry, I do not have time to set up a case for you. Have a look at the CFX tutorial examples which use multicomponent mixtures for examples on how to set this up. Make sure you do not get confused with multiphase flows - multiphase is completely different. You are looking for multicomponent mixtures.
Thank you very much for such a detailed reply. So nice of you.
abidkhan is offline   Reply With Quote

Old   February 13, 2018, 00:11
Default
  #14
New Member
 
Abid Khan
Join Date: Dec 2017
Posts: 23
Rep Power: 5
abidkhan is on a distinguished road
Quote:
Originally Posted by Opaque View Post
If you follow Glenn's suggestion of using multicomponent approach (which is limited and you will find out later if you need additional functionality) be certain you set the material components as algebraic; therefore, no need to solve any equations nor boundary conditions.

You must initialize these expressions to be 1 in the domain the material exists, and 0 in the other. Similarly for the second material component. How do you do it?

COMPONENT: Material 1
Mass Fraction = inside()@Domain 1

COMPONENT: Material 2
Mass Fraction = inside()@Domain 2

Done!!
I'm having issues in beta feature. Now I want to switch to this method quoted above. I tried to setup multicomponent mixture by creating a variable composition mixture. Then I assigned the newly defined mixture to my first fluid domain i.e. "AIR".

While setting up the domain (Air), in "Fluid Models" tab and under "Component Model" Field, I've two components of the mixture i.e. Air and Nitrogen. I clicked on the Air and selected "Algebraic Equation" from the options drop down list.

Now here I'm bit confused about entering the Mass Fraction. Kindly guide me how to enter it algebraically for my two mixtures (air and nitrogen) for the domain "AIR"?
abidkhan is offline   Reply With Quote

Old   February 14, 2018, 01:02
Default
  #15
New Member
 
Abid Khan
Join Date: Dec 2017
Posts: 23
Rep Power: 5
abidkhan is on a distinguished road
Hello,

I've used inside()@Air and inside()@Nitrogen where Air and Nitrogen are domain names. I get following error message:

Code:
Details of error:-
 ----------------
 Error detected by routine PEEKI 
 CDANAM = NWORK
 CRESLT = NONE
  
 Current Directory : /FLOW/PHYSICS/MATERIALS/MT2/DENSITY

 +--------------------------------------------------------------------+
 |                    Writing crash recovery file                     |
 +--------------------------------------------------------------------+
  
 Details of error:-
 ----------------
 Error detected by routine DELDAT 
 CDANAM = KE
 CRESLT = NONE
  
 Current Directory : /FLOW/SOLUTION/TSTEP0/CLOOP0/ZN1/VERTICES
I also used entering numeric values of Mass Fraction for components instead of inside()@Air compression and no such error is received but in this case when I enter mass fraction 1 for air and 0 for nitrogen it is also automatically updated in nitrogen as well (1 for air and 0 for nitrogen even though I've set 0 for air and 1 nitrogen). Updating component mass fraction in one fluid domain updates the values in other fluid domain.

I'm stuck, please help.
abidkhan is offline   Reply With Quote

Old   February 14, 2018, 16:50
Default
  #16
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 16,820
Rep Power: 132
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
I would not call a domain "Air" or "Nitrogen" as it may get confused with the material names. Give the domains names which are definitely unique.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum.
ghorrocks is offline   Reply With Quote

Old   February 14, 2018, 21:04
Default
  #17
New Member
 
Abid Khan
Join Date: Dec 2017
Posts: 23
Rep Power: 5
abidkhan is on a distinguished road
Yes, I tried by renaming the domains too air1 and nitrogen1 but error remains the same.
abidkhan is offline   Reply With Quote

Old   February 14, 2018, 21:19
Default
  #18
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 16,820
Rep Power: 132
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
It is hard to understand CFX error messages, they are very cryptic. But I suspect the error message you quote is saying that density is not defined for one of your materials. So check you have defined the density, or if you are using an equation of state that all the inputs to the EOS are defined.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum.
ghorrocks is offline   Reply With Quote

Old   February 19, 2018, 03:10
Default
  #19
New Member
 
Abid Khan
Join Date: Dec 2017
Posts: 23
Rep Power: 5
abidkhan is on a distinguished road
Dear Glenn,

I've fully defined the materials and even tried using the materials present in the CFX library just to check if anything wrong with the properties. I still got the same error. Please see below the detailed error code which is saying something that pressure is not set at any boundary condition in Nitrogen1 domain. However, I'm defining the pressure as 1atm in both air and nitrogen domains in buoyancy setting. May be you understand something from this log:

Code:
 +--------------------------------------------------------------------+
 |                   Buoyancy Reference Information                   |
 +--------------------------------------------------------------------+

 Domain Group: Air1
  
   Buoyancy has been activated.  The absolute pressure will include
   hydrostatic pressure contribution, using the following reference
   coordinates: ( 5.39090E-01, 2.37276E+00, 5.39090E-01).

 Domain Group: Nitrogen1
  
   Pressure has not been set at any boundary conditions.
   The pressure will be set to  0.00000E+00 at the following location:
   Domain      : Nitrogen1
   Node        :        1 (equation         1)
   Coordinates : ( 5.28000E-01, 3.51700E+00, 3.19000E-01).

 Domain Group: Nitrogen1
  
   Buoyancy has been activated.  The absolute pressure will include
   hydrostatic pressure contribution, using the following reference
   coordinates: ( 5.28000E-01, 3.51700E+00, 3.19000E-01).
  
 Details of error:-
 ----------------
 Error detected by routine PEEKI 
 CDANAM = NWORK
 CRESLT = NONE
  
 Current Directory : /FLOW/PHYSICS/MATERIALS/MT2/DENSITY

 +--------------------------------------------------------------------+
 |                    Writing crash recovery file                     |
 +--------------------------------------------------------------------+
  
 Details of error:-
 ----------------
 Error detected by routine DELDAT 
 CDANAM = KE
 CRESLT = NONE
  
 Current Directory : /FLOW/SOLUTION/TSTEP0/CLOOP0/ZN1/VERTICES

 +--------------------------------------------------------------------+
 |                An error has occurred in cfx5solve:                 |
 |                                                                    |
 | The ANSYS CFX solver exited with return code 1.   No results file  |
 | has been created.                                                  |
 +--------------------------------------------------------------------+

End of solution stage.
abidkhan is offline   Reply With Quote

Old   February 19, 2018, 04:57
Default
  #20
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 16,820
Rep Power: 132
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
The line "Pressure has not been set at any boundary conditions. The pressure will be set to 0.00000E+00 at the following location" is ominous.

It appears you have not set the pressure, so the solver has set a point to zero pressure. If you have not set a reference pressure properly this will result in zero and possibly negative absolute pressures and this will destroy most EOS equations and give you a density error.

Check that your initial and/or boundary conditions are set correctly, such that the pressure is properly defined.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum.
ghorrocks is offline   Reply With Quote

Reply

Tags
multiple fluids, thermal

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
mass flow in is not equal to mass flow out saii CFX 12 March 19, 2018 05:21
Question about adaptive timestepping Guille1811 CFX 25 November 12, 2017 17:38
CFX FSI Fatal Error unbanana CFX 0 October 3, 2015 05:57
GETVAR Error in Multiband Monte Carlo Radiation Simulation with Directional Source silvan CFX 3 June 16, 2014 09:49
FSI: Pressure and Normal Force don't match with expected values Geraud CFX 6 August 21, 2012 15:34


All times are GMT -4. The time now is 02:54.