torque coefficient

Questions and remarks about code_saturne usage
Forum rules
Please read the forum usage recommendations before posting.
Post Reply
yany
Posts: 60
Joined: Fri Aug 04, 2017 11:02 pm

torque coefficient

Post by yany »

Hello Everyone,
I' m working on the simulation of wind turbine and I need to monitor the torque(moment) coefficient of one blade to the central axis in every time step. How can I achieve that in code_saturne? Thank you.

Yany.
Yvan Fournier
Posts: 4208
Joined: Mon Feb 20, 2012 3:25 pm

Re: torque coefficient

Post by Yvan Fournier »

Hello,

We need to add a function to do this, but in the meantime, you should activate postprocessing output of boundary stresses.

You can the integrate the torque based on those stresses either by looping over selected faces in the cs_user_extra_operations user function, or in a separate postprocessing tool such as ParaView.

Best regards,

Yvan
yany
Posts: 60
Joined: Fri Aug 04, 2017 11:02 pm

Re: torque coefficient

Post by yany »

Yvan Fournier wrote:Hello,

We need to add a function to do this, but in the meantime, you should activate postprocessing output of boundary stresses.

You can the integrate the torque based on those stresses either by looping over selected faces in the cs_user_extra_operations user function, or in a separate postprocessing tool such as ParaView.

Best regards,

Yvan
Hello Yvan,

Thanks for your reply.

The postprocessing output of boundary stress can be activated by GUI or other ways?

Now I 'm using the turbomachinery module to simulate the turbine. I found some information about Turbomachinery dedicated postprocessing functions (cs_post_moment_of_force, cs_post_turbomachinery_head) . I'm wondering if these could help me get the lift and drag coefficient and moment coefficient I need?

Thank you.

Yany.
yany
Posts: 60
Joined: Fri Aug 04, 2017 11:02 pm

Re: torque coefficient

Post by yany »

Yvan Fournier wrote:Hello,

We need to add a function to do this, but in the meantime, you should activate postprocessing output of boundary stresses.

You can the integrate the torque based on those stresses either by looping over selected faces in the cs_user_extra_operations user function, or in a separate postprocessing tool such as ParaView.

Best regards,

Yvan

Hello Yvan,

I searched the information related to the turbulence module on Code_Saturne documentation and found some functions for calculating the moment of rotor(but I'm not sure).

Image

Can I add them to the cs_user_extra_operations.f90 to get the postprocssing result I need?
Thank you very much.

Yany
Yvan Fournier
Posts: 4208
Joined: Mon Feb 20, 2012 3:25 pm

Re: torque coefficient

Post by Yvan Fournier »

Hello,

Ys, you are correct. I had forgotten about the recent additions of "utility" functions found in src/examples/cs_user_extra_operations-turbomachinery.c, also described here: http://code-saturne.org/doxygen/src/turbomachinery.html.

The moment of force should be exactly what you need.

Best regards,

Yvan
yany
Posts: 60
Joined: Fri Aug 04, 2017 11:02 pm

Re: torque coefficient

Post by yany »

Yvan Fournier wrote:Hello,

Ys, you are correct. I had forgotten about the recent additions of "utility" functions found in src/examples/cs_user_extra_operations-turbomachinery.c, also described here: http://code-saturne.org/doxygen/src/turbomachinery.html.

The moment of force should be exactly what you need.

Best regards,

Yvan
Hello Yvan,
So sorry to bother you again. But I cannot find the file src/examples/cs_user_extra_operations-turbomachinery.c in Code_satune 4.0.5. Another question is that how can I use that file? Do I need to add the related functions to the cs_user_extra_operations.f90?

All the best, Yany.
Yvan Fournier
Posts: 4208
Joined: Mon Feb 20, 2012 3:25 pm

Re: torque coefficient

Post by Yvan Fournier »

Hello,

These are new functions in version 5.0. They did not exist in version 4.0, so you need either to adapt the code from src/base/cs_post_util.c in version 5.0 to your user functions, or upgrade to version 5.0.

I recommend 5.0.

Best regards,

Yvan
yany
Posts: 60
Joined: Fri Aug 04, 2017 11:02 pm

Re: torque coefficient

Post by yany »

Yvan Fournier wrote:Hello,

These are new functions in version 5.0. They did not exist in version 4.0, so you need either to adapt the code from src/base/cs_post_util.c in version 5.0 to your user functions, or upgrade to version 5.0.

I recommend 5.0.

Best regards,

Yvan
Hello Yvan,

Thanks a lot. I have installed version 5.0 and found the file cs_user_extra_operations turbomachin
ery.c in SRC/EXAMPLES.... Could you please give me some suggestions on how to use this example file in my case?

Thank you very much.

Yany.
Post Reply