user variable at boudary

Questions and remarks about code_saturne usage
Forum rules
Please read the forum usage recommendations before posting.
Post Reply
bachlinh
Posts: 28
Joined: Mon Oct 02, 2017 9:31 am

user variable at boudary

Post by bachlinh »

Hello guys,
I defined a new scalar in code saturne. Can anyone show me how to get its value at boundary after each iteration ?
I found only these values at cells by : cs_field_by_name .
Thank you,
Yvan Fournier
Posts: 4093
Joined: Mon Feb 20, 2012 3:25 pm

Re: user variable at boudary

Post by Yvan Fournier »

Hello,

Is your added scalar a solved variable (I suppose so) ? In this case, in cs_user_parameters.c, you need to call cs_parameters_add_boundary_values. Check the example of cs_user_parameters.c for this.

Regards,

Yvan
bachlinh
Posts: 28
Joined: Mon Oct 02, 2017 9:31 am

Re: user variable at boudary

Post by bachlinh »

Thank you for your answer,
I found in the cs_user_parameters.c the function you said.
I added a scalar solved variable by using GUI.
And I also want to know which function or expression (like cs_field_by_name) to access its values at boundary (by its name or its id) for my calculations ?
I'm newbie in code saturne so i'm sorry for many question.
Regards,
Bach Linh
Post Reply