45 RP::add(
"Riemann.rho1",
"Number density, left state (m^-3)", 0.0);
46 RP::add(
"Riemann.rho2",
"Number density, right state (m^-3)", 0.0);
47 RP::add(
"Riemann.T1",
"Temperature, left state (K)", 0.0);
48 RP::add(
"Riemann.T2",
"Temperature, right state (K)", 0.0);
49 RP::add(
"Riemann.Vx1",
"Bulk velocity x component, left state (m/s)", 0.0);
50 RP::add(
"Riemann.Vx2",
"Bulk velocity x component, right state (m/s)", 0.0);
51 RP::add(
"Riemann.Vy1",
"Bulk velocity y component, left state (m/s)", 0.0);
52 RP::add(
"Riemann.Vy2",
"Bulk velocity y component, right state (m/s)", 0.0);
53 RP::add(
"Riemann.Vz1",
"Bulk velocity z component, left state (m/s)", 0.0);
54 RP::add(
"Riemann.Vz2",
"Bulk velocity z component, right state (m/s)", 0.0);
55 RP::add(
"Riemann.Bx1",
"Magnetic field x component, left state (T)", 0.0);
56 RP::add(
"Riemann.Bx2",
"Magnetic field x component, right state (T)", 0.0);
57 RP::add(
"Riemann.By1",
"Magnetic field y component, left state (T)", 0.0);
58 RP::add(
"Riemann.By2",
"Magnetic field y component, right state (T)", 0.0);
59 RP::add(
"Riemann.Bz1",
"Magnetic field z component, left state (T)", 0.0);
60 RP::add(
"Riemann.Bz2",
"Magnetic field z component, right state (T)", 0.0);
68 std::cerr <<
"The selected project does not support multiple particle populations! Aborting in " << __FILE__ <<
" line " << __LINE__ << std::endl;
71 RP::get(
"Riemann.rho1", this->
rho[this->
LEFT]);
72 RP::get(
"Riemann.rho2", this->
rho[this->
RIGHT]);
73 RP::get(
"Riemann.T1", this->
T[this->LEFT]);
74 RP::get(
"Riemann.T2", this->
T[this->RIGHT]);
75 RP::get(
"Riemann.Vx1", this->
Vx[this->LEFT]);
76 RP::get(
"Riemann.Vx2", this->
Vx[this->RIGHT]);
77 RP::get(
"Riemann.Vy1", this->
Vy[this->LEFT]);
78 RP::get(
"Riemann.Vy2", this->
Vy[this->RIGHT]);
79 RP::get(
"Riemann.Vz1", this->
Vz[this->LEFT]);
80 RP::get(
"Riemann.Vz2", this->
Vz[this->RIGHT]);
81 RP::get(
"Riemann.Bx1", this->
Bx[this->LEFT]);
82 RP::get(
"Riemann.Bx2", this->
Bx[this->RIGHT]);
83 RP::get(
"Riemann.By1", this->
By[this->LEFT]);
84 RP::get(
"Riemann.By2", this->
By[this->RIGHT]);
85 RP::get(
"Riemann.Bz1", this->
Bz[this->LEFT]);
86 RP::get(
"Riemann.Bz2", this->
Bz[this->RIGHT]);
101 Real initRho = this->
rho[side];
102 Real initT = this->
T[side];
103 const Real initV0X = this->
Vx[side];
104 const Real initV0Y = this->
Vy[side];
105 const Real initV0Z = this->
Vz[side];
124 vmesh->getBlockInfo(blockGID,&blockCoords[0]);
125 creal vxBlock = blockCoords[0];
126 creal vyBlock = blockCoords[1];
127 creal vzBlock = blockCoords[2];
128 creal dvxCell = blockCoords[3];
129 creal dvyCell = blockCoords[4];
130 creal dvzCell = blockCoords[5];
132 creal vx = vxBlock + (
i+0.5)*dvxCell - initV0X;
133 creal vy = vyBlock + (
j+0.5)*dvyCell - initV0Y;
134 creal vz = vzBlock + (
k+0.5)*dvzCell - initV0Z;
152 const auto Bx_l = this->
Bx;
153 const auto By_l = this->
By;
154 const auto Bz_l = this->
Bz;
155 const auto LEFT_l = this->
LEFT;
156 const auto RIGHT_l = this->
RIGHT;
158 fsgrid.parallel_for([](
int timerId) -> phiprof::Timer {
return phiprof::Timer{timerId}; },
159 phiprof::initializeTimer(
"setProjectBField-loop"), technical,
160 [=](
const fsgrid::Coordinates &coordinates,
const fsgrid::FsStencil& stencil,
cuint sysBoundaryFlag,
cuint sysBoundaryLayer) {
161 const std::array<Real, 3> xyz = coordinates.getPhysicalCoords(stencil.i, stencil.j, stencil.k);
162 auto& cell = perb[stencil.ooo()];
#define ARCH_INNER_BODY(...)
void setBackgroundFieldToZero(FieldSolverGrid &fsgrid, fsgrids::technicalspan technical, fsgrids::bgbspan bgb)
virtual bool initialize()
virtual void getParameters()
static void addParameters(void)
virtual void calcCellParameters(spatial_cell::SpatialCell *cell, creal &t) override
virtual Realf fillPhaseSpace(spatial_cell::SpatialCell *cell, const uint popID, const uint nRequested) const override
virtual void setProjectBField(fsgrids::perbspan perb, fsgrids::bgbspan bgb, fsgrids::technicalspan technical, FieldSolverGrid &fsgrid) override
virtual bool initialize(void) override
virtual void getParameters(void) override
vmesh::VelocityMesh * get_velocity_mesh(const size_t &popID)
vmesh::VelocityBlockContainer * get_velocity_blocks(const size_t &popID)
std::array< Real, CellParams::N_SPATIAL_CELL_PARAMS > parameters
vmesh::VelocityBlockContainer * dev_get_velocity_blocks(const size_t &popID)
vmesh::VelocityMesh * dev_get_velocity_mesh(const size_t &popID)
ARCH_HOSTDEV Realf * getData()
fsgrid::FsGrid< FS_STENCIL_WIDTH > FieldSolverGrid
ObjectWrapper & getObjectWrapper()
static void parallel_reduce(const uint(&limits)[NDim], Lambda loop_body, T &sum)
std::span< std::array< Real, fsgrids::bfield::N_BFIELD > > perbspan
std::span< technical > technicalspan
std::span< std::array< Real, bgbfield::N_BGB > > bgbspan
ARCH_HOSTDEV Realf MaxwellianPhaseSpaceDensity(creal &vx, creal &vy, creal &vz, creal &T, creal &rho, creal &mass)
std::vector< species::Species > particleSpecies