DualSPHysics / DesignSPHysics

Module for FreeCAD intended to use with DualSPHysics fluid simulator.
Other
111 stars 40 forks source link

Cannot set fluid initial velocity #180

Closed Ivan-Voronyuk closed 9 months ago

Ivan-Voronyuk commented 9 months ago

Fluid initial velocity is zero, no matter what I did.

I`m trying to make a cumulative stream simulation. For this I need to have fluid with initial velocity set to 3 m/s For testing, I created a ball, set type to "fluid" and fill mode to "full". Then I tried every possible combination of positive numbers, negative numbers and zeros I could pass to "Initials" but every time the generated setup in paraview and also the simulation had zero initial velocity.

In project_name_Def.xml file I do have

<special>
<initialize>
    <fluidvelocity mkfluid="0">
        <direction x="1.0" y="1.0" z="1.0" />
        <velocity v="1.0" comment="Uniform profile velocity" units_comment="m/s" />
    </fluidvelocity>
    <fluidvelocity mkfluid="1">
        <direction x="1.0" y="1.0" z="1.0" />
        <velocity3 v="1.0" v2="1.0" v3="1.0" z="0.0" z2="1.0" z3="2.0" comment="Parabolic profile velocity" units_comment="m/s" />
    </fluidvelocity>
</initialize>
</special>

Also a pic from paraview for this setup: image [EDIT] I use 2D setup. Maybe this is the reason.

Ivan-Voronyuk commented 9 months ago

Paraview does not show initial velocity when opened from "FenCase". After some switching between 2D and 3D I managed to make it work. Now everything works perfectly.