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 Epicenter of an Earthquake with Python
Search
PyBay
August 13, 2017
Programming
0
510
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
740
2017 - Building Bridges: Stopping Python 2 without damages
pybay
0
520
2017 - Bringing Python 3 to LinkedIn
pybay
1
470
2017 - Python Debugging with PUDB
pybay
0
480
2017 - Opening up to Open Source
pybay
0
170
2017 - A Gentle Introduction to Text Classification with Deep Learning
pybay
2
140
2017 - Performant Asynchronous Programming at Quora
pybay
1
280
2017 - latus - a Personal Cloud Storage App written in Python
pybay
2
400
2017 - Everything You Ever Wanted to Know About Web Authentication in Python
pybay
3
410
Other Decks in Programming
See All in Programming
if constexpr文はテンプレート世界のラムダ式である
faithandbrave
3
640
使ってみよう Azure AI Document Intelligence
kosmosebi
2
290
코틀린으로 멀티플랫폼 만들기
pangmoo
0
150
AWS Application Composerで始める、 サーバーレスなデータ基盤構築 / 20240406-jawsug-hokuriku-shinkansen
kasacchiful
1
260
はてなにおける CSS Modules、及び CSS Modules に足りないもの / CSS Modules in Hatena, and CSS Modules missing parts
mizdra
7
910
Zero Waste, Radical Magic, and Italian Graft – Quarkus Efficiency Secrets
hollycummins
0
230
効率化に挑戦してみたらモバイル開発が少し快適になった話
ryunakayama
0
130
Changed Rules: Architectures with Lightweight Stores
manfredsteyer
PRO
0
240
Elm Form Validation
bkuhlmann
0
510
GraphQLサーバの構成要素を整理する #ハッカー鮨 #tsukijigraphql / graphql server technology selection
izumin5210
4
820
Git Rebase
bkuhlmann
11
1.6k
Komplexe Oberflächen mit SVG und der Web Animation API
joergneumann
0
670
Featured
See All Featured
Become a Pro
speakerdeck
PRO
11
4.5k
Music & Morning Musume
bryan
41
5.6k
A Modern Web Designer's Workflow
chriscoyier
689
190k
Six Lessons from altMBA
skipperchong
21
3k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
352
28k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
6
1.5k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
187
16k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
78
42k
Fireside Chat
paigeccino
21
2.6k
Building Adaptive Systems
keathley
31
1.9k
Fantastic passwords and where to find them - at NoRuKo
philnash
37
2.5k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
7
1k
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]