verify

Contents

verify.c

Validate the options. This will become a mess!

Author

Rory Barnes (RoryBarnes)

Date

May 7 2014

Functions

int bFloatComparison(double x, double y)

Check to see if two decimals numbers are equal (1) or not (0)

int bFileExists(const char *filename)
void OverwriteExit(char cName[], char cFile[])
void DoubleLineExit(char cFile1[], char cFile2[], int iLine1, int iLine2)
void VerifyOrbitExit(char cName1[], char cName2[], char cFile1[], char cFile2[], int iLine1, int iLine2, int iVerbose)
void VerifyBodyExit(char cName1[], char cName2[], char cFile[], int iLine1, int iLine2, int iVerbose)
void TripleLineExit(char cFile[], int iLine1, int iLine2, int iLine3)

Print three lines that are in conflict Only called if iVerbose >= VERBERR

void VerifyTripleExit(char cName1[], char cName2[], char cName3[], int iLine1, int iLine2, int iLine3, char cFile[], int iVerbose)
void VerifyTwoOfThreeExit(char cName1[], char cName2[], char cName3[], int iLine1, int iLine2, int iLine3, char cFile[], int iVerbose)
void VerifyDynEllip(BODY *body, CONTROL *control, OPTIONS *options, char cFile[], int iBody, int iVerbose)
void VerifyNames(BODY *body, CONTROL *control, OPTIONS *options)

Verify the user did not use the same name for two bodies.

void VerifyOrbit(BODY *body, CONTROL *control, FILES files, OPTIONS *options, int iBody)
void IntegrationWarning(char cName1[], char cName2[], char cName3[], char cFile[], int iLine, int iVerbose)
void VerifyIntegration(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, fnIntegrate *fnOneStep)
void VerifyMassRad(BODY *body, CONTROL *control, OPTIONS *options, char cFile[], int iBody)
void VerifyObliquity(BODY *body, OPTIONS *options, int iBody, int iVerbose)
void VerifyRotationGeneral(BODY *body, OPTIONS *options, char cFile[], int iBody, int iVerbose)
void VerifyImK2Env(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, int iBody)
void VerifyImK2Ocean(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, int iBody)
void VerifyImK2Mantle(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, UPDATE *update, int iBody)
void VerifyImK2(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, UPDATE *update, int iBody)

Verify all input parameters related to tidal energy dissipation (Power) into all regions of a planet. The parameter Im(k2) is set by the orbit and the internal temperature in the layer, which is set by the tidal, secular, and radiogenic heating rates. The heating is divided into layers: 1) Mantle, 2) Ocean, and 3) Envelope, and may be calculated by the EqTide, RadHeat, and/or ThermInt modules. Those modules in turn have different possibilities. By the end of this function, the values of Im(k2) in all layers and the body as a whole are set.

void InitializeConstants(BODY *body, UPDATE *update, CONTROL *control, SYSTEM *system, OPTIONS *options)

Initialize angular momentum for energy for conservation checks. Initialize here so anything that changes E, J is monitored to ensure conservation

void fnNullDerivatives(BODY *body, EVOLVE *evolve, MODULE *module, UPDATE *update, fnUpdateVariable ***fnUpdate)
void VerifyMantle(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, int iBody)
void VerifyOcean(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, int iBody)
void VerifyEnvelope(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, int iBody)
void VerifyLayers(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, int iBody)
void VerifyAge(BODY *body, CONTROL *control, OPTIONS *options)
void VerifyOptions(BODY *body, CONTROL *control, FILES *files, MODULE *module, OPTIONS *options, OUTPUT *output, SYSTEM *system, UPDATE *update, fnIntegrate *fnOneStep, fnUpdateVariable ****fnUpdate)

Master Verify subroutine

This function validates the input options. After this function, the structs are prepared for integration.

verify.h

Validate the options. This will become a mess!

Author

Rory Barnes (RoryBarnes)

Date

May 7 2014