negate function

Function performs steps to produce a value's two's complement.