Let S be the set of { ( 1 , 1 ) , ( 1 , − 1 ) , ( − 1 , 1 ) } -lattice path which begin at ( 1 , 1 ) , do not use the same vertex twice, and never touch either the x -axis or the y -axis. How many paths in S end at the point ( 4 , 8 ) ?
Details and assumptions
A lattice path is a path in the Cartesian plane between points with integer coordinates.
A step in a lattice path is a single move from one point with integer coordinates to another.
The size of the step from ( x 1 , y 1 ) to ( x 2 , y 2 ) is ( x 2 − x 1 , y 2 − y 1 ) .
The length of a lattice path is the number of steps in the path.
For a set S = { ( x i , y i ) } i = 1 k , an S -lattice path is a lattice path where every step has size which is a member of S .
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Drawing a diagram clears up the situation a lot. You are on (1,1), and you essentially can make unit diagonal moves NW, NE, and SE. You cannot touch the x and y axis. After drawing a grid for paths that you can take, you see that there are columns (which go SW to NE) and rows (which go SE to NW). We will handle this problem going row by row.
First, let's look at the very first row (call this row 0), which contain only the point (1,1). There is 1 way to get to this point: do nothing.
The next row (row 1) contains the points (1,3), (2,2), and (3,1). Each of these points have one way to arrive there from row 0.
Row 2 consists of (1,5), (2,4), (3,3), (4,2), (5,1). Each of these points have one way to get to there from each of the points on row 1: therefore, there are 1 + 1 + 1 = 3 ways to get to each of these points.
Similarly, each point on row 3 has one way to get to there from each point on row 2. Therefore, there are 3 + 3 + 3 + 3 + 3 = 1 5 ways to get to each point on row 3.
Continuing the pattern, there are 1 5 + 1 5 + 1 5 + 1 5 + 1 5 + 1 5 + 1 5 = 1 0 5 ways to get to each point on row 4.
There are 1 0 5 + 1 0 5 + 1 0 5 + 1 0 5 + 1 0 5 + 1 0 5 + 1 0 5 + 1 0 5 + 1 0 5 = 9 4 5 ways to get to each point on row 5. It happens that our goal point, (4,8), is on row 5, so our answer is 9 4 5 .
To make sure there aren't any extra ways to get to (4,8) from row 6, we go on row 6 and try to backtrack to (4,8). But note that once you go up a row, it is impossible to go down a row, so there are no extra ways.
The problem simply asks for the number of lattice paths which, at each step, move along the directions ↗ , ↘ , and ↖ , and don't touch the x or y axes. We call such a path a good path.
Let q a , b denote the number of good paths from ( 1 , 1 ) to the point ( a , b ) , and let n = a + b . The trick here is to consider all points on the line x + y = n , not just ( a , b ) . The picture above might help the reader visualize. The red and green colored lines are the lines of the form x + y = k for some k .
We claim that q a , b remains fixed as we move along the line x + y = n . In other words, if t n denotes the number of good paths from ( 1 , 1 ) to the line x + y = n , q a , b = t n whenever a + b = n . Let's say a good path touches the line x + y = n at the point ( p , q ) . Note that a unique series of ↘ and ↖ moves brings the point ( p , q ) to ( a , b ) if they both lie on the line x + y = n . The bijection is obvious: each good lattice path to ( a , b ) corresponds to some lattice path to the line x + y = n . Conversely, any good lattice path to the line x + y = n corresponds to a good lattice path to ( a , b ) .
We shall now try to find a recursion on t n . Let's see how the line x + y = n can be approached from the line x + y = n − 2 . Note that it cannot be approached from the line x + y = n − 1 . There are n − 3 lattice points on the line x + y = n − 2 which don't lie on either of the axes. There are t n − 2 ways to reach each of these points, and a single ↗ move brings each of these points to the line x + y = n . This gives us the recursion t n = ( n − 3 ) t n − 2 .
An easy check shows that t 2 = 1 . We now apply this recursion successively to obtain: t 4 = 1 , t 6 = 3 , t 8 = 1 5 , t 1 0 = 1 0 5 , t 1 2 = 9 4 5 . Our desired answer is t 4 + 8 = t 1 2 = 9 4 5 .
We call a lattice path good iff it passes through a lattice point at most once, its steps belong to the set { ( 1 , 1 ) , ( 1 , − 1 ) , ( − 1 , 1 ) } , and it lies solely in the first quadrant or on the positive axes. We wish to find out the number of good lattice paths starting from the origin and ending at ( 3 , 7 ) . Notice that each such lattice path can be obtained from another lattice path satisfying the conditions mentioned in the question by a ( 1 , 1 ) translation of the axes. So if we are able to find the number of such lattice paths, we will be done.
Claim
Any good lattice path starting from the origin and going to
(
a
,
b
)
must lie within the region bounded by the positive axes and the line
x
+
y
=
a
+
b
.
Proof
From the imposed conditions it is clear that any good lattice path must lie within the region bounded by the positive axes (i.e the
1
s
t
quadrant). On the contrary, assume a good lattice path exceeds the region bounded by the line
x
+
y
=
a
+
b
. Consider any point
(
m
,
n
)
on that lattice path, where
m
+
n
=
k
>
a
+
b
. From here, we wish to determine a sequence of
{
(
1
,
1
)
,
(
−
1
,
1
)
,
(
1
,
−
1
)
}
steps which will take us to a point line on the line
x
+
y
=
a
+
b
. Note that a
(
−
1
,
1
)
step will translate the point parallel to that line, whereas the steps
(
1
,
1
)
and
(
1
,
−
1
)
will take the point further from it. This is a contradiction. QED
Claim
The number of good lattice paths from the origin to
(
a
,
b
)
is equal to the number of good lattice paths from the origin to the line
x
+
y
=
a
+
b
.
Proof
Any such good lattice path must intersect the line
x
+
y
=
a
+
b
at one point, say
(
k
,
a
+
b
−
k
)
. From the first claim, once such a lattice path reaches this line, it must traverse along this line until it reaches its destination. Also note that a unique series of
{
(
1
,
−
1
)
,
(
−
1
,
1
)
}
steps brings the point
(
k
,
a
+
b
−
k
)
to
(
a
,
b
)
. This proves our desired claim. QED
Let L n be the number of good lattice paths from the origin to the line x + y = n . Note that we wish to determine L 7 + 3 = L 1 0 . Let T a , b be the number of good lattice paths from the origin to the point ( a , b ) which intersects the line x + y = a + b at one point only (namely the point ( a , b ) ). Note that L n = k = 0 ∑ n T k , n − k . We now make the following observations:
1 ) Note that \T {n,0}= T {0,n}= 0). This is obviously true, since those points can be approached only from the point ( n − 1 , 1 ) and ( 1 , n − 1 ) respectively, but both of them lie on the line x + y = n , and hence do not appear in the count of T n , 0 or T 0 , n .
2 ) Consider a point ( m , n − m ) on the line x + y = n , such that 2 ≤ m ≤ n − 2 . Note that this point can be approached from the points ( m + 1 , n − m − 1 ) , ( m − 1 , n − m + 1 ) , and ( m − 1 , n − m − 1 ) . However, out of them the first two points lie on the line x + y = n , and therefore do not appear in the count of T m , n − m . Also note that the line ( m − 1 , n − m − 1 ) lies on the line x + y = n − 2 . Hence we conclude T m , n − m = f ( n − 2 ) . Now, note that: f ( n ) = k = 0 ∑ n T k , n − k = T 0 , n + T n , 0 + k = 1 ∑ n − 1 T k , n − k = k = 1 ∑ n − 1 f ( n − 2 ) = ( n − 1 ) f ( n − 2 ) .....(i) An easy check shows that f ( 2 ) = 1 . We now apply the recurrence relation in ( i ) successively to obtain: f ( 4 ) = 3 × 1 = 3 f ( 6 ) = 5 × 3 = 1 5 f ( 8 ) = 7 × 1 5 = 1 0 5 f ( 1 0 ) = 9 × 1 0 5 = 9 4 5
This solution contains a lot of typos, I am so sorry for that (I had to write this the second time). Typo # 1
From here, we wish to determine a sequence of { ( 1 , 1 ) , ( 1 , − 1 ) , ( − 1 , 1 ) } steps which will take us to a point line on the line x + y = a + b
This should have been:
From here, we wish to determine a sequence of { ( 1 , 1 ) , ( 1 , − 1 ) , ( − 1 , 1 ) } steps which will take us to a point lying on the line x + y = a + b
Typo # 2
This is obviously true, since those points can be approached only from the point ( 1 , n − 1 ) and ( n − 1 , 1 )
This should have been:
This is obviously true, since those points can be approached only from the point s ( 1 , n − 1 ) and ( n − 1 , 1 )
Typo # 3
Note that \T{n,0}= T{0,n}= 0)
This should have been:
Note that T n , 0 = T 0 , n = 0
Typo # 4
Consider a point ( m , n − m ) such that 2 ≤ m ≤ n − 2
This should have been:
Consider a point ( m , n − m ) such that 1 ≤ m ≤ n − 1
Typo # 5
Note that the line ( m − 1 , n − m − 1 ) lies on the line x + y = n − 2
This should have been:
Note that the point ( m − 1 , n − m − 1 ) lies on the line x + y = n − 2
Also, at the end I accidentally replaced L n with f ( n ) , so you might as well assume L n = f ( n ) for all n . :)
Log in to reply
Typo solution! :)
Log in to reply
I'll probably get my name listed in the Guinness Book of World Records for the number of typos in this solution. :)
1 x 3 x 5 x 7 x 9 In fact, per each step from 1;1 to 2;2 we can draw a rectangle of dimensions (1, 3/5/7/9)
In order to end at ( 4 , 8 ) , a path in S must have exactly 5 steps of size ( 1 , 1 ) . Specifically, the nth such step will be from ( n + k n , n − k n ) to ( n + 1 + k n , n + 1 − k n ) with k n ∈ { 1 − n , . . . , 0 , . . . , n − 1 } . Then the total numbers of ways of choosing those 5 steps of size ( 1 , 1 ) is
1 ⋅ 3 ⋅ 5 ⋅ 7 ⋅ 9 = 9 4 5
and each such choice corresponds to exactly one path in S ending at ( 4 , 8 ) (i.e. there's exactly one legal way to get from ( n + 1 + k n , n + 1 − k n ) to ( n + 1 + k n + 1 , n + 1 − k n + 1 ) ).
Problem Loading...
Note Loading...
Set Loading...
Let Q n be the set of points ( x , y ) such that x + y = 2 n and it is legal to move to this point, i.e. x , y > 0 . Clearly ∣ Q n ∣ = 2 n − 1 .
The moves ( 1 , − 1 ) and ( − 1 , 1 ) therefore take us from a point in some Q n to another point in the same Q n .
The move ( 1 , 1 ) takes us from Q n to Q n + 1 . There are no other ways to change our Q level.
So, a valid path must consist of exactly one ( 1 , 1 ) move starting from a point in Q k − 1 and ending at a point in Q k , for all 2 ≤ k < 6 , because ( 4 , 8 ) is in Q 6 ; and some other moves which move "sideways" within a Q set.
Further, making a selection of such points Q k defines a unique path. To see this, suppose that we choose ( x , 2 n − x ) ∈ Q n and ( w , ( 2 n + 2 ) − w ) ∈ Q n + 1 as the endpoints of ( 1 , 1 ) moves. The latter move must have started at the point ( w − 1 , 2 n − ( w − 1 ) ) in Q n . But to move from one point in Q n to another point in Q n there is only one possible path, since the rules prohibit backtracking.
So we just need to count how many ways of selecting the points Q k where k goes up to 5. We are selecting ( 4 , 8 ) specifically in Q 6 . This is k = 2 ∏ 5 ∣ Q k ∣ , which is 3 × 5 × 7 × 9 = 9 4 5 .