lentil.field.multiply¶
- lentil.field.multiply(x1, x2)[source]¶
Multiply fields element-wise.
- Parameters
- Returns
y – The product of
x1
andx2
, appropriately sized and offset.- Return type
Notes
The output Field data and offset are computed according to the following rules:
If both operands are scalars, the result is 0 unless the operands share the same offset.
A single scalar operand is broadcast to the other operand’s shape and inherits the other operand’s offset. This enables default planar fields (
data = 1+0j
, offset = [0, 0]) to automatically grow in size when multiplied by a “real” field.