Prove the intersection of open rectangles/triangles are union of elements of B I'm proving that the open rectangles and triangles are basis for the euclidean topology on $R^2$, I defined the topology as open rectangles with sides parallel to the axis, others do it with open disc. I need to show that the intersection of any open rectangles (and triangles for the other exercise) is the union of open rectangles with sides paraller to the axis. I don't know how to model those sets (inequalities or something) and solve that problem without visual geometric arguments.
 A: Let's prove that rectangles form a basis for Euclidean topology on $\mathbb R^2$.
Let $R((x_1,x_2),a,b)=(x_1-a,x_1+a)\times(x_2-b,x_2+b)$ for $x\in\mathbb R^2$ and $a,b>0$. Let $\mathcal B'=\{R(x,a,b)\;|\;x\in\mathbb R^2, a>0, b>0\}$ and let $\mathcal B$ be the usual basis of open disks for Euclidean topology. We'll make the proof in two steps.


*

*First step, check $\mathcal B \subset \tau(\mathcal B')$. Here, $\tau(\mathcal B')$ denotes the topology, generated by the basis of rectangles $\mathcal B'$. To see this, it's enough to check that $\forall B\in\mathcal B:\forall y\in B:\exists B'\in \mathcal B': y\in B'\subset \mathcal B'$. What I just wrote means that for every disk in $\mathbb R^2$ and any point inside the disk we can find a rectangle such that the point is inside the rectangle and the rectangle is a subset of the disk. It is obvious that we can achieve this, but let's really derive it. Let $x\in \mathbb R^2$ and $r>0$ and let $y\in D(x,r)$. Denote the  distance between the point $x$ and $y$ with $\lVert x-y\rVert$. Then, the distance between the point $y$ and the boundary of the disk is $r-\lVert x-y\rVert=:a(x,y,r)$. It is now obvious that $R(y,\frac{a(x,y,r)}{\sqrt{2}},\frac{a(x,y,r)}{\sqrt 2})$ contains $y$ and lies inside the chosen disk, i.e. $y\in R(y,\frac{a(x,y,r)}{\sqrt{2}},\frac{a(x,y,r)}{\sqrt 2})\subset D(x,r)$. The square root of $2$ comes from Pythagorean theorem; we need to watch out that our rectangle does not fall outside the disk. Draw a picture for intuition.

*Second step, check $\mathcal B'\subset \tau(\mathcal B)$. Similarly, for any open rectangle in $\mathbb R^2$ and any point inside it, we must now find a circle that contains the point and is inside the rectangle. Let $x=(x_1,x_2)\in\mathbb R^2$ and $a,b>0$ and let $y=(y_1,y_2)\in R(x,a,b)$. Now let $c=\min\{a-|x_1-y_1|,b-|x_2-y_2|\}$ be the shortest distance between point $y$ and the rectangle's boundary. Now $y\in D(y,c)\subset R(x,a,b)$.
Why was it enought to check these two things only? Well, now that we've seen this, we can represent any disk as a union of rectangles:
$$
D(x,r)=\cup\{R(y,\frac{a(x,y,r)}{\sqrt{2}},\frac{a(x,y,r)}{\sqrt{2}})\;|\; y\in D(x,r)\}
$$
and similarly for the other direction.
A: Let U be an open set.  Since B is a base, for all x in U
there is some $U_x$ in B with x in $U_x$ subset U.
Show that $\cup\{ U_x : x \in U \} = U.$  
Letting U be the intersection of two open sets
will suffice for the triangles and rectangles.
Usually there will infinitely many rectangles that get
smaller and smaller to fit into the open intersection.  
