fixed error in IsPosPreserving's definition