check negative flag
Merge pull request #7 from JunyangGao/Junyang

check negative flag