Hi all,
Just a quick question. I would like to get the thermal conductivity (or thermal diffusivity as i'm using the enthalpy equation) to use in cs_user_parameters.c.
I try to find it in the doxygen and userguide but seems couldn't find the variable name for it.
Best,
Muhsin
Thermal conductivity/diffusivity in C
Forum rules
Please read the forum usage recommendations before posting.
Please read the forum usage recommendations before posting.
-
- Posts: 284
- Joined: Fri Dec 04, 2015 1:42 pm
Re: Thermal conductivity/diffusivity in C
Hello,
You can check it in the user manual (search for kivisl, diffusivity or conductivity)
Also check the cs_user_parameters.f90 file in the SRC/EXAMPLE directory in order to view how to access.
Regards,
Luciano
EDIT: Sorry..you ask for the C function and I have wrote about the fortran subroutine
You can check it in the user manual (search for kivisl, diffusivity or conductivity)
Also check the cs_user_parameters.f90 file in the SRC/EXAMPLE directory in order to view how to access.
Regards,
Luciano
EDIT: Sorry..you ask for the C function and I have wrote about the fortran subroutine
Re: Thermal conductivity/diffusivity in C
Hi,
Thank you for your reply.
Yes, unfortunately, I'm asking for the thermal conductivity/diffusivity in C code.
Is there anyone know the variable name for it?
Thank you for your reply.
Yes, unfortunately, I'm asking for the thermal conductivity/diffusivity in C code.
Is there anyone know the variable name for it?
-
- Posts: 4208
- Joined: Mon Feb 20, 2012 3:25 pm
Re: Thermal conductivity/diffusivity in C
Hello,
For a given variable field "c_var", to obtain the diffusivity field "c_diff" (assuming it was set to variable):
Regards,
Yvan
For a given variable field "c_var", to obtain the diffusivity field "c_diff" (assuming it was set to variable):
Code: Select all
const int kivisl = cs_field_key_id("scalar_diffusivity_id");
int diff_id = cs_field_get_key_int(c_var, kivisl)
cs_field_t *c_diff = cs_field_by_id(diff_id);
Yvan