rewrite prove of theorem 1