PLUTO
|
Stellar wind test problem. More...
#include "pluto.h"
Go to the source code of this file.
Functions | |
void | Init (double *us, double x1, double x2, double x3) |
void | Analysis (const Data *d, Grid *grid) |
void | UserDefBoundary (const Data *d, RBox *box, int side, Grid *grid) |
Stellar wind test problem.
Sets initial condition for a spherically symmetric radial wind blowing from the origin of coordinates, see [Mig14] The initial condition consists of a constant-density ambient medium with
where v_csm
is the velocity of the star with respect to the background. The wind is injeted using the INTERNAL_BOUNDARY
where flow quantities are kept constant in time and equal to
These value are defined through the UserDefBoundary() function when side
is equal to 0.
Dimensions are chosen so that the spherical wind shell has radius 1, density 1 and velocity 1 ( ).
The input parameters that control the problem dynamics are
g_inputParam[CS_WIND]
: sets the sound speed in the wind region;g_inputParam[RHO_AMB]
: sets the ambient densityg_inputParam[CS_AMB]
: sets the ambient sound speed;g_inputParam[V_CSM]
: sets the velocity of the star with respect to the background;Configurations #01-05 and #07-08 work in 2D cylindrical axisymmetric coordinates while conf. #06 is 3D Cartesian. An AMR setup is available with configuration #04.
References
Definition in file init.c.
void Init | ( | double * | us, |
double | x1, | ||
double | x2, | ||
double | x3 | ||
) |
The Init() function can be used to assign initial conditions as as a function of spatial position.
[out] | v | a pointer to a vector of primitive variables |
[in] | x1 | coordinate point in the 1st dimension |
[in] | x2 | coordinate point in the 2nd dimension |
[in] | x3 | coordinate point in the 3rdt dimension |
The meaning of x1, x2 and x3 depends on the geometry:
Variable names are accessed by means of an index v[nv], where nv = RHO is density, nv = PRS is pressure, nv = (VX1, VX2, VX3) are the three components of velocity, and so forth.
Definition at line 51 of file init.c.
Assign user-defined boundary conditions.
[in,out] | d | pointer to the PLUTO data structure containing cell-centered primitive quantities (d->Vc) and staggered magnetic fields (d->Vs, when used) to be filled. |
[in] | box | pointer to a RBox structure containing the lower and upper indices of the ghost zone-centers/nodes or edges at which data values should be assigned. |
[in] | side | specifies the boundary side where ghost zones need to be filled. It can assume the following pre-definite values: X1_BEG, X1_END, X2_BEG, X2_END, X3_BEG, X3_END. The special value side == 0 is used to control a region inside the computational domain. |
[in] | grid | pointer to an array of Grid structures. |
Assign user-defined boundary conditions in the lower boundary ghost zones. The profile is top-hat:
where and
M
is the flow Mach number (the unit velocity is the jet sound speed, so ).
Assign user-defined boundary conditions:
x < 1/6
and reflective boundary otherwise.Definition at line 90 of file init.c.