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
Pythonと数学と 多面体とペーパークラフトとベルヌーイと長門屋と田宮模型と私
Search
Kimikazu Kato
October 08, 2018
1
1.6k
Pythonと数学と 多面体とペーパークラフトとベルヌーイと長門屋と田宮模型と私
2018年10月8日PyLadies Tokyo 4周年記念パーティでのLTです。
Kimikazu Kato
October 08, 2018
Tweet
Share
More Decks by Kimikazu Kato
See All by Kimikazu Kato
PyTorchの最近の動向
hamukazu
0
700
Python 3.11: What changed in math?
hamukazu
0
440
機械学習も筋肉が大事?意外と知らない数学
hamukazu
0
960
レコメンデーションシステムのキホン
hamukazu
4
880
機械学習の中身を理解する
hamukazu
28
10k
機械学習に役立つ数学
hamukazu
11
6.2k
Featured
See All Featured
Rebuilding a faster, lazier Slack
samanthasiow
79
8.7k
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
159
15k
Into the Great Unknown - MozCon
thekraken
33
1.5k
Facilitating Awesome Meetings
lara
50
6.1k
Side Projects
sachag
452
42k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
26
1.9k
The Language of Interfaces
destraynor
154
24k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
44
9.3k
Product Roadmaps are Hard
iamctodd
PRO
49
11k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
132
33k
How GitHub (no longer) Works
holman
311
140k
Transcript
Pythonͱֶͱ ଟ໘ମͱϖʔύʔΫϥϑτ ͱϕϧψʔΠͱͱాٶܕͱࢲ Ճ౻ެҰ @hamukazu 201810݄8 PyLadiesTokyo4पه೦ύʔςΟ
ࣗݾհ Ճ౻ެҰʢ͖Έ͔ͣʣ Twitter: @hamukazu • ֶΤόϯδΣϦετ • ےτϨܯ • ϏʔϧΫζ
࠷ۙຊग़ͨ͠Αʂ ങͬͯͶ— http://bit.ly/mlessence
• ਖ਼ेೋ໘ମͷݟऔΓਤΛඳ͖ͳ͍͞ • ਖ਼ेೋ໘ମͷɺลɺ໘ͷΛͦΕͧΕ͑ͳ͍͞
ղ ུ
͔֬ΊΔํ๏ ࣮Λ࡞Δ
ଟ໘ମϖʔύʔΫϥϑτ • 2017ʹΓ࢝ΊͨʢϒϩάͰൃදʣ • ࡞ϓϩάϥϜΛΦʔϓϯιʔεͰެ։ • ࠷ॳਖ਼ଟ໘ମ • 2018PyConJP SprintsͰਖ਼ଟ໘ମʢ४ਖ਼ଟ໘ମʣ
https://github.com/hamukazu/craft_regpolyhed https://github.com/hamukazu/craft_truncated
ྫ ਖ਼ेೋ໘ମ ਖ਼ೋे໘ମ
ਖ਼ೋे໘ମ ྫ ʢ2ͭ߹Θͤͯ1ͭͷཱମʣ
Ͳ͏ͬͯ࡞Δ͔ • ݴޠͪΖΜPython • Reportlabͱ͍͏ϥΠϒϥϦ • ͋ͱֶతܭࢉʢϕΫτϧܭࢉͱճసߦྻʣ • ࣗಈඳը͢ΔΞϧΰϦζϜΛ࡞ͬͨͷͰͳ͘ɺҰͭҰͭ ઢΛҾ͘ϓϩάϥϜΛॻ͍ͨ
ReportLab PythonͰPDFϑΝΠϧΛฤूͰ͖ΔϥΠϒϥϦ اۀ͕͍ͬͯΔΦʔϓϯιʔε ReportLabϥΠϒϥϦ໊͔ͭاۀ໊
ֶతܭࢉ ✓ cos ✓ sin ✓ sin ✓ cos ✓
◆ ✓ x y ◆ = ✓ x cos ✓ y sin ✓ x sin ✓ + y cos ✓ ◆ (x,y)ΛݪΛத৺ʹθճసͤͨ͞ΛٻΊΔ ඞཁͳܭࢉ͜ΕͱɺϕΫτϧجຊܭࢉʢɾࠩɾεΧϥʔഒʣ͚ͩ
ਖ਼ޒ֯ܗͷඳ͖ํ 108° 72° A1 A2 A3 − → OA3 =
− → OA2 + − − − → A2A3 = − → OA2 + cos 72◦ − sin 72◦ sin 72◦ cos 72◦ − − − → A1A2 ͜ΕΛ܁ΓฦͤΑ͍
࣍ʹఔ
ඞཁͳͷ φ-022 ʢಛްޱʣ ϓϥε͞Έ ϑΟοτΧʔϒ ϓϨϛΞϜνλϯ ʢϕϧψʔΠۂઢʣ λϛϠ ΫϥϑτϘϯυ
ϕϧψʔΠۂઢ Ωλʔʂ
ఆٛʢϕϧψʔΠۂઢʣ ฏ໘ͷۃ࠲ඪදࣔɹɹɹʹରͯ͠ Ͱද͞ΕΔۂઢΛϕϧψʔΠۂઢͱݺͿ ఆཧ ݪ͔Βग़ΔઢͱϕϧψʔΠۂઢͷͳ֯͢ҰఆͰ͋Δ r = aebθ ূ໌ ಡऀͷԋशͱ͢Δ
(r, θ)
࡞Γํͷίπ • ંΓఆنΛͬͯંΔ • ͘Β͍ΈཱͯͯͨΒҰணࡎΛס͔ͯ͠ݻఆ͢Δ • ͷΓ͠Ζ͕ͳ͍໘͕͋ΔͷͰͦΕΛ࠷ޙʹด͡Δ
TODO • ϦϑΝΫλϦϯάͯ͠ύοέʔδԽ • pip install͍ͨ͠ΑͶʁ • ࡞ΓํͷίπͷυΩϡϝϯτӳ༁ͯ͠ެ։