When working with audio signals, you must look at the signals as phasors rather than plain numbers. As such, the signals will be represented as complex numbers. For example, a given sinusoidal signal $Se^{j\phi}$ has an amplitude of S, and a phase angle of $\phi$. Inverting the signal means increasing its phase angle by 180 degrees, or $\pi$ radians. So when adding the two signals together what you are doing is represented by the equation (omitting conjugate pairs):
$$S_{sum}=Se^{j\phi}+Se^{j(\phi+\pi)}$$
$$S_{sum}=Se^{j\phi}+Se^{j\phi}e^{j\pi}$$
$$e^{j\pi}=-1$$
$$S_{sum}=Se^{j\phi}-Se^{j\phi}=0$$
In terms of the intensity going up by 6dB when the intensity is doubled, this can be calculated by using the equation:
$$ 10log(I_2/I_1)dB$$
Intensity is directly proportional to the square of the amplitude, so doubling the amplitude will result in the equation:
$$ 10log(4S^2/S^2)dB=6dB$$
Doing the other calculations you mentioned is a simple matter of trigonometric arithmetic. For example, in the case of squaring the sinusoidal signal, the result is a sinusoid of twice the frequency and half the phase. This is demonstrated by the identity:
$$cos^2(x)=\frac{1}{2}(cos(2x)+1)$$