How to use the pymap3d.geocentric_radius function in pymap3d

To help you get started, we’ve selected a few pymap3d examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github scivision / pymap3d / tests / test_latitude.py View on Github external
def test_geodetic_alt_geocentric(geodetic_lat, alt_m, geocentric_lat):
    assert pm.geod2geoc(geodetic_lat, alt_m) == approx(geocentric_lat)

    r = pm.geocentric_radius(geodetic_lat)
    assert pm.geoc2geod(geocentric_lat, r) == approx(geodetic_lat)
    assert pm.geoc2geod(geocentric_lat, 1e5 + r) == approx(pm.geocentric2geodetic(geocentric_lat, 1e5 + alt_m))

    assert pm.geod2geoc(geodetic_lat, 1e5 + alt_m) == approx(pm.geodetic2geocentric(geodetic_lat, 1e5 + alt_m))
github scivision / pymap3d / tests / test_rsphere.py View on Github external
def test_geocentric_radius_badval(bad_lat):
    with pytest.raises(ValueError):
        pm.geocentric_radius(bad_lat)
github scivision / pymap3d / tests / test_rsphere.py View on Github external
def test_geocentric_radius():
    assert pm.geocentric_radius(0) == approx(ell.semimajor_axis)
    assert pm.geocentric_radius(90) == approx(ell.semiminor_axis)
    assert pm.geocentric_radius(45) == approx(6367490.0)
    assert pm.geocentric_radius(30) == approx(6372824.0)
github scivision / pymap3d / tests / test_rsphere.py View on Github external
def test_geocentric_radius():
    assert pm.geocentric_radius(0) == approx(ell.semimajor_axis)
    assert pm.geocentric_radius(90) == approx(ell.semiminor_axis)
    assert pm.geocentric_radius(45) == approx(6367490.0)
    assert pm.geocentric_radius(30) == approx(6372824.0)
github scivision / pymap3d / tests / test_rsphere.py View on Github external
def test_geocentric_radius():
    assert pm.geocentric_radius(0) == approx(ell.semimajor_axis)
    assert pm.geocentric_radius(90) == approx(ell.semiminor_axis)
    assert pm.geocentric_radius(45) == approx(6367490.0)
    assert pm.geocentric_radius(30) == approx(6372824.0)
github scivision / pymap3d / tests / test_rsphere.py View on Github external
def test_geocentric_radius():
    assert pm.geocentric_radius(0) == approx(ell.semimajor_axis)
    assert pm.geocentric_radius(90) == approx(ell.semiminor_axis)
    assert pm.geocentric_radius(45) == approx(6367490.0)
    assert pm.geocentric_radius(30) == approx(6372824.0)