Hi Zuoran,
If the heat transfer fluid is user-defined, SAM uses a lookup function to interpolate between the values provided in a table of fluid properties. For the physical trough model, you can find an example of a user-defined HTF table for the
Storage HTF fluid input on the Thermal Storage input page: Choose the user-defined fluid from the list, and then click
Edit to see the table.
The lookup function Linear_Interp::linear_1D_interp() interpolates these table values and is defined in tcs/interpolation_routines.cpp:
github.com/NREL/ssc/blob/develop/tcs/interpolation_routines.cpp#L65.
For non-user-defined heat transfer fluids, the property functions are in tcs/htf_props.cpp:
github.com/NREL/ssc/blob/develop/tcs/htf_props.cpp#L309.
Functions from the user interface call intermediate functions in the SSC code like the ones here,
github.com/NREL/ssc/blob/develop/ssc/cmod_ui_tes_calcs.cpp#L128, but the final calls are to htf_props.cpp.
Best regards,
Paul.