Skip to content

Reply To: Unit conversion

#5710
Gloriousface
Participant

Hello,everuone

When I read the help document, I found that the analyticF function is applicable to the SI unit. Can I ask the following lines of code to set the speed and pressure in the SI system of units?

AnalyticalConst2D<T,T> ux( 0. );
AnalyticalConst2D<T,T> uy( 0. );
AnalyticalConst2D<T,T> rho( 1. );
AnalyticalComposed2D<T,T> u( ux,uy );

The calculation of LBM uses lattice units. These lines of code for setting the initial equilibrium distribution function directly use international units. Is there a conversion mechanism?

sLattice.defineRhoU( bulkIndicator, rho, u );
sLattice.iniEquilibrium( bulkIndicator, rho, u );