Reply To: Compabilitities of superLattticeIntegralF2D for DynOmegaD2Q9Descriptor
OpenLB – Open Source Lattice Boltzmann Code › Forums › on OpenLB › General Topics › Compabilitities of superLattticeIntegralF2D for DynOmegaD2Q9Descriptor › Reply To: Compabilitities of superLattticeIntegralF2D for DynOmegaD2Q9Descriptor
Dear Junwei Guo,
BlockLatticePhysWallShearStress2D uses a constant relaxation frequency only in _physFactor for unit conversion. Its calculation can just be moved into the operator() for a cell dependant calculation.
AFAIK your descriptor DynOmegaD2Q9 stores omega in the external field and can therefore be accessed by a template variable.
Try changing the source of both Super- and BlockLatticePhysWallShearStress to provide a FIELD template argument. For a generic example see how its done in Super- and BlockLatticeField2D.
Then just replace omega in
_physFactor = -omega * descriptors::invCs2<T,DESCRIPTOR>() / dt * this->_converter.getPhysDensity() * this->_converter.getPhysViscosity();
with the computeField function for your desired external field and move the line to the top of the operator().
Best,
Jonathan