The FARGO_THORIN code developer's guide
|
Contains routines used by the hydrodynamical loop. More...
#include "fargo.h"
Go to the source code of this file.
Macros | |
#define | CFLSECURITY 0.5 /* Maximum fraction of zone size */ |
#define | CVNR 1.41 /* Shocks are spread over CVNR zones: */ |
Functions | |
boolean | DetectCrash (PolarGrid *array) |
void | FillPolar1DArrays () |
void | InitEuler (PolarGrid *Rho, PolarGrid *Vr, PolarGrid *Vt, PolarGrid *En) |
real | min2 (real a, real b) |
real | max2 (real a, real b) |
void | ActualiseGas (PolarGrid *array, PolarGrid *newarray) |
void | AlgoGas (PolarGrid *Rho, PolarGrid *Vrad, PolarGrid *Vtheta, PolarGrid *Energy, PolarGrid *Label, PlanetarySystem *sys, struct reb_simulation *rsim) |
void | SubStep1 (PolarGrid *Vrad, PolarGrid *Vtheta, PolarGrid *Rho, real dt) |
void | SubStep2 (PolarGrid *Rho, PolarGrid *Energy, real dt) |
void | SubStep3 (PolarGrid *Rho, real dt) |
Numerical step reponsible for the energy update. More... | |
int | ConditionCFL (PolarGrid *Vrad, PolarGrid *Vtheta, real deltaT) |
void | ComputeSoundSpeed (PolarGrid *Rho, PolarGrid *Energy) |
Updates the sound speed over the mesh. More... | |
void | ComputePressureField (PolarGrid *Rho, PolarGrid *Energy) |
Updates the pressure over the mesh. More... | |
void | ComputeTemperatureField (PolarGrid *Rho, PolarGrid *Energy) |
Updates the temperature over the mesh. More... | |
Variables | |
static PolarGrid * | TemperInt |
static PolarGrid * | VradNew |
static PolarGrid * | VradInt |
static PolarGrid * | VthetaNew |
static PolarGrid * | VthetaInt |
static real | timeCRASH |
boolean | Corotating |
static PolarGrid * | EnergyNew |
static PolarGrid * | EnergyInt |
static int | AlreadyCrashed = 0 |
static int | GasTimeStepsCFL |
int | TimeStep |
boolean | FastTransport |
boolean | IsDisk |
Contains routines used by the hydrodynamical loop.
More specifically, it contains the main loop itself and all the source term substeps (with the exception of the evaluation of the viscous force). The transport substep is treated elsewhere.
Definition in file SourceEuler.c.
#define CFLSECURITY 0.5 /* Maximum fraction of zone size */ |
Definition at line 16 of file SourceEuler.c.
Referenced by ConditionCFL().
#define CVNR 1.41 /* Shocks are spread over CVNR zones: */ |
Definition at line 19 of file SourceEuler.c.
Referenced by ConditionCFL(), and SubStep2().
Definition at line 181 of file SourceEuler.c.
References polargrid::Nrad.
Referenced by AlgoGas().
void AlgoGas | ( | PolarGrid * | Rho, |
PolarGrid * | Vrad, | ||
PolarGrid * | Vtheta, | ||
PolarGrid * | Energy, | ||
PolarGrid * | Label, | ||
PlanetarySystem * | sys, | ||
struct reb_simulation * | rsim | ||
) |
Definition at line 199 of file SourceEuler.c.
References AccreteOntoPlanets(), AccretePebblesOntoPlanets(), ActualiseGas(), AdvanceSystemFromDisk(), AdvanceSystemRebound(), AlreadyCrashed, ApplyBoundaryCondition(), CommunicateBoundaries(), ComputePressureField(), ComputeSoundSpeed(), ComputeTemperatureField(), ConditionCFL(), Corotating, CorrectPebblesVtheta(), CorrectVtheta(), CriticalCharTime(), DetectCrash(), DetectCrashPebbles(), DiffusiveParticles, domega, DT, EnergyEq, EvolvePebbleDisk(), FillForcesArrays(), GasTimeStepsCFL, GET, GetPsysInfo(), GetPsysInfoFromRsim(), IsDisk, MARK, MassTaper, MASSTAPER, masterprint(), MinStepForRebound(), MPI_Allreduce(), MPI_COMM_WORLD, MPI_INT, MPI_MAX, NO, OmegaFrame, ParametricAccretion(), ParticleDiffusion(), Pebbles, PebbleStokesNumbers(), PhysicalTime, PrescribedAccretion, RotatePsys(), SloppyCFL, SourceTermsPebbles(), SubStep1(), SubStep1Pebbles(), SubStep2(), SubStep3(), SynchronizeFargoRebound(), SynchronizePebbleDisc(), Temperature, timeCRASH, Transport(), UpdateDivVelocAndStressTensor(), WriteDiskPolar(), and YES.
Updates the pressure over the mesh.
Definition at line 708 of file SourceEuler.c.
References ADIABIND, EnergyEq, polargrid::Field, Pressure, and SoundSpeed.
Referenced by AlgoGas(), and InitEuler().
Updates the sound speed over the mesh.
Definition at line 683 of file SourceEuler.c.
References ADIABIND, AspectRatio(), EnergyEq, polargrid::Field, FLARINGINDEX, G, globcsvec, mpi_make1Dprofile(), Rmed, and SoundSpeed.
Referenced by AlgoGas(), and InitEuler().
Updates the temperature over the mesh.
Definition at line 733 of file SourceEuler.c.
References ADIABIND, EnergyEq, polargrid::Field, GASCONST, MOLWEIGHT, Pressure, and Temperature.
Referenced by AlgoGas(), and InitEuler().
Definition at line 574 of file SourceEuler.c.
References CFLSECURITY, CPU_Rank, CVNR, debug, FastTransport, polargrid::Field, invdtpeb_sq, invdtreb_sq, InvRmed, MAX1D, max2(), Max_or_active, MaxMO_or_active, min2(), NSEC, polargrid::Nsec, One_or_active, Pebbles, PI, Rinf, Rmed, Rsup, SoundSpeed, YES, and Zero_or_active.
Referenced by AlgoGas().
Definition at line 37 of file SourceEuler.c.
Referenced by AlgoGas().
void FillPolar1DArrays | ( | ) |
Definition at line 57 of file SourceEuler.c.
References CPU_Master, GLOBALNRAD, GlobalRmed, IMIN, InvDiffRmed, InvDiffRsup, InvRinf, InvRmed, InvSurf, LogGrid, mastererr(), NRAD, NSEC, OmegaInv, OUTPUTDIR, PI, prs_exit(), Radii, Rinf, RMAX, Rmed, Rmed2, RMIN, Rsup, Surf, and YES.
Referenced by InitEuler().
Definition at line 122 of file SourceEuler.c.
References ADIABIND, ComputePressureField(), ComputeSoundSpeed(), ComputeTemperatureField(), CreatePolarGrid(), Damping, DampInit, EnergyEq, FillEnergy(), FillPolar1DArrays(), FillSigma(), FillVtheta(), GravAccelRad, GravAccelTheta, InitGasDensityEnergy(), InitGasVelocity(), InitPebbleArrays(), InitRadiatDiffusionFields(), InitTransport(), InitViscosity(), NRAD, NSEC, ParametricCooling, PebbleGravAccelRad, PebbleGravAccelTheta, Pebbles, Pressure, Qplus, RhoInt, RhoStar, SetWaveKillingZones(), SoundSpeed, SQRT_ADIABIND_INV, Temperature, Torque, and TorqueDensity.
Definition at line 173 of file SourceEuler.c.
Referenced by ConditionCFL().
Definition at line 166 of file SourceEuler.c.
Referenced by ConditionCFL().
Definition at line 304 of file SourceEuler.c.
References BackReaction, Damping, DragForceRad, DragForceTheta, polargrid::Field, GasAccelrad, GasAcceltheta, GravAccelRad, GravAccelTheta, IMPOSEDDISKDRIFT, ImposeKeplerianEdges(), InvDiffRmed, InvRinf, polargrid::Nrad, OmegaFrame, Pebbles, PI, Pressure, Rinf, Rmed, SIGMASLOPE, UpdateDivVelocAndStressTensor(), and UpdateVelocityWithViscousTerms().
Referenced by AlgoGas().
Definition at line 402 of file SourceEuler.c.
References CVNR, EnergyEq, polargrid::Field, InvDiffRmed, InvDiffRsup, polargrid::Nrad, polargrid::Nsec, PI, RhoInt, and Rmed.
Referenced by AlgoGas().
Numerical step reponsible for the energy update.
Calls the energy equation solver.
Definition at line 493 of file SourceEuler.c.
References ADIABIND, CoolingTimeMed, DivergenceVelocity, EnergyMed, polargrid::Field, FViscosity(), ImplicitRadiativeDiffusion(), ParametricCooling, Qplus, QplusMed, Rmed, SigmaMed, TAUPP, TAURP, and TAURR.
Referenced by AlgoGas().
|
static |
Definition at line 31 of file SourceEuler.c.
Referenced by AlgoGas().
boolean Corotating |
Definition at line 30 of file Interpret.c.
Referenced by AlgoGas(), and ReadVariables().
|
static |
Definition at line 29 of file SourceEuler.c.
|
static |
Definition at line 29 of file SourceEuler.c.
boolean FastTransport |
Definition at line 29 of file Interpret.c.
Referenced by ConditionCFL().
|
static |
Definition at line 31 of file SourceEuler.c.
Referenced by AlgoGas().
boolean IsDisk |
Definition at line 30 of file Interpret.c.
Referenced by AlgoGas(), and ReadVariables().
|
static |
Definition at line 23 of file SourceEuler.c.
|
static |
Definition at line 26 of file SourceEuler.c.
Referenced by AlgoGas().
|
static |
Definition at line 24 of file SourceEuler.c.
|
static |
Definition at line 24 of file SourceEuler.c.
|
static |
Definition at line 25 of file SourceEuler.c.
|
static |
Definition at line 25 of file SourceEuler.c.