Reply To: Physical to Lattice time
OpenLB – Open Source Lattice Boltzmann Code › Forums › on OpenLB › General Topics › Physical to Lattice time › Reply To: Physical to Lattice time
Hello Mathias,
Thank you for your response. I used two ways to declare the values:
1) const T
2) size_t (as done in the code)
Why use size_t over const T declaration? I get the same values. I understand the rounding part as you suggested.
Here is the code snippet I tested with
cout<<“The physical simulation time is “<<maxPhysT<<endl;
size_t lattice_time = (maxPhysT/converter.getConversionFactorTime()+0.5);
OR
const T lattice_time = maxPhysT/converter.getConversionFactorTime();
cout<<“The Lattice time is “<<converter.getLatticeTime(maxPhysT)<<endl;
cout<<“The Lattice time is “<<lattice_time<<endl;
Thank you.
Yours sincerely,
Abhijeet D. Chodankar