Function objects being modified when written into ControlDict

Hi everyone,

I have defined a cutting plane function object but what is written into ControlDict differs from the original input, not only messing with the order but altering the syntax! as one parenthesis is missing and causing an error when running SimpleFoam:


left: controlDict file written by Butterfly, right: text input

As you can see, the closing parenthesis from the surfaces block is missing, causing an error.

Why is this happening and how can I input such function object without syntax modification when writing ControlDict?

Thanks.

cc @TheodorosGalanos

hi @javiervinuales

please share your file so it’s easier to try with.
I note that you have in your input panel writeControl and writeInterval, perhaps for cuttingPlane function you need to replace with:
outputControl timeStep;
outputInterval 2;
(have a look here http://openfoambuilder.org/functionobjects.php#cuttingplanesampling )

I just wonder if that’s conflicting with writeControl and writeInterval of the controldict.

Best
Olivier

Hi Oliver,

Thanks for your answer. I tried to change to the suggested keywords and the written controlDict is still messed up from the original input, attached file.

Anyway, the original input should not be a problem, I manually modify the controlDict copying and pasting such input under functions {} and could run OpenFOAM manually with no error and exporting the cutting planes as expected. The problem I think is that when writting the controlDict file, Butterfly is somehow messing up the syntax.

1_Manifold_run2.gh (87.0 KB)

Cheers,

Javier

any suggestions? …