spinbody

Contents

spinbody.c

Subroutines that control the integration of the N Body simulation.

Author

Hayden Smotherman (smotherh)

Date

Feb 21 2017

Functions

void BodyCopySpiNBody(BODY *dest, BODY *src, int iFoo, int iNumBodies, int iBody)
void InitializeUpdateTmpBodySpiNBody(BODY *body, CONTROL *control, UPDATE *update, int iBody)
void ReadPositionX(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, int iFile)
void ReadPositionY(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, int iFile)
void ReadPositionZ(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, int iFile)
void ReadVelX(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, int iFile)
void ReadVelY(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, int iFile)
void ReadVelZ(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, int iFile)
void ReadMeanA(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, int iFile)
void ReadUseOrbParams(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, int iFile)
void InitializeOptionsSpiNBody(OPTIONS *options, fnReadOption fnRead[])
void ReadOptionsSpiNBody(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, SYSTEM *system, fnReadOption fnRead[], int iBody)
void InitializeBodySpiNBody(BODY *body, CONTROL *control, UPDATE *update, int iBody, int iModule)
void InitializeUpdateSpiNBody(BODY *body, UPDATE *update, int iBody)
void VerifyPositionX(BODY *body, OPTIONS *options, UPDATE *update, double dAge, int iBody)
void VerifyPositionY(BODY *body, OPTIONS *options, UPDATE *update, double dAge, int iBody)
void VerifyPositionZ(BODY *body, OPTIONS *options, UPDATE *update, double dAge, int iBody)
void VerifyVelX(BODY *body, OPTIONS *options, UPDATE *update, double dAge, int iBody)
void VerifyVelY(BODY *body, OPTIONS *options, UPDATE *update, double dAge, int iBody)
void VerifyVelZ(BODY *body, OPTIONS *options, UPDATE *update, double dAge, int iBody)
void VerifyGM(BODY *body, CONTROL *control)
void AssignSpiNBodyDerivatives(BODY *body, EVOLVE *evolve, UPDATE *update, fnUpdateVariable ***fnUpdate, int iBody)
void NullSpiNBodyDerivatives(BODY *body, EVOLVE *evolve, UPDATE *update, fnUpdateVariable ***fnUpdate, int iBody)
void VerifySpiNBody(BODY *body, CONTROL *control, FILES *files, OPTIONS *options, OUTPUT *output, SYSTEM *system, UPDATE *update, int iBody, int iModule)
int fbHaltMaxMutualIncSpiNBody(BODY *body, EVOLVE *evolve, HALT *halt, IO *io, UPDATE *update, fnUpdateVariable ***fnUpdate, int iBody)

Check the maximum allowed mutual inclination.

Parameters:
  • body – A pointer to the current BODY instance

  • control – A pointer to the integration CONTROL instance

  • files – A pointer to the array of input FILES

  • options – A pointer to the OPTIONS instance

  • system – A pointer to the SYSTEM instance

  • iFile – The current file number

Returns:

TRUE if one mutual incliantion in a system is larger than dHaltMaxMutualInc, FALSE if not

void OrbElems2Helio(BODY *body, int iBody)
void Helio2Bary(BODY *body, int iNumBodies, int iBody)
void Bary2Helio(BODY *body, int iBody)
void Bary2OrbElems(BODY *body, int iBody)
void CountHaltsSpiNBody(HALT *halt, int *iHalt)
void VerifyHaltSpiNBody(BODY *body, CONTROL *control, OPTIONS *options, int iBody, int *iHalt)
void WritePositionX(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WritePositionY(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WritePositionZ(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteVelX(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteVelY(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteVelZ(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteInclinationSpinBody(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteLongASpinBody(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void InitializeOutputSpiNBody(OUTPUT *output, fnWriteOutput fnWrite[])
void fnForceBehaviorSpiNBody(BODY *body, MODULE *module, EVOLVE *evolve, IO *io, SYSTEM *system, UPDATE *update, fnUpdateVariable ***fnUpdate, int iBody, int iModule)
void PropsAuxSpiNBody(BODY *body, EVOLVE *evolve, IO *io, UPDATE *update, int iBody)
void FinalizeUpdateVelXSpiNBody(BODY *body, UPDATE *update, int *iEqn, int iVar, int iBody, int iFoo)
void FinalizeUpdateVelYSpiNBody(BODY *body, UPDATE *update, int *iEqn, int iVar, int iBody, int iFoo)
void FinalizeUpdateVelZSpiNBody(BODY *body, UPDATE *update, int *iEqn, int iVar, int iBody, int iFoo)
void FinalizeUpdatePositionXSpiNBody(BODY *body, UPDATE *update, int *iEqn, int iVar, int iBody, int iFoo)
void FinalizeUpdatePositionYSpiNBody(BODY *body, UPDATE *update, int *iEqn, int iVar, int iBody, int iFoo)
void FinalizeUpdatePositionZSpiNBody(BODY *body, UPDATE *update, int *iEqn, int iVar, int iBody, int iFoo)
void LogBodySpiNBody(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UPDATE *update, fnWriteOutput fnWrite[], FILE *fp, int iBody)
void LogSpiNBody(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UPDATE *update, fnWriteOutput fnWrite[], FILE *fp)
void AddModuleSpiNBody(CONTROL *control, MODULE *module, int iBody, int iModule)
double fdDPositionXDt(BODY *body, SYSTEM *system, int *iaBody)
double fdDPositionYDt(BODY *body, SYSTEM *system, int *iaBody)
double fdDPositionZDt(BODY *body, SYSTEM *system, int *iaBody)
double fdDVelXDt(BODY *body, SYSTEM *system, int *iaBody)
double fdDVelYDt(BODY *body, SYSTEM *system, int *iaBody)
double fdDVelZDt(BODY *body, SYSTEM *system, int *iaBody)

spinbody.h

Subroutines that control the integration of the N Body simulation.

Author

Hayden Smotherman (smotherh)

Date

Feb 21 2017

Defines

OPTSTARTSPINBODY
OPTENDSPINBODY
OPT_POSITIONXSPINBODY
OPT_POSITIONYSPINBODY
OPT_POSITIONZSPINBODY
OPT_VELXSPINBODY
OPT_VELYSPINBODY
OPT_VELZSPINBODY
OPT_MEANA
OPT_USEORBPARAMS
OUTSTARTSPINBODY
OUTENDSPINBODY
OUTBODYSTARTSPINBODY
OUT_POSITIONXSPINBODY
OUT_POSITIONYSPINBODY
OUT_POSITIONZSPINBODY
OUT_VELXSPINBODY
OUT_VELYSPINBODY
OUT_VELZSPINBODY
OUT_INCSPINBODY
OUT_LONGASPINBODY