proof for theorem 1