Skip to content
Projects

Neutral backgrounds

The equations of plasmacoll.background, declared on the code that implements them and checked by the tests.

DensityProfile

classsource

A piecewise-linear relative neutral density along one coordinate axis.

factor
f(x)=fi+fi+1−fixi+1−xi (xa−xi),xi≤xa≤xi+1f(\mathbf x) = f_i + \frac{f_{i+1} - f_i}{x_{i+1} - x_i}\,(x_a - x_i), \qquad x_i \le x_a \le x_{i+1}
density
n(x)=nb f(x),Fb=max⁡ifin(\mathbf x) = n_b\,f(\mathbf x), \qquad F_b = \max_i f_i
Order
2
Assumes
  • xax_a the position component axis; the end values outside the table
  • FbF_b bounds the density for the null-collision method

sample_velocities

functionsource

Sample num neutral velocities (3 components) from the Maxwellian.

velocity
w=ub+e Tb fT,b(x)M  ξ,ξ∼N(0,1)3\mathbf w = \mathbf u_b + \sqrt{\frac{e\,T_b\,f_{T,b}(\mathbf x)}{M}}\;\boldsymbol\xi, \qquad \boldsymbol\xi \sim \mathcal N(0, 1)^3
Assumes
  • a drifting Maxwellian: ub\mathbf u_b the drift, TbT_b the temperature in eV, fT,bf_{T,b} the temperature profile clipped at zero (1 without one)