I have been modifying the microFluidics2d example to simulate a scenario for my university thesis. I have been attempting to include gravity in the example but have not had any success so far. As far as I can tell none of the other multiComponent examples include gravity. Any assistance with this would be much appreciated.
In the line where the Descriptor is set, you have to include the Field “EXTERNAL_FORCE” like this:
typedef D2Q9<CHEM_POTENTIAL,FORCE,EXTERNAL_FORC> DESCRIPTOR;
This field will be added to the multi-phase force in the free energy post-processor, just fyi. In the “prepareLattice” method, you can now initialize the external force field with the desired gravitational acceleration.
Thanks for your help. Unfortunately I haven’t gotten around to trying to implement that yet.
I have been trying to define each fluid as a different density, i.e. fluid coming from inlet1 having a density close to air and fluid coming from inlet21 and inlet22 having a density close to water. I have so far had no success with this, does anyone have any suggestions on how I can implement this?
the microFluidics2d example uses a phase-field model that might be incapable of simulating a high density ratio such as water/air. For this, you can use the model from the example “phaseSeparation3d”. It is a pseudo-potential approach that uses Carnahan-Starling EoS. With the right reduced temperature, the EoS will give you a density ratio of the water/air system. The implementation with this model is easier, too, as you will only need one lattice.
Best regards,
Tim
Author
Posts
Viewing 5 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic.
We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.Ok