While reading an article on architecture this week, I stumbled upon a statement saying that in the future 80% of jobs will require math and physics skills. I mentioned this to my kids to motivate their occasionally fading math homework spirits and it seemed to energize them a bit. But the best trick that really lights up their minds is an illustration of how math is relevant to the occupations of their dreams. In our home this may mean a story about the collapse of a roof in the new Paris airport terminal for my son, who (currently) wants to be an architect, or discussion of NFL players' statistical models, or a girl movie mentioning the math of ice skating (Ice Princess).
But while math is omnipresent in most professions, some of the best playgrounds for math skills have always been: special effects, national defense and medicine. Math majors always felt like kids in a candy shop in these fields, liberating hours of manual labor and allowing for projects to be done cheaper, faster, safer and more realistically. As a special effects veteran, I am happy to share with you a math trick that I have used in the past in the movies "Air Force One," "Multiplicity," "Desperate Measures" and "Starship Troopers." It is called Motion Tracking.
Take a look at this breathtaking commercial and don't forget to invite your kids. Note the boy who is holding a giant gorilla's hand in the beginning of the movie, the man who is bouncing the soccer balls and the race car drivers.
And now, check out the clip of how this was made. No time? Play at least till you see the boy walking around with a box.
Why is he holding this box and why it is marked with a tape?
The box is obviously being replaced with the giant gorilla's hand (computer generated). The tape on the box allows to reconstruct the exact motion of the box relative to the camera and then make the gorilla move it's hand with exactly the same motion.
Why are there four tape marks on the box? Wouldn't one be enough?
No!
Imagine the box right in front of you, moving in your direction. One piece of tape attached right in the middle of the box. The tape may not be moving at all as the box approaches you. When you have two tapes, you will notice that the distance between them is increasing as the box is moving closer.
The math behind this requires you to use at least three tape marks to solve a system of equations and find the exact motion of the box with respect to the camera. Use of more than three marks allows to do it more precisely, minimizing any possible errors.
In order to render the gorilla as holding the boy's hand, we need to know how far away the gorilla should stand from the camera and how it should be rotated. This is defined through two parameters: R that is the 3x3 rotation matrix and T that is 3x1 translation vector. Gorilla and its computer generated hand are represented as a collection of 3D points. Each such point P has (X, Y, Z) values in the computer graphics library. To place gorilla next to the boy animators tell their rendering programs to use rotation R, translation T and some camera parameters. How do they know what R and T are? From the box!
Special effects artists are tracking the tape on the box to recover its R and T. Imagine this box in your hands. Every point P on this box (including the tape point) has 3 coordinates (X, Y, Z). Next to the boy, these coordinates are P1:
P1 = R x P + T
We don't know P1 but we know its projection on the image in each frame of the commercial. Let's call this projected point p.
P1/Z = p/f where f is known camera's focal distance
from this:
p = (f/Z ) P1 = R x P + T
We know f, p and P and want to find R and T. P is a coordinate of a point on the box where tape is attached, when this point is in your hands. p is coordinate of the same point in the image of the commercial. As p has two coordinates on the image (x, y) you get two equations for every point you use.
If you use some special rotation matrix (small angle rotational matrix), you will get a system of linear equations with 6 unknowns: 3 rotational components and 3 translational components. To solve a linear system with 6 unknowns you need at least 6 equations.
Remember we have 2 equations per point? Three points minimum but better more to account for possible imprecision in point tracking: some points being blurred on the image or box is tilted so that some points become invisible.
If you got it right then the gorilla's hand will be tightly attached to the boy's hand. If your math is wrong, then the gorilla and it's hand will be unrealistically plastered next to the boys as in some cheap old commercials. By the way, in the second video you can see similar tape marks on the wall that the soccer balls are bouncing off, and on the race car driver's helmets. In both cases, the position of these objects with respect to the video camera is being tracked in order to add more computer generated objects into the scene, map textures or render reflections.
Interestingly, exactly the same motion tracking strategies are used to reconstruct battle scenes from video for analysis and training purposes in the field of national defense, or to track patients' motion during a surgery in medicine. Now you have something to tell anyone who mentions that linear equations and matrices are boring.
There are many tricks that allow special effects artists seamlessly combine real and computer generated characters in one sequence. Matching character motion is one of them. Others include realistic texture and fur rendering and light matching as described in the following stories: The Silly, Wacky, Revealing and Useful Shadows
and The trouble with facial hair.
Navigation Bar
Math in Special Effects: Motion Tracking
Share this with your friends:
Our weekly newsletter with stories, puzzles and ideas can spice up your weekend and help present math to your family as a toy and a friend. Join 1,500+ subscribers:
Subscribe to:
Post Comments (Atom)
Wow, this is fantastic. Just what I needed for my 13 year old daughter interested in screenplay writing and movie-making.
ReplyDeleteI love this post. Very cool examples of particular interest to the current generation of students.
ReplyDeleteChris
I teach high school math and had just taught my honors precaclulus class about geometric transformation matrices. We had a lot of fun watching the videos of that commercial and discussing how matrices were used in those special effects.
ReplyDeletefrom Steve G. via email
I even have been getting a lot of helpful and informative material in your web site.
ReplyDeletegaga ball pit
Your contents are too straightforward to browse and easy to understand.
ReplyDeletecomment pirater un compte facebook
I wonder why different professionals don't take action your website overmuch m happy I got this.
ReplyDeletebubblegum casting
coach factory outlet, coach outlet store online, louis vuitton outlet, coach purses, tiffany and co, nike free, prada outlet, michael kors outlet, nike shoes, chanel handbags, kate spade handbags, louis vuitton outlet stores, gucci outlet, louis vuitton, prada handbags, louboutin, michael kors outlet, louboutin outlet, longchamp handbags, michael kors outlet, michael kors outlet, longchamp handbags, jordan shoes, tiffany and co, oakley sunglasses, burberry outlet, oakley sunglasses, christian louboutin shoes, oakley sunglasses cheap, coach outlet, michael kors outlet, air max, louis vuitton outlet, true religion jeans, louis vuitton handbags, burberry outlet, ray ban sunglasses, kate spade outlet, michael kors outlet, true religion jeans, air max, tory burch outlet, polo ralph lauren outlet, ray ban sunglasses, longchamp outlet, polo ralph lauren outlet, louboutin
ReplyDeletejimmy choo outlet, instyler, abercrombie and fitch, celine handbags, nfl jerseys, mac cosmetics, canada goose jackets, herve leger, soccer shoes, ugg boots, beats by dre, north face outlet, mcm handbags, ugg boots, ghd, soccer jerseys, vans shoes, canada goose outlet, uggs outlet, wedding dresses, babyliss pro, longchamp, ugg australia, new balance shoes, ugg pas cher, ferragamo shoes, lululemon outlet, canada goose, rolex watches, bottega veneta, canada goose, valentino shoes, marc jacobs, reebok outlet, uggs outlet, ugg boots, hollister, giuseppe zanotti, birkin bag, p90x, north face jackets, ugg, mont blanc, asics running shoes, nike roshe run, chi flat iron, moncler, canada goose uk, canada goose, insanity workout
ReplyDeleteI am quite sure they will learn lots of new stuff here than anybody else!....There is also a lot of visual symbolism that is sometimes subtle, sometimes not so subtle.. perte de poids rapide
ReplyDeletetods shoes
ReplyDeletehollister clothing
coach outlet online
soccer jerseys
valentino sale
marc jacobs
mac cosmetics
asics gel kayano
jordan 4 retro
links of london
michael kors outlet
michael kors handbags
true religion
swarovski crystal
lacoste outlet
valentino shoes
ray ban sunglasses online
louis vuitton handbags
christian louboutin
coach outlet online
karen millen dresses
marc jacobs outlet
ray ban sunglasses
polo lacoste pas cher
tiffany and co jewelry
kate spade handbags
michael kors outlet online sale
ed hardy t-shirts
tiffany and co
air max 95
GATE score is considered in various Government undertaking and private companies to recruit technical staff and engineers. Technical Graduates can fill application form for GATE examination and those who are in final year of their technical courses. GATE is Computer Based Test (CBT) and is being conducted on different days for different branches.
ReplyDeletegate exam, gate 2016 GATE 20116 notification, GATE notification, gate 2016 syllabus, gate syllabus, gate exam pattern, gate question papers, gate previous year papers, crack gate, gate tips and trick, gate application form, gate 2016 application form
jianbin1027
ReplyDeletecanada goose sale
north face outlet
louis vuitton uk
philadelphia eagles
louis vuitton outlet store
minnesota vikings
michael kors outlet online
boston celtics
hollister clothing store
moncler jackets
coach outlet online,coach purses,coach handbags,coach bags,coach handbags sale,coach handbags outlet
longchamp outlet online
wedding dresses
nhl jerseys wholesale
hollister pas cher
coach outlet store
coach outlet online
soccer jerseys,cheap soccer jerseys,cheap soccer jerseys for sale,soccer jersey,usa soccer jersey,football jerseys
coach outlet store online,coach outlet store,coach outlet
20151222 junda
ReplyDeleteoakley sunglasses
nike cortez
ugg outlet
canada goose jackets
north face outlet
coach factory outlet
uggs outlet
burberry outlet
ghd hair straighteners
nike air max
michael kors handbags
nike air max shoes
prada outlet
gucci outlet
louis vuitton
instyler max
nike roshe run women
michael kors outlet
cheap uggs boots
adidas uk
michael kors
sac longchamp
cheap ugg boots
michael kors handbags
michael kors outlet online
mont blanc pens
ray ban sunglasses
louis vuitton outlet
soccer jerseys
jordan 8s
coach factory outlet
coach outlet store online
nike uk
air jordans
coach factory outlet
adidas superstars
louis vuitton handbags
burberry outlet online
michael kors outlet
toms outlet
pink asics gel wall and dre headphones black timberland boots tiles, burberry and ralph lauren instantly instyler ionic styler faint mizuno running shoes stuck nike.dk his gucci head out ugg australia of adidas.se a true religion jeans women Apricot hilfiger outlet ... ed hardy clothing remember new balance what montblanc Mr. pandora charms cat nike roshe run said to veneta the, "Spring polo ralph lauren is louis vuitton australia the daughter salvatore ferragamo home nike fu?ballschuhe ......" has long been designer handbags over daughter roshes Every swarovski australia family's gooses age, louis vuitton and tommy hilfiger outlet heart louis vuitton can hollisterco be louis vuitton handbags a <a
ReplyDeleteThis is a wonderful post. I enjoyed the information lot. I will bookmark this page. Thanks for sharing this information.
ReplyDeletestarfall | nick jr | minecraft games | barney