MATRIX calculateAvgK | ( | MATRIX | wk, | |
MAP_DEPTH_MATRIX | K, | |||
int | kx, | |||
int | ky | |||
) |
Calculate the averaging kernel at a given kx, ky in wave space.
[in] | wk | A MATRIX containing the solution weights at a specific kx,ky in wave space. |
[in] | K | A MAP_DEPTH_MATRIX containing the kernels. |
[in] | kx | The x-coordinate in wave space. |
[in] | ky | The y-coordinate in wave space. |
void calculateDerivedValues | ( | Model * | model, | |
MAP_DEPTH_MATRIX | K, | |||
MAP_DEPTH_MATRIX | tau, | |||
MAP_DEPTH_MATRIX | Lambda, | |||
bool | DValueShift | |||
) |
Calculate q, Averaging Kernel and noise squared.
[in] | model | A Model object. |
[in] | K | Kernel matrix |
[in] | tau | Travel-map matrix |
[in] | Lambda | Travel-map noise covariance matrix |
[in] | DValueShift | Boolean indicating whether to shift output matrices q, and averaging kernel, and noise. |
void calculateDerivedValuesNoQ | ( | Model * | model, | |
MAP_DEPTH_MATRIX | K, | |||
MAP_DEPTH_MATRIX | Lambda, | |||
bool | DValueShift | |||
) |
MATRIX calculateNoiseK | ( | MATRIX | wk, | |
MAP_DEPTH_MATRIX | Lambda, | |||
int | kx, | |||
int | ky | |||
) |
Calculate the noise at a given kx, ky in wave space.
[in] | wk | A MATRIX containing the solution weights at a specific kx,ky in wave space. |
[in] | Lambda | A MAP_DEPTH_MATRIX containing the input covariance. |
[in] | kx | The x-coordinate in wave space. |
[in] | ky | The y-coordinate in wave space. |
MATRIX calculateQK | ( | MATRIX | wk, | |
MAP_DEPTH_MATRIX | tau, | |||
int | kx, | |||
int | ky | |||
) |
Calculate the model, q, at a given kx, ky in wave space.
[in] | wk | A MATRIX containing the solution weights at a specific kx,ky in wave space. |
[in] | tau | Travel-map matrix |
[in] | kx | The x-coordinate in wave space. |
[in] | ky | The y-coordinate in wave space. |
void calculateQValues | ( | Model * | model, | |
MAP_DEPTH_MATRIX | tau, | |||
bool | DValueShift | |||
) |
Calculate q
[in] | model | A Model object. |
[in] | tau | Travel-map matrix |
[in] | DValueShift | Boolean indicating whether to shift output matrix q. |
void clearParameters | ( | Model * | model | ) |
Clear parameter values (mu and sigma) in the model. Output FITS files will not have sigma and mu parameters in the header.
[in,out] | model | A Model object. |
void freeModel | ( | Model * | model | ) |
Free all memory associated with outputModel.
void initializeCalcQOutputModel | ( | Model * | model, | |
MAP_DEPTH_MATRIX | w | |||
) |
void initializeForwardOutputModel | ( | Model * | model, | |
MAP_DEPTH_MATRIX | kernelTdm | |||
) |
Initialize output model for use by forward calculation
[in,out] | model | Pointer to Model structure |
[in] | kernelTdm | Matrix containing 3D Kernel. |
void initializeModel | ( | Model * | model, | |
int | X, | |||
int | Y, | |||
int | M, | |||
int | Z | |||
) |
void initializeOutputModel | ( | Model * | model, | |
MAP_DEPTH_MATRIX | kernelTdm | |||
) |
Initialize output model for use by RLS inversion
[in,out] | model | Pointer to Model structure |
[in] | kernelTdm | Matrix containing 3D RLS Kernel. |
Save inversion solution, b, for RLS 1D.
[in,out] | model | A Model object. |
[in] | b | Solution matrix. |
[in] | nStep | Parameter step number. |
Save lambda values and kx, ky values for each wave number (RLS 3D inversion).
[in,out] | m | A Model object. |
[in] | r | Row (index into matrix). |
[in] | c | Column (index into matrix). |
[in] | kx | Value of kx at (x,y) |
[in] | ky | Value of ky at (x,y) |
[in] | lambda | Value of lambda (regularization) parameter. |
Record parameter values in the model.
[in,out] | model | A Model object. |
[in] | mu | Value for mu parameter. |
[in] | sigma | Value for sigma parameter. |
Record multiple parameter values in the model.
[in,out] | model | A Model object. |
[in] | values | Pointer to array of parameter values. NOTE: there is a special ordering to the parameters, mu, sigma, then nu (which is optional). |
[in] | nValues | How many parameter values. |
void useNoMaps | ( | Model * | model | ) |
void writeAVectors1d | ( | Model * | model, | |
BaseDirectory * | baseName, | |||
Float | lambda | |||
) |
Write the Averaging Kernel data for 1d problem.
[in] | model | The OutputModel containing the Averaging Kernel. |
[in] | baseName | BaseDirectory structure for managing output file name. |
[in] | lambda | Which lambda value was used for this solution. |
void writeAvgKern | ( | Model * | model, | |
BaseDirectory * | baseName | |||
) |
Write averaging kernel to file for OLA inversion.
[in,out] | model | A Model object. |
[in] | baseName | BaseDirectory structure for managing output file name. |
void writeAvgKernValues3d | ( | Model * | model, | |
BaseDirectory * | baseName | |||
) |
Write averaging kernels and error covariance matrices for RLS 3D inversion.
[in,out] | model | A Model object. |
[in] | baseName | BaseDirectory structure for managing output file name. |
void writeBVectors1d | ( | Model * | model, | |
BaseDirectory * | baseName | |||
) |
Write solution matrix for RLS 1D inversion.
[in,out] | model | A Model object. |
[in] | baseName | BaseDirectory structure for managing output file name. |
void writeBVectors3d | ( | Model * | model, | |
BaseDirectory * | baseName | |||
) |
Write solution B vectors to FITS files matrix for RLS 3D inversion.
[in,out] | model | A Model object. |
[in] | baseName | BaseDirectory structure for managing output file name. |
void writeCovVectors1d | ( | Model * | model, | |
BaseDirectory * | baseName, | |||
Float | lambda | |||
) |
Write the Error Covariance data for 1d problem.
[in] | model | Model structure containing the Error Covariance. |
[in] | baseName | Which lambda step was used for this solution. |
[in] | lambda | Which lambda value was used for this solution. |
void writeDTildaValues3d | ( | Model * | model, | |
BaseDirectory * | baseName, | |||
bool | useFT | |||
) |
Write d~ matrices for RLS 3D inversion.
[in,out] | model | A Model object. |
[in] | baseName | BaseDirectory structure for managing output file name. |
[in] | useFT | Boolean indicates if d~ matrices should be Fourier transformed. |
void writeGridValues3d | ( | Model * | model, | |
BaseDirectory * | baseName | |||
) |
Write lambda values and kx, ky values for each wave number (RLS 3D inversion). Write kxGridValues, kyGridValues and lambdaGridValues at each grid point to FITS files matrix for RLS 3D inversion.
[in,out] | model | A Model object. |
[in] | baseName | BaseDirectory structure for managing output file name. |
void writeNoise | ( | Model * | model, | |
BaseDirectory * | baseName | |||
) |
Write noise estimate to file for OLA inversion.
[in,out] | model | A Model object. |
[in] | baseName | BaseDirectory structure for managing output file name. |
void writeQ | ( | Model * | model, | |
BaseDirectory * | baseName | |||
) |
Write solution, q, for OLA inversion.
[in,out] | model | A Model object. |
[in] | baseName | BaseDirectory structure for managing output file name. |
void writeW | ( | Model * | model, | |
BaseDirectory * | baseName | |||
) |
Write OLA inversion weights, w, to file.
[in,out] | model | A Model object. |
[in] | baseName | BaseDirectory structure for managing output file name. |