Problem generator for non-linear streaming instability in stratified disks. More...
Go to the source code of this file.
Functions | |
double | ran2 (long int *idum) |
double | Normal (long int *idum) |
Real | Erf (Real z) |
void | MultiNSH (int n, Real *tstop, Real *mratio, Real etavk, Real *uxNSH, Real *uyNSH, Real *wxNSH, Real *wyNSH) |
static Real | hst_rho_Vx_dVy (const Grid *pG, const int i, const int j, const int k) |
static void | close_ix3 (Grid *pGrid) |
static void | close_ox3 (Grid *pGrid) |
static Real | ShearingBoxPot (const Real x1, const Real x2, const Real x3) |
static int | property_limit (const Grain *gr, const GrainAux *grsub) |
user defined particle selection function (1: true; 0: false) | |
static int | property_trace (const Grain *gr, const GrainAux *grsub) |
user defined particle selection function (1: true; 0: false) | |
static int | property_type (const Grain *gr, const GrainAux *grsub) |
user defined particle selection function (1: true; 0: false) | |
static int | property_dense (const Grain *gr, const GrainAux *grsub) |
user defined particle selection function (1: true; 0: false) | |
Real | expr_dpar (const Grid *pG, const int i, const int j, const int k) |
Wrapper for particle density. | |
Real | expr_V1par (const Grid *pG, const int i, const int j, const int k) |
Wrapper for particle 1-velocity. | |
Real | expr_V2par (const Grid *pG, const int i, const int j, const int k) |
Wrapper for particle 2-velocity. | |
Real | expr_V3par (const Grid *pG, const int i, const int j, const int k) |
Wrapper for particle 3-velocity. | |
Real | expr_V2 (const Grid *pG, const int i, const int j, const int k) |
void | problem (Grid *pGrid, Domain *pDomain) |
void | problem_write_restart (Grid *pG, Domain *pD, FILE *fp) |
void | problem_read_restart (Grid *pG, Domain *pD, FILE *fp) |
Gasfun_t | get_usr_expr (const char *expr) |
Sets pointer to expression for special output data. | |
VGFunout_t | get_usr_out_fun (const char *name) |
Returns a user defined output function pointer. | |
PropFun_t | get_usr_par_prop (const char *name) |
Returns a user defined particle selection function. | |
void | gasvshift (const Real x1, const Real x2, const Real x3, Real *u1, Real *u2, Real *u3) |
Gas velocity shift. | |
void | Userforce_particle (Vector *ft, const Real x1, const Real x2, const Real x3, const Real v1, const Real v2, const Real v3) |
void | Userwork_in_loop (Grid *pGrid, Domain *pDomain) |
void | Userwork_after_loop (Grid *pGrid, Domain *pDomain) |
Variables | |
Real | vsc1 |
Real | vsc2 |
int | ipert |
Real | x1min |
Real | x1max |
Real | x2min |
Real | x2max |
Real | x3min |
Real | x3max |
Real | Lx |
Real | Ly |
Real | Lz |
Real | Lg |
long | Npar |
long | ntrack |
long | nlis |
int | mytype |
Real | dpar_thresh |
Problem generator for non-linear streaming instability in stratified disks.
PURPOSE: Problem generator for non-linear streaming instability in stratified disks. This code works in 3D ONLY. Isothermal eos is assumed, and the value etavk/iso_sound is fixed. MPI domain decomposition in x is allowed, but not in z.
Perturbation modes:
Should be configured using --enable-shearing-box and --with-eos=isothermal. FARGO is recommended.
Reference:
Definition in file par_strat3d.c.
static void close_ix3 | ( | Grid * | pGrid | ) | [static] |
static void close_ox3 | ( | Grid * | pGrid | ) | [static] |
Real expr_dpar | ( | const Grid * | pG, | |
const int | i, | |||
const int | j, | |||
const int | k | |||
) |
Wrapper for particle density.
Definition at line 291 of file output_particle.c.
Real expr_V1par | ( | const Grid * | pG, | |
const int | i, | |||
const int | j, | |||
const int | k | |||
) |
Wrapper for particle 1-velocity.
Definition at line 312 of file output_particle.c.
Real expr_V2 | ( | const Grid * | pG, | |
const int | i, | |||
const int | j, | |||
const int | k | |||
) |
Real expr_V2par | ( | const Grid * | pG, | |
const int | i, | |||
const int | j, | |||
const int | k | |||
) |
Wrapper for particle 2-velocity.
Definition at line 319 of file output_particle.c.
Real expr_V3par | ( | const Grid * | pG, | |
const int | i, | |||
const int | j, | |||
const int | k | |||
) |
Wrapper for particle 3-velocity.
Definition at line 326 of file output_particle.c.
Gas velocity shift.
Definition at line 487 of file par_strat3d.c.
Gasfun_t get_usr_expr | ( | const char * | expr | ) |
Sets pointer to expression for special output data.
Definition at line 467 of file par_strat3d.c.
VGFunout_t get_usr_out_fun | ( | const char * | name | ) |
Returns a user defined output function pointer.
Definition at line 472 of file par_strat3d.c.
PropFun_t get_usr_par_prop | ( | const char * | name | ) |
Returns a user defined particle selection function.
Definition at line 477 of file par_strat3d.c.
static Real hst_rho_Vx_dVy | ( | const Grid * | pG, | |
const int | i, | |||
const int | j, | |||
const int | k | |||
) | [static] |
Definition at line 412 of file par_strat3d.c.
References cc_pos(), Omega_0, and qshear.
Referenced by problem(), and problem_read_restart().
void MultiNSH | ( | int | n, | |
Real * | tstop, | |||
Real * | mratio, | |||
Real | etavk, | |||
Real * | uxNSH, | |||
Real * | uyNSH, | |||
Real * | wxNSH, | |||
Real * | wyNSH | |||
) |
Definition at line 612 of file par_strat3d.c.
References calloc_1d_array(), calloc_2d_array(), free_2d_array(), InverseMatrix(), and MatrixMult().
double Normal | ( | long int * | idum | ) |
Definition at line 734 of file par_strat3d.c.
References ran2().
void problem | ( | Grid * | pGrid, | |
Domain * | pDomain | |||
) |
Definition at line 100 of file par_strat3d.c.
References alamcoeff, ath_error(), calloc_1d_array(), calloc_2d_array(), cc_pos(), cellk(), close_ix3(), close_ox3(), dpar_thresh, dump_history_enroll(), epsilon, etavk, free_2d_array(), get_ts, grrhoa, hst_rho_Vx_dVy(), ipert, Iso_csound, left_x3, Lg, Lx, Ly, Lz, mratio, MultiNSH(), nlis, Normal(), Npar, ntrack, Omega(), Omega_0, par_getd(), par_getd_def(), par_geti(), par_geti_def(), particle_realloc(), q, qshear, ran2(), right_x3, ShearingBoxPot, StaticGravPot, tstop0, uxNSH, uyNSH, vsc1, vsc2, wxNSH, wyNSH, x1max, x1min, x2max, x2min, x3max, x3min, zmax, and zmin.
void problem_read_restart | ( | Grid * | pG, | |
Domain * | pD, | |||
FILE * | fp | |||
) |
Definition at line 374 of file par_strat3d.c.
References dump_history_enroll(), hst_rho_Vx_dVy(), ipert, Iso_csound, Lg, Lx, Ly, Lz, nlis, Npar, ntrack, Omega_0, par_getd(), par_getd_def(), par_geti(), par_geti_def(), qshear, ShearingBoxPot, StaticGravPot, vsc1, vsc2, x1max, x1min, x2max, x2min, x3max, and x3min.
void problem_write_restart | ( | Grid * | pG, | |
Domain * | pD, | |||
FILE * | fp | |||
) |
Definition at line 369 of file par_strat3d.c.
static int property_dense | ( | const Grain * | gr, | |
const GrainAux * | grsub | |||
) | [static] |
user defined particle selection function (1: true; 0: false)
Definition at line 594 of file par_strat3d.c.
References GrainAux::dpar, and dpar_thresh.
static int property_limit | ( | const Grain * | gr, | |
const GrainAux * | grsub | |||
) | [static] |
user defined particle selection function (1: true; 0: false)
Definition at line 564 of file par_strat3d.c.
References nlis.
static int property_trace | ( | const Grain * | gr, | |
const GrainAux * | grsub | |||
) | [static] |
user defined particle selection function (1: true; 0: false)
Definition at line 574 of file par_strat3d.c.
References ntrack.
static int property_type | ( | const Grain * | gr, | |
const GrainAux * | grsub | |||
) | [static] |
user defined particle selection function (1: true; 0: false)
Definition at line 584 of file par_strat3d.c.
References mytype.
double ran2 | ( | long int * | idum | ) |
Definition at line 696 of file par_strat3d.c.
void Userwork_after_loop | ( | Grid * | pGrid, | |
Domain * | pDomain | |||
) |
Definition at line 526 of file par_strat3d.c.
void Userwork_in_loop | ( | Grid * | pGrid, | |
Domain * | pDomain | |||
) |
Definition at line 515 of file par_strat3d.c.
Definition at line 60 of file par_strat3d.c.
int ipert |
Definition at line 52 of file par_strat3d.c.
Definition at line 54 of file par_strat3d.c.
Definition at line 54 of file par_strat3d.c.
Definition at line 54 of file par_strat3d.c.
Definition at line 54 of file par_strat3d.c.
int mytype |
Definition at line 59 of file par_strat3d.c.
long nlis |
Definition at line 58 of file par_strat3d.c.
long Npar |
Definition at line 55 of file par_strat3d.c.
long ntrack |
Definition at line 57 of file par_strat3d.c.
Definition at line 51 of file par_strat3d.c.
Definition at line 51 of file par_strat3d.c.
Definition at line 54 of file par_strat3d.c.
Definition at line 54 of file par_strat3d.c.
Definition at line 54 of file par_strat3d.c.
Definition at line 54 of file par_strat3d.c.
Definition at line 54 of file par_strat3d.c.
Definition at line 54 of file par_strat3d.c.