Welcome! Log In Create A New Profile

Advanced

Model developed through stl file

Posted by AceAce  
Model developed through stl file
February 01, 2018 11:39PM
Hi all,
I build a model through a stl file, but the simulation results are out of my expect and the average energy shown in terminal is nan or -nan. I just wonder what it means. Does that mean the calculation can not converge? how can I adjust the simu parameters?
The xml file reads as follows:
<?xml version="1.0" ?>

<geometry>
<mesh> ./channel.stl </mesh>
<!-- Inlet diameter (m). This parameter has no impact on the simulation,
and is only used to display the Reynolds number. -->
<inletDiameter> 0.0005 </inletDiameter>
<!-- Average inlet velocity in physical units (m/s). -->
<!-- averageInletVelocity> 0.071176 </averageInletVelocity -->
<averageInletVelocity> 0.012 </averageInletVelocity>

<!-- The STL geometry provided by the user has openings (inlets and outlets).
It must not be provided by the user closed. -->
<openings>
<!-- 0 means x-direction, 1 means y-direction and 2 means z-direction. -->
<sortDirection> 0 </sortDirection>
<!-- According to the sortDirection, the user provides which openings are
inlets and which are outlets. -->
<type> Inlet Outlet </type>
</openings>
</geometry>

<!-- All fluid properties are given in physical units. -->
<fluid>
<kinematicViscosity> 3.7037e-06 </kinematicViscosity>
<density> 1080 </density>
<volume> 3.0-9 </volume>
</fluid>

<numerics>
<!-- The referenceDirection is used for the resolution.
0 means x-direction, 1 means y-direction and 2 means z-direction. -->
<referenceDirection> 0 </referenceDirection>
<!-- The reference resolution is the resolution at the grid refinement level 0. -->
<referenceResolution> 800 </referenceResolution>
<nuLB> 0.00062 </nuLB>
</numerics>

<simulation>
<!-- Upper limit for time of simulation (s). The simulation may abort
earlier if convergence is reached. -->
<simTime> 1000 </simTime>
<!-- Maximum level for smooth grid refinement. -->
<maxLevel> 0 </maxLevel>
<epsilon> 1.e-1 </epsilon>

<performOutput> True </performOutput>
<doImages> True </doImages>
<!-- Extrapolation scheme for the off lattice boundary condition. -->
<useAllDirections> True </useAllDirections>
<!-- Use an off lattice boundary condition which is closer in spirit to
regularized boundary conditions. -->
<useRegularizedWall> True </useRegularizedWall>
<!-- Use an incompressible BGK model or the standard BGK model. -->
<useIncompressible> True </useIncompressible>
<!-- Use Poiseuille profile as an inflow boundary condition, or use
a simple plug profile instead. -->
<poiseuilleInlet> True </poiseuilleInlet>
<convectiveScaling> False </convectiveScaling>
</simulation>



Regards,
Si



Edited 1 time(s). Last edit at 02/01/2018 11:41PM by Ace.
Re: Model developed through stl file
February 09, 2018 05:58PM
Hi Si,
I'm not an expert on Palabos, but I faced the same issue some weeks ago. Do you obtain nan values in other physical quantities, such as density, velocity, etc.? Otherwise, the problem might be constrained to the lines where you compute the average energy. Does it start at the beginning of the simulation or it appears after some time?

According with the xml file you provided, I think that you are based on the aneurysm example. Are you using a provided example (like aneurysm.cpp) and just changing the stl file, or are you using your own palabos implementation?

In my case, the problem was that I wasn't setting the inlets and outlets properly. I figured it out by plotting the profiles at these boundaries in the first iteration. I solved it by following the aneurysm example. Let me know if that's your case so I can try to help you.

Regards,
Emilio
Sorry, you do not have permission to post/reply in this forum.