Andrew Garfield portrays Peter Parker in a scene from "The Amazing Spider-Man." (Jaimie Trueblood/Sony Pictures/AP)

Note: This post contains extremely minor spoilers about the plot of “The Amazing Spider-Man.” That’s your warning.

In addition to adorable scenes between Peter Parker and Gwen Stacy and lots of web slinging, “The Amazing Spider-Man,” which come outs next week, revolves a lot around the Oscorp lab and, subsequently, science.

One of those science plot points is a math formula called the Decay Rate Algorithm. Thanks to The Mary Sue, we know that real life scientist, University of Minnesota physics professor Jim Kakalios, served as a consultant on the film and helped come up with the realistic looking formula.

The good professor, who wrote the book “The Physics of Superheroes,” has made a video to explain the real science that went into the fake algorithm. Watch it below.