Skip to content

Reply To: Modifying field values for neighboring cells inside a postprocessor

OpenLB – Open Source Lattice Boltzmann Code Forums on OpenLB General Topics Modifying field values for neighboring cells inside a postprocessor Reply To: Modifying field values for neighboring cells inside a postprocessor

#9846
Danial.Khazaeipoul
Participant

For anyone interested, if you encounter an issue where custom tasks added via addCustomTask<stage::> in SuperLattice are not executed, it’s because the SuperLattice<T, DESCRIPTOR>::collideAndStream() method only calls executeCustomTasks(PostStream()), meaning tasks scheduled for other stages are not automatically executed.

To resolve this, you need to explicitly invoke executeCustomTasks() for your specific stage. You can do this by modifying collideAndStream() to include the call for your stage or by calling it manually from anywhere appropriate in your application using a SuperLattice object. For example:

executeCustomTasks(PreCollide())