output

Contents

output.c

Subroutines for output and logging.

Author

Rory Barnes (RoryBarnes)

Date

May 7 2014

Functions

void WriteAge(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteBodyType(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteCOPP(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteCriticalSemi(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteCumulativeXUVFlux(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteDeltaTime(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteDensity(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteEscapeVelocity(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteHecc(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteHZLimitDryRunaway(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteHZLimitRecentVenus(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteHZLimitRunawayGreenhouse(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteHZLimitMoistGreenhouse(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteHZLimitMaxGreenhouse(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteHZLimitEarlyMars(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteBodyInc(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteInstellation(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteK2Man(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteImK2Man(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteKecc(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteBodyLongA(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteLongP(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteBodyArgP(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteLXUVTot(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteMass(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteObliquity(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteBodyPrecA(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteOrbAngMom(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteOrbEcc(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteLostEng(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteOrbEnergy(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteOrbMeanMotion(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteOrbPeriod(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteOrbSemi(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteRadius(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteRadGyra(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteRotAngMom(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteRotKinEnergy(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteRotRate(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteRotPer(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteRotVel(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteSurfaceEnergyFlux(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)

SurfaceEnergyFluc is complicated as it can be determined by thermint, radheat, and/or eqtide. Furthermore, eqtide is complicated by heat sources in the solid interior, ocean, and/envelope.

void WriteTidalQ(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteTidalQMantle(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteTime(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteTotAngMom(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteLostAngMom(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteTotEnergy(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WritePotEnergy(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteKinEnergy(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteOrbKinEnergy(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteOrbPotEnergy(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteTotOrbEnergy(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteImK2(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteK2(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteXobl(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteYobl(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteZobl(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteMeanAnomaly(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void WriteMeanLongitude(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UNITS *units, UPDATE *update, int iBody, double *dTmp, char **cUnit)
void InitializeOutputGeneral(OUTPUT *output, fnWriteOutput fnWrite[])
void UnitsSI(UNITS *units)
void WriteLogEntry(BODY *body, CONTROL *control, OUTPUT *output, SYSTEM *system, UPDATE *update, fnWriteOutput fnWrite, FILE *fp, int iBody)
void LogUnits(FILE *fp)
void LogIntegration(CONTROL *control, FILE *fp)
void LogHalt(CONTROL *control, FILE *fp)
void LogBodyRelations(CONTROL *control, FILE *fp, int iBody)
void LogOutputOrder(BODY *body, CONTROL *control, FILES *files, OUTPUT *output, SYSTEM *system, UPDATE *update, fnWriteOutput fnWrite[], FILE *fp, int iBody)
void LogGridOutput(BODY *body, CONTROL *control, FILES *files, OUTPUT *output, SYSTEM *system, UPDATE *update, fnWriteOutput fnWrite[], FILE *fp, int iBody)
void LogOptions(CONTROL *control, FILES *files, MODULE *module, SYSTEM *system, FILE *fp)
void LogSystem(BODY *body, CONTROL *control, MODULE *module, OUTPUT *output, SYSTEM *system, UPDATE *update, fnWriteOutput fnWrite[], FILE *fp)
void LogBody(BODY *body, CONTROL *control, FILES *files, MODULE *module, OUTPUT *output, SYSTEM *system, fnWriteOutput fnWrite[], FILE *fp, UPDATE *update)
void WriteLog(BODY *body, CONTROL *control, FILES *files, MODULE *module, OPTIONS *options, OUTPUT *output, SYSTEM *system, UPDATE *update, fnUpdateVariable ***fnUpdate, fnWriteOutput fnWrite[], int iEnd)
void WriteOutput(BODY *body, CONTROL *control, FILES *files, OUTPUT *output, SYSTEM *system, UPDATE *update, fnWriteOutput *fnWrite)
void InitializeOutput(FILES *files, OUTPUT *output, fnWriteOutput fnWrite[])

output.h

Subroutines for output and logging.

To add a new output: 1) Add new definition here 2) Add output properties to InitializeOutput 3) Write new subroutine that returns desired output 4) Write new fnWriteOutput function

Author

Rory Barnes (RoryBarnes)

Date

May 7 2014

Defines

EXIT_EXE
EXIT_INPUT
EXIT_UNITS
EXIT_WRITE
EXIT_INT
EXIT_OUTPUT
VERBERR
VERBPROG
VERBINPUT
VERBUNITS
VERBALL
OUTSTART
OUTBODYSTART
OUTEND
OUT_AGE
OUT_TIME
OUT_TOTANGMOM
OUT_TOTENERGY
OUT_POTENERGY
OUT_KINENERGY
OUT_TOTORBENERGY
OUT_DT
OUT_MASS
OUT_OBL
OUT_PRECA
OUT_XOBL
OUT_YOBL
OUT_ZOBL
OUT_RADIUS
OUT_RADGYRA
OUT_ROTANGMOM
OUT_ROTKINENERGY
OUT_ROTVEL
OUT_BODYTYPE
OUT_ROTRATE
OUT_ROTPER
OUT_DENSITY
OUT_SURFENFLUX
OUT_TIDALQ
OUT_IMK2
OUT_K2
OUT_K2MAN
OUT_IMK2MAN
OUT_TIDALQMAN
OUT_VISCUMAN
OUT_HECC
OUT_HZLIMDRYRUNAWAY

Recent Venus HZ Limit

OUT_HZLIMRECVENUS

Recent Venus HZ Limit

OUT_HZLIMRUNAWAY

Runaway Greenhouse HZ Limit

OUT_HZLIMMOIST

Moist Greenhouse HZ Limit

OUT_HZLIMMAX

Maximum Venus HZ Limit

OUT_HZLIMEARLYMARS

Early Mars HZ Limit

OUT_INSTELLATION
OUT_KECC
OUT_ORBECC
OUT_ORBEN
OUT_ORBMEANMOTION
OUT_ORBPER
OUT_ORBSEMI
OUT_CRITSEMI
OUT_COPP
OUT_ORBANGMOM
OUT_ARGP
OUT_MEANA
OUT_INC
OUT_LONGA
OUT_MEANL
OUT_LONGP
OUT_LXUVTOT

Total XUV Luminosity from the star

OUT_ORBKINENERGY
OUT_ORBPOTENERGY
OUT_ORBENERGY
OUT_LOSTENG
OUT_LOSTANGMOM
OUT_ESCAPEVELOCITY