However, all clouds must be specified at compile time which is not a good programming practice. To define it at run time, it is better to create a dictionary file constant/kinematicCloudList which specifies the clouds:

Code:

kinematicCloudNames kinematicCloud1 kinematicCloud2;

I want to read in this file in the createClouds.H file to see which clouds have to be created at runtime:

Hi guys, I also need to define kinematic clouds at runtime and I'm happy to have just found this useful topic! So very thank you both for this code.
In the posts however there is no reference to the necessary correction to the Ueqn.H file in which the contributions of individual clouds of momentum equation must be added (if I'm not wrong...).
I'm trying to do this and I've written some code. I'm not a good C++ programmer so hope someone could help me.

Dear OFrs
I am using OF 2.1.0 and looking for to write a simple macro to control writeInterval entitiy of controlDict file. For example if endTime is 10 and startTime is 0. I want to write every time directories like 1 2 3 4 5 and when runTime is greater than 5 then I want alternative directories 7 9 ..., I mean write internval should change from 1 to 2 as the time passes by 5.
I am trying to use following line controlDict file but returned with errorswriteInterval $(if(runTime.()>5) ? 2:1);

please let me know how to use macro/directives properly in this regard. And in general is there documentation available for this topic.