Fix negative area value

Signed-off-by: RyeYao <rye.y.cn@gmail.com>
Fix bugs in calculating area;
Fix bugs in compare method;
Fix bugs in determining relative position of two vectors;

Signed-off-by: RyeYao <rye.y.cn@gmail.com>