Skip to content

Commit

Permalink
Merge pull request #75 from c42f/earth-gravity
Browse files Browse the repository at this point in the history
Add acceleration due to gravity and pounds force units
  • Loading branch information
ajkeller34 authored Apr 12, 2017
2 parents 00fe499 + f20d8e0 commit 2916ba2
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/pkgdefaults.jl
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ const ɛ0 = 1/(μ0*c^2) # exact, electric constant
const ϵ0 = ɛ0
const Z0 = μ0*c # exact, impedance of free space
const G = 6.674_08e-11*m^3/kg/s^2 # (31) gravitational constant
const gn = 9.80665*m/s^2 # exact, standard acceleration of gravity
const h = 6.626_070_040e-34*J*s # (81) Planck constant
const ħ = h/2π # hbar
const Φ0 = h/(2q) # Superconducting magnetic flux quantum
Expand All @@ -129,6 +130,10 @@ const R = 8.314_459_8*J/(mol*K) # (48) molar gass constant
const k = 1.380_648_52e-23*(J/K) # (79) Boltzmann constant
const σ = π^2*k^4/(60*ħ^3*c^2) # Stefan-Boltzmann constant

# Acceleration
@unit ge "ge" EarthGravity gn false


#########
# Shared Imperial / US customary units

Expand All @@ -153,6 +158,9 @@ Unitful.offsettemp(::Unitful.Unit{:Fahrenheit}) = 45967//100
@unit dr "dr" Dram oz//16 false
@unit gr "gr" Grain (32//875)*dr false

# Force
@unit lbf "lbf" PoundsForce 1lb*ge false

#########

# `using Unitful.DefaultSymbols` will bring the following into the calling namespace:
Expand Down

0 comments on commit 2916ba2

Please sign in to comment.