Another method signals can be combined is by subtracting the amplitude of one signal from another signal. When working with signals (or arrays in Matlab) this is accomplished using element-wise subtraction. For the signals, $x = \{ {x}_{1},{x}_{2},\hdots,{x}_{n} \}$ and $w = \{ {w}_{1},{w}_{2},\hdots,{w}_{n} \}$, subtracting $w$ from $x$ results in the signal:

$y = \{ {x}_{1} - {w}_{1},{x}_{2} - {w}_{2}, \hdots,{x}_{n} - {w}_{n} \}$.

Audio engineers use this operation to perform a “null test”. This test is used to determine if two signals are identical to each other. If the signals are identical, then by subtracting one from the other the result is a signal with an amplitude of zero.

Next, let’s use the multiplication operator to combine signals together.