Open hrwakeford opened 5 years ago
I have the IDL code to do this for the 1D grid which can be translated to the 3D grid but I am having trouble working out where to put the information I need within the current structure of the limb-darkening code.
I think this will involve a fair amount of changes to the structure of the code but not the inputs or outputs so I will run a series of tests and show what is being done.
First is a def to calculate the tri-linear interpolation following https://en.wikipedia.org/wiki/Trilinear_interpolation
The structure of the data files for the 1D and 3D stellar models is the biggest problem here.
For the 1D stellar model data files from Kurucz the structure changes after 6000K meaning it is not a simple grid set-up posting the bounds for the grid points.
For the 3D grid it is so small any number outside the grid cannot be interpolated between using trilinear interpolation, as you cannot fully populate the corners of the cube space.
I have now created an .npz file which contains the full structure of the 1D array. This file is then loaded and searched to determine the starting line value for the needed table of intensities for each model that is used in the interpolation.
Introduce a selection of stellar models surrounding the input values rather than the closest model. This will create a grid of 8 models, two for [M/H], two for Teff, and two for logg. Then use trilinear interpolation to calculate the desired limb darkening parameter.