Skip to content

Instantly share code, notes, and snippets.

View murphym18's full-sized avatar

Michael Murphy murphym18

  • University of Notre Dame in Indiana
  • San Francisco-Oakland-Berkeley, CA MSA
View GitHub Profile
@murphym18
murphym18 / geoid.py
Created March 22, 2021 01:19 — forked from pyRobShrk/geoid.py
Python classes to calculate geoid height in meters NAVD 88 (Geoid 12b) and EGM 96
import numpy as np
from scipy.interpolate import RectBivariateSpline as Spline
import pygeodesy as geo
from pygeodesy.ellipsoidalVincenty import LatLon
class Geoid12B(): #NAD 83 Ellipsoid
# https://www.ngs.noaa.gov/GEOID/GEOID12B/GEOID12B_CONUS.shtml
# Download a Geoid Grid in little endian binary format ('g2012bu5.bin')
def __init__(self, leBinFile):
glamn, glomn, dla, dlo = np.fromfile(leBinFile,'<f8',4)
#! /usr/bin/env bash
sudo apt update
sudo apt upgrade --yes
sudo apt-get install --yes python-pip python-dev git
pip install dronekit==2.9.1 dronekit-sitl==3.2.0
cd ~/Desktop/
git clone http://github.com/dronekit/dronekit-python.git
@murphym18
murphym18 / special196.java
Created July 18, 2017 04:14
special196 created by murphym18 - https://repl.it/J62R/6
import java.math.BigDecimal;
public class Main{
public static void main(String[] args) {
BigDecimal a = new BigDecimal(89);
find(a);
}
public static void find(BigDecimal f) {
while(!checkNumber(f)) {
BigDecimal r = getReverse(f);