This works but is slow and unstable. Change to >=0 for clockwise quads.
94
Expression 95: max left parenthesis, left parenthesis, "x" minus "p" Subscript, 00 "o" "b" "j" , Baseline . "x" , right parenthesis left parenthesis, "p" Subscript, 10 "o" "b" "j" , Baseline . "y" minus "p" Subscript, 00 "o" "b" "j" , Baseline . "y" , right parenthesis minus left parenthesis, "y" minus "p" Subscript, 00 "o" "b" "j" , Baseline . "y" , right parenthesis left parenthesis, "p" Subscript, 10 "o" "b" "j" , Baseline . "x" minus "p" Subscript, 00 "o" "b" "j" , Baseline . "x" , right parenthesis , left parenthesis, "x" minus "p" Subscript, 10 "o" "b" "j" , Baseline . "x" , right parenthesis left parenthesis, "p" Subscript, 11 "o" "b" "j" , Baseline . "y" minus "p" Subscript, 10 "o" "b" "j" , Baseline . "y" , right parenthesis minus left parenthesis, "y" minus "p" Subscript, 10 "o" "b" "j" , Baseline . "y" , right parenthesis left parenthesis, "p" Subscript, 11 "o" "b" "j" , Baseline . "x" minus "p" Subscript, 10 "o" "b" "j" , Baseline . "x" , right parenthesis , left parenthesis, "x" minus "p" Subscript, 11 "o" "b" "j" , Baseline . "x" , right parenthesis left parenthesis, "p" Subscript, 01 "o" "b" "j" , Baseline . "y" minus "p" Subscript, 11 "o" "b" "j" , Baseline . "y" , right parenthesis minus left parenthesis, "y" minus "p" Subscript, 11 "o" "b" "j" , Baseline . "y" , right parenthesis left parenthesis, "p" Subscript, 01 "o" "b" "j" , Baseline . "x" minus "p" Subscript, 11 "o" "b" "j" , Baseline . "x" , right parenthesis , left parenthesis, "x" minus "p" Subscript, 01 "o" "b" "j" , Baseline . "x" , right parenthesis left parenthesis, "p" Subscript, 00 "o" "b" "j" , Baseline . "y" minus "p" Subscript, 01 "o" "b" "j" , Baseline . "y" , right parenthesis minus left parenthesis, "y" minus "p" Subscript, 01 "o" "b" "j" , Baseline . "y" , right parenthesis left parenthesis, "p" Subscript, 00 "o" "b" "j" , Baseline . "x" minus "p" Subscript, 01 "o" "b" "j" , Baseline . "x" , right parenthesis , right parenthesis less than or equal to 0maxx−p00obj.xp10obj.y−p00obj.y−y−p00obj.yp10obj.x−p00obj.x,x−p10obj.xp11obj.y−p10obj.y−y−p10obj.yp11obj.x−p10obj.x,x−p11obj.xp01obj.y−p11obj.y−y−p11obj.yp01obj.x−p11obj.x,x−p01obj.xp00obj.y−p01obj.y−y−p01obj.yp00obj.x−p01obj.x≤0