cross_component

PlasmaCalcs.quantities.patterns.vector_arithmetic.cross_component(A, B, x, *, yz=None, missing_ok=False)

return x component of A cross B, given A and B which have values for y and z ‘component’.

x: int, str, or Component

tells component (of result) to get. if int or str, use XYZ.get(x)
A, B: xarray.DataArray
vectors to take cross product of.
must include ‘component’ dimension including coordinates y and z.
yz: None or iterable of two (int, str, or Component) objects
the other two components; (x,y,z) should form a right-handed coordinate system.
if not provided, infer from x.
missing_ok: bool, default False
whether it is okay for ‘component’ dimension to be missing y or z components, of A or B.
if True, treat any missing components as 0.
[Implementation currently just returns xarray_cross_component(A, B, x, yz=yz, …)]