Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
2017 - Gabrielle Simard-Moore - Calculating the...
Search
PyBay
August 13, 2017
Programming
0
580
2017 - Gabrielle Simard-Moore - Calculating the Epicenter of an Earthquake with Python
PyBay
August 13, 2017
Tweet
Share
More Decks by PyBay
See All by PyBay
2017 - The Packaging Gradient
pybay
2
830
2017 - Building Bridges: Stopping Python 2 without damages
pybay
0
590
2017 - Bringing Python 3 to LinkedIn
pybay
1
510
2017 - Python Debugging with PUDB
pybay
0
580
2017 - Opening up to Open Source
pybay
0
210
2017 - A Gentle Introduction to Text Classification with Deep Learning
pybay
2
160
2017 - Performant Asynchronous Programming at Quora
pybay
1
330
2017 - latus - a Personal Cloud Storage App written in Python
pybay
2
450
2017 - Everything You Ever Wanted to Know About Web Authentication in Python
pybay
3
510
Other Decks in Programming
See All in Programming
ピクシブ百科事典のWebフロントエンドパフォーマンス改善
higara
0
230
Going Staff - Keynote edition
pragtob
0
440
Why Spring Matters to Jakarta EE - and Vice Versa
ivargrimstad
0
620
色々なIaCツールを実際に触って比較してみる
iriikeita
0
140
カラム追加で増えるActiveRecordのメモリサイズ イメージできますか?
asayamakk
3
1.1k
Server Driven Compose With Firebase
skydoves
0
350
僕がつくった48個のWebサービス達
yusukebe
17
16k
#pixiv小説画像メーカー はこうしてできた / The Making of the pixiv Novel Image Maker
roiban
0
230
Re:proS_案内資料
rect
0
260
Tuning GraphQL on Rails
pyama86
2
790
Dev ContainersとGitHub Codespacesの素敵な関係
ymd65536
1
120
Vertical Architectures for Scalable Angular Applications
manfredsteyer
PRO
0
290
Featured
See All Featured
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
28
9k
Bash Introduction
62gerente
608
210k
Embracing the Ebb and Flow
colly
84
4.4k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
504
140k
Six Lessons from altMBA
skipperchong
26
3.4k
For a Future-Friendly Web
brad_frost
174
9.4k
It's Worth the Effort
3n
183
27k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
47
5k
Agile that works and the tools we love
rasmusluckow
327
21k
Speed Design
sergeychernyshev
24
560
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
5
140
Intergalactic Javascript Robots from Outer Space
tanoku
268
27k
Transcript
Calculating the Epicenter of an Earthquake with Python Gabrielle Simard-Moore
From Seismograph to Epicenter • 3 Seismic Stations • P-
and S-wave arrival time difference • Distance to Earthquake • Draw 3 circles • Intersection = Epicenter
Seismic Data
Getting the Distance and Magnitude
None
Tech Stack • Python • Numpy • Datetime • Math
• Flask • Ajax/Jquery • Google Maps JS API
Assumptions • Wave velocity in CA crustal rocks P-wave velocity
~ 6.34 km/s (varies by +/- 2+) S-wave velocity ~ 3.67 km/s (varies by +/- 1+) • Homogeneity of materials (very unrealistic for a heterogeneous lithosphere)
3 stations
Many steps
Degrees to Radians
Geodetic (latitude, longitude) to ECEF X, Y, Z coordinates to
Numpy array ECEF = “Earth centered, Earth fixed”
Vector Normalization
Final Trilateration point: Epicenter
ECEF XYZ to Lat, Lon
Front end
Thanks! github.com/gsimore/earthquakes
[email protected]