Define a new field and output it with time

Questions and remarks about code_saturne usage
Forum rules
Please read the forum usage recommendations before posting.
Post Reply
yang
Posts: 16
Joined: Thu Jul 14, 2022 3:39 pm

Define a new field and output it with time

Post by yang »

Hi team,

In Code_Saturne v7.0.2, I'd like to monitor the change of kinetic energy in whole field with time. Specifically, in each time step, Code_Saturne calculates kinetic energy in whole field, and output these values into a file. Then, I can plot its change with time. Could you share an example for this function? Thanks!

Best wishes,
Yang
yang
Posts: 16
Joined: Thu Jul 14, 2022 3:39 pm

Re: Define a new field and output it with time

Post by yang »

?
Yvan Fournier
Posts: 4157
Joined: Mon Feb 20, 2012 3:25 pm

Re: Define a new field and output it with time

Post by Yvan Fournier »

Hello,

It seems no one has an example ready for this.

But it should be quite simple to do this. You can even create the extra field with the GUI (in the post-processing section), and you then need to compute its values in a user-defined function, such as cs_user_extra_operations.c.

Best regards,

Yvan
Post Reply