SOE ex.8.10
Rectangle s1 s2 `containsS` p = Rectangle (-s1) s2 `containsS` p
Rectangle s1 s2 `containsS` (x,y)
= let t1 = s1 / 2
t2 = s2 / 2
in -t1 <= x && x <= t1 && -t2 <= y && y <= t2
so,
-(s1/2) <= x <= (s1/2)
<=> (-s1/2) <= x <= -(-s1/2)
so,
(s1) or (-s1), x always in the range of -(s1/2) and (s1/2).
(or in the range -(-s1/2) and (-s1/2)).
CQFD
--------------------------------------------------------------------------
Ellipse r1 r2 `containsS` p = Ellipse (-r1) r2 `containsS` p
Ellipse r1 r2 `containsS` (x,y)
= (x/r1) ^ 2 + (y/r2) ^ 2 <= 1
because:
(x/-r1) ^ 2 = (-1 * (x/r1)) ^ 2 = (-1)^2 * (x/r1)^2 = (x/r1)^2
so,
CQFD