Engaging students: Synthetic Division

In my capstone class for future secondary math teachers, I ask my students to come up with ideas for engaging their students with different topics in the secondary mathematics curriculum. In other words, the point of the assignment was not to devise a full-blown lesson plan on this topic. Instead, I asked my students to think about three different ways of getting their students interested in the topic in the first place.

I plan to share some of the best of these ideas on this blog (after asking my students’ permission, of course).

This student submission comes from my former student Chelsea Hancock. Her topic, from Precalculus: synthetic division.

green line

The method of synthetic division is an alternative version of long division concerning polynomials. Synthetic division uses the basic mathematical skills of addition, subtraction, multiplication, and negative signs. They must also understand the definitions of polynomial, coefficient, and remainder. A polynomial is an expression with multiple terms, poly meaning “many” and nomial meaning “term.” A coefficient is a number used to multiply a variable. The remainder is the amount left over after division. Synthetic division involves multiplying, then adding or subtracting the coefficients of two polynomials. On some occasions, there will be a remainder after dividing the polynomials.

 

green line

Mathematicians are lazy. That is a fact of life. One mathematician understood this, so in 1809 he created a cleaner, faster, and much simpler method for division. His name was Paolo Ruffini. In order to more efficiently divide polynomials, Ruffini invented the Ruffini’s Rule, known more commonly as synthetic division in today’s society. In 1783, he entered the University of Modena and he studied mathematics, medicine, philosophy and literature. Then, in 1798 he began teaching mathematics at the University of Modena. He was required to swear an oath of allegiance to the republic, but due to religious purposes, refused to do so. This resulted in the loss of his professorship and was prevented from teaching.

 

green line

There are several videos on the Internet involving synthetic division, but there are two in particular that I personally think are excellent demonstrations of both the method itself and why it works. I have labeled these clips Video 1 and Video 2. Video 1 is a demonstration of the method in action, using a specific example involving numbers, walking the viewers through the process through the whole video. Video 2 explains why using synthetic division instead of using long division is the more efficient and less complicated method for dividing polynomials. The clip uses the same example used in Video 1, but this time the polynomials are divided using long division, walking the viewers through the process the entire time. As the narrator moves through the process, he makes connections between the synthetic division method and the long division method and draws conclusions between the two. By the end of the video, it is evident which is the cleanest method to use when concerning the division of polynomials. These videos not only give great tutorials on both methods of division, but allows the viewers to see the benefits and uses of synthetic division when it is possible to use it.

 

Video 1:

Video 2:

References

 

http://www.mathsisfun.com/algebra/polynomials.html

 

http://www.mathsisfun.com/definitions/coefficient.html

 

http://www.mathsisfun.com/definitions/remainder.html

 

http://www-groups.dcs.st-and.ac.uk/~history/Biographies/Ruffini.html

 

http://www.personal.psu.edu/djh300/cyhs/trig/unit-e-adv-polyn/06-05-02-synth-div.pdf

 

https://www.khanacademy.org/math/algebra2/polynomial_and_rational/synthetic-division/v/synthetic-division

 

https://www.khanacademy.org/math/algebra2/polynomial_and_rational/synthetic-division/v/why-synthetic-division-works

 

 

 

 

Engaging students: Introducing the number e

In my capstone class for future secondary math teachers, I ask my students to come up with ideas for engaging their students with different topics in the secondary mathematics curriculum. In other words, the point of the assignment was not to devise a full-blown lesson plan on this topic. Instead, I asked my students to think about three different ways of getting their students interested in the topic in the first place.

I plan to share some of the best of these ideas on this blog (after asking my students’ permission, of course).

This student submission comes from my former student Kenna Kilbride. Her topic, from Precalculus: introducing the number e.

green line

How can this topic be used in your students’ future courses in mathematics or science?

 

Students will add on to this constant from calculus up to differential equations and even further. In Calculus I students use the number e to solve exponential functions and logarithm function. Calculus II uses the number e when computing integrals. In Complex Numbers you see the number e written as the Taylor series

$latex e^x = \displaystyle \sum_{n=0}^\infty \frac{x^n}{n!}

Differential equations utilizes the number e in y(x) = Ce^x. The number e can be utilized in many other areas since it is considered to be a base of the natural logarithm. The number e is also defined as:

e = \displaystyle \lim_{x \to \infty} \left(1 + \frac{1}{x} \right)^x

Also the number e can be seen in the infinite series

$latex e = \sum_{k=0}^\infty \frac{1}{k!}

The number e can be seen in many different areas of mathematics and with many different series and equations. Stirling’s approximation, Pippenger product, and Euler formula are just a few more examples of where you can see the number e.

http://mathworld.wolfram.com/e.html

http://tutorial.math.lamar.edu/Classes/CalcII/ImproperIntegralsCompTest.aspx

 

 

green line

What interesting (i.e., uncontrived) word problems using this topic can your students do now? (You may find resources such as http://www.spacemath.nasa.gov to be very helpful in this regard; feel free to suggest others.)

 

Introducing this constant can be a very hard thing for a teacher to do and using a word problem that involves a satellite that students can comprehend what they do in the sky will help.

A satellite has a radioisotope power supply. The power output in watts is given by the equation

P = 50e^(-t/250)

where t is the time in days and e is the base of natural logarithms.

Then when introducing, e, you can give them problems that they can easily solve without fully understanding what e is. Give them problems such as, how much power will be available in a year. The solution is:

P = 50e^(-365/250)

= 5Oe^(-1.46)

= 50 x 0.232

= 11 .6

Once e has been more formally introduced and the students can then become more familiar (this should only be added on when the students fully understand e) you can add onto this problem by giving them questions such as, what is the half-life of the power supply? Students must use natural log to solve this equation:

25 = 50e^(-t/250)

for t and obtain

– t/250 = ln O.5

= -0.693

t = 250 x 0.693

= 173 days

http://er.jsc.nasa.gov/seh/math49.html

green line

What interesting things can you say about the people who contributed to the discovery and/or the development of this topic? (You might want to consult Math Through The Ages.)

 

John Napier was born in Scotland around 1550. Napier started attending St. Andrews University at the age of 13. After leaving St. Andrews without a degree he attended Cambridge University. Later he studied abroad, presumably in Paris. In 1614 Napier invented logarithms and later exponential expressions. Along with mathematics, Napier was interested in peace keeping and religion. Napier died on April 4, 1617 of gout.

Euler contributed to e, a mathematical constant. He was born 1707 in the town Basel of Switzerland. By the age of 16 he had earned a Master’s degree and in 1727 he applied for a position as a Physics professor at the University of Basel and was turned down. Due to extreme health problems by 1771 he had lost almost all of his vision. By the time of his death in 1783, the Academy of Sciences in Petersburg had received 500 of his works.

 

http://www.macs.hw.ac.uk/~greg/calculators/napier/great.html

http://www.pdmi.ras.ru/EIMI/EulerBio.html

 

Story of George Dantzig

Every math teacher should be familiar with this famous story concerning George B. Dantzig (1914-2005). Dantzig is universally hailed as the Father of Linear Programming for his development of the simplex method, which was named one of the top 10 algorithms of the 20th century. The following story happened while he was a graduate student at the University of California.

 

If you search the Web for “urban legend George Dantzig” you will probably find the first hit to be “Snopes.com, The Unsolvable Math Problem.” That site recounts the story of how George, coming in late for class, mistakenly thought two problems written on the board by Neyman were homework problems. After a few days of struggling, George turned his answers in. About six weeks later, at 8 a.m. on a Sunday morning, he and Anne were awakened by someone banging on their front door. It was Neyman who said, “I have just written an introduction to one of your papers. Read it so I can send it out right away for publication.”

George’s answers to the homework problems were proofs of then two unproven theorems in statistics. The Web site gives all the details about how George’s experiences ended up as a sermon for a Lutheran minister and the basis for the film, “Good Will Hunting.” The solution to the second homework problem became part of a joint paper with Abraham Wald who proved it in 1950, unaware that George had solved it until it was called to his attention by a journal referee. Neyman had George submit his answers to the “homework” problems as his doctoral dissertation.

Source: http://www.orms-today.org/orms-8-05/dantzig.html

True story: my own paths actually overlapped with Dantzig’s once. When I was a sophomore in college and he was a professor emeritus, we both attended the same seminar, and he was stick as sharp as a tack. However, I couldn’t build up enough courage to introduce myself to the great man.

 

Engaging students: Computing trigonometric functions

In my capstone class for future secondary math teachers, I ask my students to come up with ideas for engaging their students with different topics in the secondary mathematics curriculum. In other words, the point of the assignment was not to devise a full-blown lesson plan on this topic. Instead, I asked my students to think about three different ways of getting their students interested in the topic in the first place.

I plan to share some of the best of these ideas on this blog (after asking my students’ permission, of course).

This student submission comes from my former student Nataly Arias. Her topic, from Precalculus: computing trigonometric functions.

green line

How has this topic appeared in pop culture (movies, TV, current music, video games, etc.)?

 

Trigonometry does not only relate to mathematics, trigonometry is also used in real life. Many people don’t know that trigonometry is involved in video games. In game development, there are many situations where you will need to use trig functions. Video games are full of triangles. For example in order to calculate the direction the player is heading you will form a triangle and use sine, cosine, or tangent to solve. The trig function used depends on the values given. For example if the opposite and adjacent values are given (the xSpeed and ySpeed), the function you will need to calculate the direction of the player is tangent. This is represented by the equation Tan( Dir ) = xSpeed /ySpeed. Again, by applying the inverted function of tan to both sides of the equal sign, we get an equation that will return the player’s direction. In a spaceship game you will need to use trigonometric functions to have one ship shoot a laser in the direction of the other ship, play a warning sound effect if an enemy ship is getting too close, or have one ship start moving in the direction of another ship to chase. Trig is used in several situations in video games some more examples include calculating a new trajectory after a collision between two objects such as billiard balls, rotating a spaceship or other vehicle, properly handling the trajectory of projectiles shot from a rotated weapon, and determining if a collision between two objects is happening.

 

green line

How has this topic appeared in high culture (art, classical music, theatre, etc.)?

 

The “unit circle” is a circle with a radius of 1 that is centered at the origin in the Cartesian coordinate system in the Euclidean plane. Because the radius is 1 we can directly measure sine, cosine, and tangent. The unit circle has made parts of mathematics easier and neater. The concepts of the unit circle go far back into the past. Not only do we use and see circles in mathematics we also can see circles in art form. We can also use trigonometric functions to determine the best position to view a painting hanging on an art gallery wall. For example you can determine the angle between a person’s eye and the top and base of the painting when a person is standing 1m away, 2 m away, 3 m away and so on. By comparing your data you can estimate the best position for a person to stand in front of the painting. Also using trig functions and your handy calculator you can develop a formula that describes the relationship between the distance away from the painting and the angle that exists between the person’s eye and the top and bottom of the painting.

 

 

 

green line

How have different cultures throughout time used this topic in their society?

 

Today the unit circle is used as a helpful tool to help calculate trig functions. Trig functions are taught in trigonometry, pre-calculus and are frequently used in advanced math classes. Many people don’t realize that not only are trig functions learned and used in school but throughout time several cultures have used trig functions in their society. The main application of trigonometry in past cultures was in astronomy. In 1900 BC the Babylonians kept details of stars, the motion of planets, and solar eclipses by using angular distance measured on the celestial sphere. In 1680-1620 BC the Egyptians used ancient forms of trigonometry for building pyramids. The idea of dividing a circle into 360 equal pieces goes back to the sexagesimal counting system of the ancient Sumerians. Early astronomical calculations wedded the sexagesimal system to circles and the rest is history. Today in trigonometry the unit circle has a radius of 1 unlike the Greek, Indian, Arabic, and early Europeans who used a circle of some other convenient radius. In today’s society trigonometry is everywhere. The mathematics used behind trigonometry is the same mathematics that allows us to store sound waves digitally onto a CD. We use it without even knowing it. When we plug something into the wall there is trigonometry involved. The sine and cosine wave are the waves that are running through the electrical circuit known as alternating current.


References

 

http://www.math.ucdenver.edu/~jloats/Student%20pdfs/40_Trigonometry_Trenkamp.pdf

 

http://www.math.dartmouth.edu/~matc/math5.geometry/unit9/unit9.html

 

http://en.wikipedia.org/wiki/Trigonometric_functions

 

http://aleph0.clarku.edu/~djoyce/ma105/trighist.html

 

http://www.slideshare.net/mgeis784/building-the-unit-circle

 

http://www.softlion.nl/download/article/Trigonometry.pdf

 

http://www.raywenderlich.com/35866/trigonometry-for-game-programming-part-1

 

http://stackoverflow.com/questions/3946892/trigonometry-and-game-development

 

Engaging students: Verifying trigonometric identities

In my capstone class for future secondary math teachers, I ask my students to come up with ideas for engaging their students with different topics in the secondary mathematics curriculum. In other words, the point of the assignment was not to devise a full-blown lesson plan on this topic. Instead, I asked my students to think about three different ways of getting their students interested in the topic in the first place.

I plan to share some of the best of these ideas on this blog (after asking my students’ permission, of course).

This student submission comes from my former student Michelle McKay. Her topic, from Precalculus: verifying trigonometric identities.

green line

How could you as a teacher create an activity or project that involves your topic?

polar3

Engaging students with trigonometric identities may seem daunting, but I believe the key to success for this unit lies within allowing students to make the discovery of the identities themselves.

For this particular activity, I will focus on some trigonometric identities that can be derived using the Pythagorean Theorem. Before beginning this activity, students must already know about the basic trig functions (sine, cosine, and tangent) along with their corresponding reciprocals (cosecant, secant, and cotangent).

Using this diagram (or a similar one), have students write out the relationship between all sides using the Pythagorean Theorem.
Students should all come to the conclusion of: x2 + y2 = r2.

For higher leveled students, you may want to remind them of the adage SohCahToa, with emphasis on sine and cosine for this next part. You might ask, “How can we rearrange the above equation into something remotely similar to a trigonometric function?”

Ultimately, we want students to divide each side by r2. This will give us:

Again, SohCahToa. Students, perhaps with some leading questions, should see that we can substitute sine and cosine functions into the above equation, giving us the identity:

cos2θ + sin2θ = 1

From this newly derived identity, students can then go on to find tan2θ + 1 = sec2θand then 1 + cot2θ = csc2θ.

 

green line

How can technology be used to effectively engage students with this topic?

For engaging the students and encouraging them to play around with identities, I find the Trigonometric Identities Solver by Symbolab to be a fabulous technological supplement. Students can enter in identities that they may need more help understanding and this website will state whether the identity is true or not, and then provide detailed steps on how to derive the identity.
A rather fun activity that may utilize this site is to challenge the students to come up with their own elaborate trigonometric identity.

SymbolLab

Another online tool students can explore is the interactive graph from http://www.intmath.com. In fact, students could also use this right after they derive the identities from the earlier activity. This site does a wonderful job at providing a visual representation of the trigonometric functions’ relationships to one another. It also allows the students to explore the functions using concrete numbers, rather than the general Ө. Although this site only shows the cos2θ + sin2θ = 1identity in action, it would not be difficult for students to plug in the data from this graph to numerically verify the other identities.

trig1

 

green line

What are the contributions of various cultures to this topic?

 

The beginning of trigonometry began with the intention of keeping track of time and the quickly expanding interest in the study of astronomy. As each civilization inherited old discoveries from their predecessors, they added more to the field of trigonometry to better explain the world around them. The below table is a very brief compilation of some defining moments in trigonometry’s history. It is by no means complete, but was created with the intention to capture the essence of each civilization’s biggest contributions.

 

Civilization People of Interest Contributions
Egyptians
  • Ahmes
– Earliest ideas of angles.- The Egyptian seked was the cotangent of an angle at the base of a building.
Babylonians – Division of the circle into 360 degrees.- Detailed records of moving celestial bodies (which, when mapped out, resembled a sine or cosine curve).- May have had the first table of secants.
Greek
  • Aristarchus
  • Menelaus
  • Hippocharus
  • Ptolemy
– Chords.- Trigonometric proofs presented in a geometric way.- First widely recognized trigonometric table: Corresponding values of arcs and chords.- Equivalent of the half-angle formula.
Indian
  • Aryabhata
  • Bhaskara I
  • Bhaskara II
  • Brahmagupta
  • Madhava
– Sine and cosine series.- Formula for the sine of an acute angle.- Spherical trigonometry.- Defined modern sine, cosine, versine, and inverse sine.
Islamic
  • Muhammad ibn Mūsā al-Khwārizmī
  • Muhammad ibn Jābir al-Harrānī al-Battānī
  •  Abū al-Wafā’ al-Būzjānī
–          – First accurate sine and cosine tables.-          – First table for tangent values.-          – Discovery of reciprocal functions (secant and cosecant).-          – Law of Sines for spherical trigonometry.-          – Angle addition in trigonometric functions.
Germans – “Modern trigonometry” was born by defining trigonometry functions as ratios rather than lengths of lines.

 

It is interesting to note that while the Chinese were making many advances in other fields of mathematics, there was not a large appreciation for trigonometry until long after they approached the study and other civilizations had made significant contributions.

 

 

Sources

  1. http://www.intmath.com/analytic-trigonometry/1-trigonometric-identities.php
  2. http://www.intmath.com/analytic-trigonometry/trig-ratios-interactive.php
  3. http://symbolab.com/solver
  4. http://www.trigonometry-help.net/history-of-trigonometry.php
  5. http://nrich.maths.org/6843&part=
  6. http://www.scribd.com/doc/33216837/The-History-of-Trigonometry-and-of-Trigonometric-Functions-May-Span-Nearly-4
  7. http://www.britannica.com/EBchecked/topic/605281/trigonometry/12231/History-of-trigonometry

2048 and algebra (Part 10)

In this series of posts, I used algebra to show that 114,795 moves were needed to produce the following final board. This board represents the event horizon of 2048 that cannot be surpassed.

2048-0

I reached after about four weeks of intermittent doodling. It should be noted that the above game board was accomplished in practice mode, and I needed perhaps a couple thousand undos to offset the bad luck of a tile randomly appearing in an unneeded place.

For what it’s worth, my personal best in game mode was reaching the 8192-tile. I’m convinced that, even with the random placements of the new 2-tiles and 4-tiles, the skilled player can reach the 2048-tile nearly every time and should reach the 4096-tile most of the time.  However, reaching the 8192-tile requires more luck than skill, and reaching the 16384-tile requires an extraordinary amount of luck.

So what are the odds of a skilled player reaching the event horizon in game mode, without the benefit of undoing the previous move? I will employ Fermi estimation to approach this question. Of the approximately 100,000 moves, I estimate that about 5% of the moves require a certain 2-tile or 4-tile to appear at a certain location on the board. For example, in the initial stages of the game, the board is wide open and really doesn’t matter a whole lot where the new tiles appear. However, when the board gets quite crowded, it’s essential that new tiles appear in certain places, or else even a highly skilled player will get stuck.

What is the probability of getting the right tile on each of these occasions? Usually it’s quite high (over 90%). But sometimes it’s necessary to get a 4-tile in exactly the right place when there are four blank spaces (estimated probability of 3%). So let’s estimate 10% to be the probability for getting the right tile for all of these occasions. Let’s also assume that the random number generator is indeed random, so that the tiles appear independently of all other tiles.

With these estimates, I can estimate the probability of reaching the event horizon in game as \displaystyle \left( \frac{1}{10} \right)^{5000} = \displaystyle \frac{1}{10^{5000}}. While this analysis isn’t foolproof, it sure beats playing the game about 10^{10,000} times and then dividing by the number of times the event horizon is reached by the total number of attempts!

How small is \displaystyle \frac{1}{10^{5000}}? Since 2^3 \approx 10, this is approximately equal to \displaystyle \frac{1}{2^{15,000}}, and that’s a probability so small that it was reached (and surpassed) when the Heart of Gold spaceship activated the Infinite Improbability Drive in The Hitchhiker’s Guide to the Galaxy. By way of comparison:

  • \displaystyle \frac{1}{2^{276,709}} is the probability that someone stranded in the vacuum of space will be picked up by a starship within 30 seconds.
  • \displaystyle \frac{1}{2^{100,000}} is the probability of skidding down a beam of light… or having a million-gallon vat of custard appearing in the sky and dumping its contents on you without warning.
  • \displaystyle \frac{1}{2^{75,000}} is the probability of a person turning into a penguin.
  • \displaystyle \frac{1}{2^{50,000}} is the probability of having one of your arms suddenly elongate.
  • \displaystyle \frac{1}{2^{20,000}} is the probability of an infinite number of monkeys randomly typing out Hamlet.

These are the events to which the probability of reaching the event horizon in 2048 without any undos should be compared.

 

 

 

 

2048 and algebra (Part 9)

In this series of posts, I consider how algebra can be used to answer a question about the 2048 game: From looking at a screenshot of the final board, can I figure out how many moves were needed to reach the final board? Can I calculate how many new 2-tiles and 4-tiles were introduced to the board throughout the course of this game? In this post, we consider the event horizon of 2048, which I reached after about four weeks of intermittent doodling:

2048-0

In yesterday’s post, we developed a system of two equations in two unknowns to solve for t and f, the number of 2-tiles and 4-tiles (respectively) that appeared throughout the course of the game:

2t + 4f = \displaystyle \sum_{n=2}^{17} 2^n.

2t + \displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = 3,867,072

In this post and tomorrow’s post, I consider how the two sums in the above equations can be obtained without directly adding the terms.

In yesterday’s post, we used the formula for the sum of a finite geometric series to calculate the second sum:

\displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = 14 \times 2^{18} + 2^3 = 3,670,024

In this post, I perform this calculation again, except symbolically and more compactly. The key initial steps are writing the series as a double sum and then interchanging the order of summation (much like reversing the order of integration in a double integral). This is a trick that I’ve used again and again in my own research efforts, but it seems that the students that I teach have never learned this trick. Here we go:

\displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = \displaystyle \sum_{n=1}^{15} \sum_{k=1}^n 2^{n+2} = \displaystyle \sum_{k=1}^{15} \sum_{n=k}^{15} 2^{n+2}

The inner sum is a finite geometric series with 15-k+1 terms, common ratio of 2, and initial term 2^{k+2}. Therefore,

\displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = \displaystyle \sum_{k=1}^{15} \frac{ 2^{k+2} \left(1 - 2^{15-k+1} \right) }{1 - 2}

= \displaystyle \sum_{k=1}^{15} \left(2^{18} - 2^{k+2} \right)

= \displaystyle \sum_{k=1}^{15} 2^{18} -\sum_{k=1}^{15} 2^{k+2}

 The first sum is merely the sum of a constant. The second sum is another finite geometric series with 15 terms, common ratio of 2, and initial term 2^3. So

\displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = 15 \times 2^{18} - \displaystyle \frac{ 2^3 \left(1 - 2^{15} \right) }{1 - 2}

\displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = 15 \times 2^{18} - \left( 2^{18} - 2^3 \right)

\displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = 14 \times 2^{18} + 2^3

\displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = 3,670,024

2048 and algebra (Part 8)

In this series of posts, I consider how algebra can be used to answer a question about the 2048 game: From looking at a screenshot of the final board, can I figure out how many moves were needed to reach the final board? Can I calculate how many new 2-tiles and 4-tiles were introduced to the board throughout the course of this game? In this post, we consider the event horizon of 2048, which I reached after about four weeks of intermittent doodling:

2048-0

In yesterday’s post, we developed a system of two equations in two unknowns to solve for t and f, the number of 2-tiles and 4-tiles (respectively) that appeared throughout the course of the game:

2t + 4f = \displaystyle \sum_{n=2}^{17} 2^n.

2t + \displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = 3,867,072

In this post and tomorrow’s post, I consider how the two sums in the above equations can be obtained without directly adding the terms.

In yesterday’s post, we showed that the formula for the sum of a finite geometric series can be used to calculate the first sum:

\displaystyle \sum_{n=2}^{17} 2^n = \displaystyle \frac{4(1-2^{16})}{1-2} = 4(2^{15} - 1) = 262,140

Let’s now consider the second (and more complicated) sum, which can be written as

2^3 + 2 \cdot 2^4 + 3 \cdot 2^5 + \cdot + 15 \cdot 2^{17}

For reasons that will become clear shortly, this sum can be written in expanded form as

2^3

+ 2^4 + 2^4

+ 2^5 + 2^5 + 2^5

\vdots

+ 2^{17} + 2^{17} + 2^{17} + \dots + 2^{17}

 Let’s now rearrange the terms of this sum. We will do this by adding along the diagonals instead of along the rows. In this way, the above sum can be rearranged as

2^3 + 2^4 + 2^5 + \dots + 2^{17}

+ 2^4 + 2^5 + \dots + 2^{17}

+ 2^5 + \dots + 2^{17}

\vdots

+ 2^{17}

Each of these new rows (or the original diagonals) is a geometric series and can be calculated using the formula:

2^3 + 2^4 + 2^5 + \dots + 2^{17} = \displaystyle \frac{2^3 (1-2^{15})}{1-2} = 2^{18} - 2^3

2^4 + 2^5 + \dots + 2^{17} = \displaystyle \frac{2^4 (1-2^{14})}{1-2} = 2^{18} - 2^4

2^5 + \dots + 2^{17} = \displaystyle \frac{2^5 (1-2^{13})}{1-2} = 2^{18} - 2^5

\vdots

2^{17} = (2-1) \cdot 2^{17} = 2^{18} - 2^{17}

So, thus far in the calculation, we have established that

\displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = \displaystyle \sum_{n=3}^{17} \left( 2^{18} - 2^n \right).

Simplifying,

\displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2}=\displaystyle \sum_{n=3}^{17} 2^{18} - \sum_{n=3}^{17} 2^n

The first sum on the right is the sum of a constant being added to itself 15 times:

\displaystyle \sum_{n=3}^{17} 2^{18} = 15 \times 2^{18}

The second sum on the right is yet another geometric series. Indeed, it’s the same geometric  series from the first diagonal above:

\sum_{n=3}^{17} 2^n = \displaystyle \frac{2^3 (1-2^{15})}{1-2} = 2^{18} - 2^3

Therefore,

\displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = 15 \times 2^{18} - \left(2^{18} - 2^3 \right)

\displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = 14 \times 2^{18} + 2^3

\displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = 3,670,024

Not surprisingly, this matches the sum that was found via direct addition.

2048 and algebra (Part 7)

In this series of posts, I consider how algebra can be used to answer a question about the 2048 game: From looking at a screenshot of the final board, can I figure out how many moves were needed to reach the final board? Can I calculate how many new 2-tiles and 4-tiles were introduced to the board throughout the course of this game? In this post, we consider the event horizon of 2048, which I reached after about four weeks of intermittent doodling:

2048-0

In yesterday’s post, we developed a system of two equations in two unknowns to solve for t and f, the number of 2-tiles and 4-tiles (respectively) that appeared throughout the course of the game:

2t + 4f = \displaystyle \sum_{n=2}^{17} 2^n.

2t + \displaystyle \sum_{n=1}^{15} n \cdot 2^{n+2} = 3,867,072

In this post and tomorrow’s post, I consider how the two sums in the above equations can be obtained without directly adding the terms.

The first sum is certainly the easiest to handle, as it requires the sum of a finite geometric series:

a + ar + ar^2 + \dots + a r^{n-1} = \displaystyle \sum_{i=1}^n a r^{i-1} = \displaystyle \frac{a(1-r^n)}{1-r}

For the geometric series

\displaystyle \sum_{n=2}^{17} 2^n,

there are 16 terms (after all, there are 16 tiles on the board). The first term is 4, and the common ratio is 2. Therefore,

\displaystyle \sum_{n=2}^{17} 2^n = \displaystyle \frac{4(1-2^{16})}{1-2}

\displaystyle \sum_{n=2}^{17} 2^n = 4(2^{15} - 1)

\displaystyle \sum_{n=2}^{17} 2^n = 262,140

We’ll consider the more complicated sum in tomorrow’s post.