Enclosing Squares
Here's a problem to work at with your graphic calculator or graphplotting package on a computer.
If you plot the following lines
$\begin{eqnarray} y &=& 2x + 1\\ y &=& 2x + 4 \\ y &=& 0.5x + 1\\ y &=& 0.5x + 2.5 \end{eqnarray}$  Image

the lines will enclose a square.
Can you find other sets of sloping lines that enclose a square?
If you are given the equations of two parallel lines
From these two distances you can find the gradient and the length of the line segment between the points.
We have had two good answers to this problem; one from Harry from Riccarton High School in Christchurch, New Zealand, and one from Ang Zhi Ping from River Valley High School in Singapore.
Harry starts by mentioning that there are two pairs of parallel lines, that the distance between each pair of lines has to be equal and that we need to have four right angles to make a square.
The gradient of the second pair of parallel lines is going to be the negative reciprocal of the first set of parallel lines in order to make right angles (ie. the product of their gradients will be 1).
For example:
gradient of the first pair  gradient of the second pair 

2  1/2 
4  1/4 
10  1/10 
To keep the distance between each pair of lines the same, we'd have to make sure that the difference of the two yintercepts of one pair of lines is equal to the difference of the two xintercepts of the other pair.
In the example given in the question:
$y = 2x + 1$ and $y = 2x + 4$ cut the vertical axis at $(0,1)$ and
$(0,4)$, three units apart,
and $y = 0.5x + 1$ and $y = 0.5x + 2.5$ cut the horizontal axis
at $(2,0)$ and $(5,0)$, also three units apart.
\begin{eqnarray} y &=& 2x + 1\\ y &=& 2x + 4 \\ y &=& 0.5x + 1\\ y &=& 0.5x + 2.5 \end{eqnarray}  Image

Alternatively, the difference of the yintercepts of the second pair have to be the same as the difference of the $x$intercepts of the first pair.
In the example given in the question:
$y = 2x + 1$ and $y = 2x + 4$ cut the horizontal axis at $(0.5,0)$
and $(2,0)$, one and a half units apart, and $y = 0.5x + 1$ and
$y = 0.5x + 2.5$ cut the vertical axis at $(0,1)$ and $(0,2.5)$,
also one and a half units apart.
This distance can be worked out easily:
it is the difference of the $y$intercepts of the first pair
divided by the gradient.
In the example above, the difference between the $y$intercepts of $y = 2x + 1$ and $y = 2x + 4$ is three. This difference divided by the gradient of two gives us $1.5$; this is the difference between the $y$intercepts of the other pair of lines, $y = 0.5x + 1$ and $y = 0.5x + 2.5$.
Consider another example:
If you are given the equations of two parallel lines
$y = 4x  2$ and $y = 4x + 3$
and told that one of the vertices of the squares will be at
$(0,2)$
we can deduce that the equation of one of the other lines will
be
$y = 0.25x  2$ (perpendicular to the original pair with an
intercept at $2$).
Since the difference between the yintercepts of $y = 4x  2$ and
$y = 4x + 3$ is five,
the difference between the yintercepts of the other pair of lines
will be five divided by the gradient ($5/4$ or $1.25$).
One of the perpendicular lines is $y = 0.25x  2$, so the other
line can be at $y = 0.25x  0.75$,
cutting the vertical axis $1.25$ units above the first line.
\begin{eqnarray} y &=& 4x 2\\ y &=& 4x + 3 \\ y &=& 0.25x 2\\ y &=& 0.25x 0.75 \end{eqnarray}  Image

Why do this problem?
This activity enables learners to explore the concept of gradient and it follows on nicely from Perpendicular Lines . The lengths of the sides of the square being equal connects with Pythagoras Theorem and the property that, for perpendicular lines the product of the gradients is 1 (reversing the horizontal and vertical increments).
Possible Approach
The problem can be used in the early stages of working on gradients and before introducing the equation of a straight line in 2D. At this stage it will be challenging for the majority of learners and take up most of a lesson.
Although it is tagged as Stage 3, the problem can also be used at Stage 4 or 5 when it could be completed in 10 to 15 minutes.
At Stage 5, extension work could ask for the equation of the circle through the 4 vertices linking Pythagoras Theorem, the midpoint of a line segment, the distance between 2 points with given coordinates and the equation of a circle.
Key Questions
If you know the coordinates of two points how much do you go up and down on the line through the points when you go across one unit?
How do you know if 2 line segments are parallel?
How do you know if 2 line segments are perpendicular?
If you know the coordinates of two points how do you find the distance between them?
Questions for the Stage 5 Extension:
How do you find the midpoint of a square?
What do you know about points on a circle in relation to the centre of the circle?