O'Reilly logo

jQuery and JavaScript Phrasebook by Brad Dayley

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Applying Power Functions

Math.exp(4); //returns 54.59815 Math.pow(2,16); //returns 65536 Math.sqrt(25); //returns 5

The Math object provides several power functions that allow you to apply exponential and root operations on numbers. Table 2.4 lists the trig methods to apply Euler’s exponential, power, and square root functions. You can pass in the values as numbers or numerical strings.

Image

Table 2.4 Match Object Trigonometric Methods

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required