ImpactX
Loading...
Searching...
No Matches
SoftQuad.H
Go to the documentation of this file.
1/* Copyright 2022-2026 The Regents of the University of California, through Lawrence
2 * Berkeley National Laboratory (subject to receipt of any required
3 * approvals from the U.S. Dept. of Energy). All rights reserved.
4 *
5 * This file is part of ImpactX.
6 *
7 * Authors: Chad Mitchell, Axel Huebl
8 * License: BSD-3-Clause-LBNL
9 */
10#ifndef IMPACTX_SOFTQUAD_H
11#define IMPACTX_SOFTQUAD_H
12
15#include "mixin/alignment.H"
16#include "mixin/beamoptic.H"
17#include "mixin/dynamicdata.H"
19#include "mixin/named.H"
20#include "mixin/nofinalize.H"
21#include "mixin/pipeaperture.H"
22#include "mixin/thick.H"
23#include "mixin/spintransport.H"
24#include "mixin/TrackedVector.H"
25
26#include <ablastr/constant.H>
27
28#include <AMReX.H>
29#include <AMReX_Extension.H>
30#include <AMReX_Math.H>
31#include <AMReX_REAL.H>
32#include <AMReX_SIMD.H>
33#include <AMReX_SmallMatrix.H>
34
35#include <cmath>
36#include <memory>
37#include <stdexcept>
38#include <tuple>
39#include <vector>
40
41
42namespace impactx::elements
43{
63 {
65 0.834166514794446,
66 0.598104328994702,
67 0.141852844428785,
68 -0.118211272182381,
69 -9.056149864743113E-002,
70 1.803476331179615E-002,
71 4.464887700797893E-002,
72 7.364410636252136E-003,
73 -1.697541023436736E-002,
74 -9.012679515542771E-003,
75 4.367667630047725E-003,
76 5.444030542119803E-003,
77 -5.889959910931886E-005,
78 -2.409098101409192E-003,
79 -7.962712154165590E-004,
80 7.855814707106538E-004,
81 6.174930463182168E-004,
82 -1.340154094301854E-004,
83 -3.167213724698439E-004,
84 -4.925292460592617E-005,
85 1.221580597451921E-004,
86 6.331025910961789E-005,
87 -3.202416719002774E-005,
88 -3.872103053895529E-005,
89 8.212882937116278E-007
90 };
91
93 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
94 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
95 0, 0, 0, 0, 0
96 };
97 };
98
109
111 : public mixin::Named,
112 public mixin::BeamOptic<SoftQuadrupole>,
113 public mixin::LinearTransport<SoftQuadrupole>,
114 public mixin::Thick,
115 public mixin::Alignment,
116 public mixin::NoFinalize,
117 public mixin::PipeAperture,
119 public amrex::simd::Vectorized<amrex::simd::native_simd_size_particlereal>
120 {
121 static constexpr auto type = "SoftQuadrupole";
123
125
144 amrex::ParticleReal gscale,
145 std::vector<amrex::ParticleReal> cos_coef,
146 std::vector<amrex::ParticleReal> sin_coef,
149 amrex::ParticleReal rotation_degree = 0,
152 int mapsteps = 10,
153 int nslice = 1,
154 std::optional<std::string> name = std::nullopt
155 )
156 : Named(std::move(name)),
157 Thick(ds, nslice),
158 Alignment(dx, dy, rotation_degree),
160 m_gscale(gscale), m_mapsteps(mapsteps),
161 m_id(DynamicData::allocate_id())
162 {
163 m_ncoef = int(cos_coef.size());
164 if (m_ncoef != int(sin_coef.size()))
165 throw std::runtime_error("SoftQuadrupole: cos and sin coefficients must have same length!");
166
167 auto& coef = DynamicData::emplace(
168 m_id,
169 std::move(cos_coef),
170 std::move(sin_coef)
171 );
172 m_cos_h_data = coef.cos.host_const().data();
173 m_sin_h_data = coef.sin.host_const().data();
174 }
175
177 void reverse () {
178 // Reversing ds traverses the Fourier profile in the opposite z direction,
179 // so the odd sine terms change sign implicitly via sin(-kz) = -sin(kz).
180 Thick::reverse();
181 }
182
184 using BeamOptic::operator();
185
193 void compute_constants (RefPart const & refpart)
194 {
195 using namespace amrex::literals; // for _rt and _prt
196
197 Alignment::compute_constants(refpart);
198
199 // Ensure dynamic coefficient data is on GPU and we have fresh pointers to it
200 auto const & coef = *DynamicData::get(m_id);
201 m_cos_d_data = coef.cos.device_const().data();
202 m_sin_d_data = coef.sin.device_const().data();
203 }
204
219 template<typename T_Real=amrex::ParticleReal, typename T_IdCpu=uint64_t>
222 T_Real & AMREX_RESTRICT x,
223 T_Real & AMREX_RESTRICT y,
224 T_Real & AMREX_RESTRICT t,
225 T_Real & AMREX_RESTRICT px,
226 T_Real & AMREX_RESTRICT py,
227 T_Real & AMREX_RESTRICT pt,
228 T_IdCpu & AMREX_RESTRICT idcpu,
229 RefPart const & AMREX_RESTRICT refpart
230 ) const
231 {
232 using namespace amrex::literals; // for _rt and _prt
233
234 // shift due to alignment errors of the element
235 shift_in(x, y, px, py);
236
237 // get the linear map
239
240 // symplectic linear map for a quadrupole is computed using the
241 // Hamiltonian formalism as described in:
242 // https://uspas.fnal.gov/materials/09UNM/ComputationalMethods.pdf .
243 // R denotes the transfer matrix in the basis (x,px,y,py,t,pt),
244 // so that, e.g., R(3,4) = dyf/dpyi.
245 amrex::SmallVector<T_Real, 6, 1> const v{x, px, y, py, t, pt};
246
247 // push particles using the linear map
248 auto const out = R * v;
249
250 // assign updated values
251 x = out[1];
252 px = out[2];
253 y = out[3];
254 py = out[4];
255 t = out[5];
256 pt = out[6];
257
258 // apply transverse aperture
259 apply_aperture(x, y, idcpu);
260
261 // undo shift due to alignment errors of the element
262 shift_out(x, y, px, py);
263 }
264
270 void operator() (RefPart & AMREX_RESTRICT refpart) const
271 {
272 using namespace amrex::literals; // for _rt and _prt
273 using amrex::Math::powi;
274
275 // assign input reference particle values
276 amrex::ParticleReal const x = refpart.x;
277 amrex::ParticleReal const px = refpart.px;
278 amrex::ParticleReal const y = refpart.y;
279 amrex::ParticleReal const py = refpart.py;
280 amrex::ParticleReal const z = refpart.z;
281 amrex::ParticleReal const pz = refpart.pz;
282 amrex::ParticleReal const pt = refpart.pt;
283 amrex::ParticleReal const s = refpart.s;
284 amrex::ParticleReal const sedge = refpart.sedge;
285
286 // initialize linear map (deviation) values
287 refpart.map = decltype(refpart.map)::Identity();
288
289 // initialize the spin-orbit coupling matrix
290 refpart.spin_coupling = {};
291
292 // length of the current slice
293 amrex::ParticleReal const slice_ds = m_ds / nslice();
294
295 // compute initial value of beta*gamma
296 amrex::ParticleReal const bgi = std::sqrt(powi<2>(pt) - 1.0_prt);
297
298 // call integrator to advance (t,pt)
299 amrex::ParticleReal const zin = s - sedge;
300 amrex::ParticleReal const zout = zin + slice_ds;
301 int const nsteps = m_mapsteps;
302
303 integrators::symp2_integrate(refpart,zin,zout,nsteps,*this);
304 amrex::ParticleReal const ptf = refpart.pt;
305
306 /*
307 // print computed linear map:
308 for(int i=1; i<7; ++i){
309 for(int j=1; j<7; ++j){
310 amrex::PrintToFile("QuadMap.txt") << i << " " <<
311 j << " " << refpart.map(i,j) << "\n";
312 }
313 }
314 //
315 */
316
317 // advance position (x,y,z)
318 refpart.x = x + slice_ds*px/bgi;
319 refpart.y = y + slice_ds*py/bgi;
320 refpart.z = z + slice_ds*pz/bgi;
321
322 // compute final value of beta*gamma
323 amrex::ParticleReal const bgf = std::sqrt(powi<2>(ptf) - 1.0_prt);
324
325 // advance momentum (px,py,pz)
326 refpart.px = px*bgf/bgi;
327 refpart.py = py*bgf/bgi;
328 refpart.pz = pz*bgf/bgi;
329
330 // advance integrated path length
331 refpart.s = s + slice_ds;
332 }
333
334
349 template<typename T_Real=amrex::ParticleReal, typename T_IdCpu=uint64_t>
352 T_Real & AMREX_RESTRICT x,
353 T_Real & AMREX_RESTRICT y,
354 T_Real & AMREX_RESTRICT t,
355 T_Real & AMREX_RESTRICT px,
356 T_Real & AMREX_RESTRICT py,
357 T_Real & AMREX_RESTRICT pt,
358 T_Real & AMREX_RESTRICT sx,
359 T_Real & AMREX_RESTRICT sy,
360 T_Real & AMREX_RESTRICT sz,
361 T_IdCpu & AMREX_RESTRICT idcpu,
362 RefPart const & AMREX_RESTRICT refpart
363 ) const
364 {
365 using namespace amrex::literals; // for _rt and _prt
366
367 // initialize the three components of the axis-angle vector
368 T_Real lambdax = 0_prt;
369 T_Real lambday = 0_prt;
370 T_Real lambdaz = 0_prt;
371
372 // store the phase space variables in vector form
373 amrex::SmallVector<T_Real, 6, 1> const v{x, px, y, py, t, pt};
374
375 // get the spin-orbit coupling matrix
377
378 // use phase space variables to obtain the angle-axis generator of spin rotation
379 auto const out = A * v;
380
381 // update the angle-axis generator
382 lambdax = out[1];
383 lambday = out[2];
384 lambdaz = out[3];
385
386 // push the spin vector using the generator just determined
387 rotate_spin(lambdax,lambday,lambdaz,sx,sy,sz);
388
389 // phase space push
390 (*this)(x, y, t, px, py, pt, idcpu, refpart);
391 }
392
393
395 using LinearTransport::operator();
396
403 Map6x6
404 transport_map ([[maybe_unused]] RefPart const & AMREX_RESTRICT refpart) const
405 {
406
408 R = refpart.map;
409
410 return R;
411 }
412
419 std::tuple<amrex::ParticleReal, amrex::ParticleReal, amrex::ParticleReal>
422 {
423 using namespace amrex::literals; // for _rt and _prt
424
425 // pick the right data depending if we are on the host side
426 // (reference particle push) or device side (particles):
427#if AMREX_DEVICE_COMPILE
428 amrex::ParticleReal const * cos_data = m_cos_d_data;
429 amrex::ParticleReal const * sin_data = m_sin_d_data;
430#else
431 amrex::ParticleReal const * cos_data = m_cos_h_data;
432 amrex::ParticleReal const * sin_data = m_sin_h_data;
433#endif
434
435 // specify constants
437 amrex::ParticleReal const zlen = std::abs(m_ds);
438 amrex::ParticleReal const zmid = zlen * 0.5_prt;
439
440 // compute on-axis magnetic field (z is relative to quadrupole midpoint)
441 amrex::ParticleReal bfield = 0.0;
442 amrex::ParticleReal bfieldp = 0.0;
443 amrex::ParticleReal bfieldint = 0.0;
444 amrex::ParticleReal const z = zeval - zmid;
445
446 if (std::abs(z) <= zmid)
447 {
448 bfield = 0.5_prt*cos_data[0];
449 bfieldint = z*bfield;
450 for (int j=1; j < m_ncoef; ++j)
451 {
452 bfield = bfield + cos_data[j] *std::cos(j * 2 * pi * z / zlen) +
453 sin_data[j] *std::sin(j * 2 * pi * z / zlen);
454 bfieldp = bfieldp - j * 2 * pi * cos_data[j] *std::sin(j * 2 * pi * z / zlen) / zlen +
455 j * 2 * pi * sin_data[j] *std::cos(j * 2 * pi * z / zlen) / zlen;
456 bfieldint = bfieldint + zlen * cos_data[j] *std::sin(j * 2 * pi * z / zlen) / (j * 2 * pi) -
457 zlen * sin_data[j] *std::cos(j * 2 * pi * z / zlen) / (j * 2 * pi);
458 }
459 }
460 return std::make_tuple(bfield, bfieldp, bfieldint);
461 }
462
472 void map1 (amrex::ParticleReal const tau,
473 RefPart & refpart,
474 [[maybe_unused]] amrex::ParticleReal & zeval) const
475 {
476 using namespace amrex::literals; // for _rt and _prt
477 using amrex::Math::powi;
478
479 // push the reference particle
480 amrex::ParticleReal const t = refpart.t;
481 amrex::ParticleReal const pt = refpart.pt;
482 amrex::ParticleReal const z = zeval;
483
484 if (pt < -1.0_prt) {
485 refpart.t = t + tau/std::sqrt(1.0_prt - powi<-2>(pt));
486 refpart.pt = pt;
487 }
488 else {
489 refpart.t = t;
490 refpart.pt = pt;
491 }
492
493 zeval = z + tau;
494
495 // push the linear map equations
497 amrex::ParticleReal const betgam = refpart.beta_gamma();
498
499 refpart.map(1,1) = R(1,1) + tau*R(2,1);
500 refpart.map(1,2) = R(1,2) + tau*R(2,2);
501 refpart.map(1,3) = R(1,3) + tau*R(2,3);
502 refpart.map(1,4) = R(1,4) + tau*R(2,4);
503
504 refpart.map(3,1) = R(3,1) + tau*R(4,1);
505 refpart.map(3,2) = R(3,2) + tau*R(4,2);
506 refpart.map(3,3) = R(3,3) + tau*R(4,3);
507 refpart.map(3,4) = R(3,4) + tau*R(4,4);
508
509 refpart.map(5,5) = R(5,5) + tau*R(6,5) / powi<2>(betgam);
510 refpart.map(5,6) = R(5,6) + tau*R(6,6) / powi<2>(betgam);
511 }
512
522 void map2 (amrex::ParticleReal const tau,
523 RefPart & refpart,
524 amrex::ParticleReal & zeval) const
525 {
526 using namespace amrex::literals; // for _rt and _prt
527
528 amrex::ParticleReal const t = refpart.t;
529 amrex::ParticleReal const pt = refpart.pt;
530
531 // Define parameters and intermediate constants
532 amrex::ParticleReal const G0 = m_gscale;
533
534 // push the reference particle
535 auto [bz, bzp, bzint] = Quad_Bfield(zeval);
536 amrex::ignore_unused(bzp, bzint);
537
538 refpart.t = t;
539 refpart.pt = pt;
540
541 // push the linear map equations
543 amrex::ParticleReal const alpha = G0*bz;
544
545 refpart.map(2,1) = R(2,1) - tau*alpha*R(1,1);
546 refpart.map(2,2) = R(2,2) - tau*alpha*R(1,2);
547 refpart.map(2,3) = R(2,3) - tau*alpha*R(1,3);
548 refpart.map(2,4) = R(2,4) - tau*alpha*R(1,4);
549
550 refpart.map(4,1) = R(4,1) + tau*alpha*R(3,1);
551 refpart.map(4,2) = R(4,2) + tau*alpha*R(3,2);
552 refpart.map(4,3) = R(4,3) + tau*alpha*R(3,3);
553 refpart.map(4,4) = R(4,4) + tau*alpha*R(3,4);
554
555 // BELOW: if spin is needed only:
558 amrex::ParticleReal const gamma = refpart.gamma();
560
561 // Update spin-orbit coupling matrix here
562 dA(1,3) = -(1_prt + G*gamma) * tau * alpha;
563 dA(2,1) = -(1_prt + G*gamma) * tau * alpha;
564
565 // update the spin-orbit coupling matrix here
566 refpart.spin_coupling = A + dA*R;
567
568 }
569
572 int m_id;
573
574 int m_ncoef = 0;
579 };
580
581} // namespace impactx
582
585
586#endif // IMPACTX_SOFTQUAD_H
#define AMREX_FORCE_INLINE
#define AMREX_RESTRICT
#define AMREX_GPU_HOST_DEVICE
#define AMREX_GPU_HOST
#define IMPACTX_PUSH_EXTERN_TEMPLATE(ElementType)
Definition PushAll.H:78
#define IMPACTX_GPUDATA_EXTERN(ElementType)
Definition dynamicdata.H:169
amrex_particle_real ParticleReal
constexpr T powi(T x) noexcept
__host__ __device__ void ignore_unused(const Ts &...)
SmallMatrix< T, N, 1, Order::F, StartIndex > SmallVector
Definition All.H:56
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void symp2_integrate(RefPart &refpart, amrex::ParticleReal const zin, amrex::ParticleReal const zout, int const nsteps, T_Element const &element)
Definition Integrators.H:36
@ s
fixed s as the independent variable
Definition ImpactXParticleContainer.H:37
@ t
fixed t as the independent variable
Definition ImpactXParticleContainer.H:38
amrex::SmallMatrix< amrex::ParticleReal, 6, 6, amrex::Order::F, 1 > Map6x6
Definition CovarianceMatrix.H:20
static constexpr __host__ __device__ SmallMatrix< T, NRows, NCols, ORDER, StartIndex > Identity() noexcept
Definition ReferenceParticle.H:33
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::ParticleReal beta_gamma() const
Definition ReferenceParticle.H:168
amrex::ParticleReal pt
energy, normalized by rest energy
Definition ReferenceParticle.H:42
amrex::SmallMatrix< amrex::ParticleReal, 6, 6, amrex::Order::F, 1 > map
linearized map
Definition ReferenceParticle.H:48
amrex::SmallMatrix< amrex::ParticleReal, 3, 6, amrex::Order::F, 1 > spin_coupling
linearized spin-orbit coupling matrix
Definition ReferenceParticle.H:49
amrex::ParticleReal gyromagnetic_anomaly
anomalous magnetic moment [unitless]
Definition ReferenceParticle.H:45
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::ParticleReal gamma() const
Definition ReferenceParticle.H:140
amrex::ParticleReal t
clock time * c in meters
Definition ReferenceParticle.H:38
Definition SoftQuad.H:63
amrex::Vector< amrex::ParticleReal > default_cos_coef
Definition SoftQuad.H:64
amrex::Vector< amrex::ParticleReal > default_sin_coef
Definition SoftQuad.H:92
mixin::TrackedVector< amrex::ParticleReal > sin
Definition SoftQuad.H:107
mixin::TrackedVector< amrex::ParticleReal > cos
Definition SoftQuad.H:106
Definition SoftQuad.H:120
static constexpr auto type
Definition SoftQuad.H:121
mixin::GPUDataRegistry< QuadrupoleFourierCoefficients > DynamicData
Definition SoftQuad.H:124
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void map1(amrex::ParticleReal const tau, RefPart &refpart, amrex::ParticleReal &zeval) const
Definition SoftQuad.H:472
SoftQuadrupole(amrex::ParticleReal ds, amrex::ParticleReal gscale, std::vector< amrex::ParticleReal > cos_coef, std::vector< amrex::ParticleReal > sin_coef, amrex::ParticleReal dx=0, amrex::ParticleReal dy=0, amrex::ParticleReal rotation_degree=0, amrex::ParticleReal aperture_x=0, amrex::ParticleReal aperture_y=0, int mapsteps=10, int nslice=1, std::optional< std::string > name=std::nullopt)
Definition SoftQuad.H:142
int m_ncoef
unique soft quad id used for data lookup map
Definition SoftQuad.H:574
ImpactXParticleContainer::ParticleType PType
Definition SoftQuad.H:122
amrex::ParticleReal const * m_cos_d_data
non-owning pointer to host sine coefficients
Definition SoftQuad.H:577
int m_id
number of map integration steps per slice
Definition SoftQuad.H:572
amrex::ParticleReal const * m_sin_h_data
non-owning pointer to host cosine coefficients
Definition SoftQuad.H:576
AMREX_GPU_HOST AMREX_FORCE_INLINE Map6x6 transport_map(RefPart const &AMREX_RESTRICT refpart) const
Definition SoftQuad.H:404
std::tuple< amrex::ParticleReal, amrex::ParticleReal, amrex::ParticleReal > AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE Quad_Bfield(amrex::ParticleReal const zeval) const
Definition SoftQuad.H:421
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void spin_and_phasespace_push(T_Real &AMREX_RESTRICT x, T_Real &AMREX_RESTRICT y, T_Real &AMREX_RESTRICT t, T_Real &AMREX_RESTRICT px, T_Real &AMREX_RESTRICT py, T_Real &AMREX_RESTRICT pt, T_Real &AMREX_RESTRICT sx, T_Real &AMREX_RESTRICT sy, T_Real &AMREX_RESTRICT sz, T_IdCpu &AMREX_RESTRICT idcpu, RefPart const &AMREX_RESTRICT refpart) const
Definition SoftQuad.H:351
amrex::ParticleReal m_gscale
Definition SoftQuad.H:570
int m_mapsteps
scaling factor for quad field gradient
Definition SoftQuad.H:571
void reverse()
Definition SoftQuad.H:177
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void operator()(T_Real &AMREX_RESTRICT x, T_Real &AMREX_RESTRICT y, T_Real &AMREX_RESTRICT t, T_Real &AMREX_RESTRICT px, T_Real &AMREX_RESTRICT py, T_Real &AMREX_RESTRICT pt, T_IdCpu &AMREX_RESTRICT idcpu, RefPart const &AMREX_RESTRICT refpart) const
Definition SoftQuad.H:221
amrex::ParticleReal const * m_sin_d_data
non-owning pointer to device cosine coefficients
Definition SoftQuad.H:578
amrex::ParticleReal const * m_cos_h_data
number of Fourier coefficients
Definition SoftQuad.H:575
void compute_constants(RefPart const &refpart)
Definition SoftQuad.H:193
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void map2(amrex::ParticleReal const tau, RefPart &refpart, amrex::ParticleReal &zeval) const
Definition SoftQuad.H:522
Definition alignment.H:27
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void shift_out(T_Real &AMREX_RESTRICT x, T_Real &AMREX_RESTRICT y, T_Real &AMREX_RESTRICT px, T_Real &AMREX_RESTRICT py) const
Definition alignment.H:109
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::ParticleReal dy() const
Definition alignment.H:146
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::ParticleReal dx() const
Definition alignment.H:136
Alignment(amrex::ParticleReal dx, amrex::ParticleReal dy, amrex::ParticleReal rotation_degree)
Definition alignment.H:36
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void shift_in(T_Real &AMREX_RESTRICT x, T_Real &AMREX_RESTRICT y, T_Real &AMREX_RESTRICT px, T_Real &AMREX_RESTRICT py) const
Definition alignment.H:78
Definition beamoptic.H:436
static std::shared_ptr< QuadrupoleFourierCoefficients > const & get(int id)
Definition dynamicdata.H:98
static QuadrupoleFourierCoefficients & emplace(int id, Args &&... args)
Definition dynamicdata.H:125
Definition lineartransport.H:50
Definition named.H:29
AMREX_GPU_HOST Named(std::optional< std::string > name)
Definition named.H:57
AMREX_FORCE_INLINE std::string name() const
Definition named.H:122
Definition nofinalize.H:22
Definition pipeaperture.H:26
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void apply_aperture(T_Real &AMREX_RESTRICT x, T_Real &AMREX_RESTRICT y, T_IdCpu &AMREX_RESTRICT idcpu) const
Definition pipeaperture.H:59
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::ParticleReal aperture_x() const
Definition pipeaperture.H:90
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::ParticleReal aperture_y() const
Definition pipeaperture.H:101
PipeAperture(amrex::ParticleReal aperture_x, amrex::ParticleReal aperture_y)
Definition pipeaperture.H:32
Definition spintransport.H:36
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void rotate_spin(T_Real const &AMREX_RESTRICT lambdax, T_Real const &AMREX_RESTRICT lambday, T_Real const &AMREX_RESTRICT lambdaz, T_Real &AMREX_RESTRICT sx, T_Real &AMREX_RESTRICT sy, T_Real &AMREX_RESTRICT sz) const
Definition spintransport.H:48
Definition thick.H:24
Thick(amrex::ParticleReal ds, int nslice)
Definition thick.H:30
amrex::ParticleReal m_ds
Definition thick.H:68
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::ParticleReal ds() const
Definition thick.H:53
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE int nslice() const
Definition thick.H:43
Definition TrackedVector.H:49