3.0.4 • Published 10 years ago

esg v3.0.4

Weekly downloads
1
License
MIT
Repository
github
Last release
10 years ago

npm.io

ESG

ESG-short for Equatorial Surface Gravity-is a small functionally-programmed library which returns the surface gravity of a spherical body as derived from the Newton's gravitational constant.

Build Status

Installation

npm install esg

Usage

var esg = require('esg').ESG;

// Surface gravity in m/s.
esg.gravity(5.972E+24, 6.371E+6) // 9.91810989409835

// Relative surface gravity to Earth's, expressed as a ratio.
esg.relative(5.972E+24, 6.371E+6); // 1

// Escape velocity in m/s.
esg.escape(5.972E+24, 6.371E+6); // 11241.732796619975

// Orbital velocity in m/s.
esg.orbit(5.972E+24, 6.371E+6); // 7949.105492777197

Testing

npm test

Contributing

Pull requests welcome.

License

The code is under the MIT license.

3.0.4

10 years ago

3.0.3

10 years ago

2.0.3

10 years ago

2.0.2

10 years ago

2.0.1

10 years ago

1.0.1

10 years ago

1.0.0

10 years ago