Using component-wise maths to avoid allocations, see #50