黒木玄 Gen Kuroki
- いいね数 389,756/311,170
- フォロー 995 フォロワー 14,556 ツイート 293,980
- 現在地 (^-^)/
- Web https://genkuroki.github.io/documents/
- 自己紹介 私については https://twilog.org/genkuroki と https://genkuroki.github.io と https://github.com/genkuroki と https://github.com/genkuroki/public を見て下さい。
2021年07月26日(月)

コンピュータ将棋の勉強は、PyCon mini Hiroshima 2018で48さんの講演を聴いて、その後もいろいろおしえていただいて、そのうちやろうと思っていて何年も経っていたのでした。しかし今年は少しはちゃんとやれている気がします。そのときに48さんに
タグ:
posted at 00:05:51

#超算数 かけ算順序でバツを付ける行為には100年以上の歴史があります。これに矛盾するかけ算順序指導の由来の推測は全部イーカゲンなデマ扱いで問題ありません。
以下のリンク先を見ればわかるようにバツを付ける側自身が逆順だと誤りになると信じている。現在も同様です。 twitter.com/genkuroki/stat...
タグ: 超算数
posted at 00:07:21



①小学2年生がまだ小さくてとてもかわいいことを知る。
②教えている先生もかわいいと思っているんだろうなと想像する。
③その先生が「かけ算順序でバツをつけろ」と指導を受けたりする。
④その先生が嫌だなと感じながらその圧力に負けてかけ算順序でバツを付けるときの気持ちを想像する。
地獄!
タグ:
posted at 00:26:53

非公開
タグ:
posted at xx:xx:xx


元となっているツイートはいろいろ突っ込みたくなりますね。
そもそも時速の単位は、km でなくて、km/h 何じゃないのとか。 twitter.com/genkuroki/stat...
タグ:
posted at 00:43:21

非公開
タグ:
posted at xx:xx:xx

@kado_judo0312 using Plots.PlotMeasuresとしておいて
plot!(right_margin=5mm)のようにしたらどうですか?
タグ:
posted at 03:20:44


非公開
タグ:
posted at xx:xx:xx

@kado_judo0312 @physicsturtle #Julia言語 「xtick, ytick, xlabel, ylabelの表示のためのマージンがうまく調節されない」という問題はPlots.jlがずっと抱えている解決困難なバグです。
github.com/JuliaPlots/Plo...
や
github.com/JuliaPlots/Plo...
を見て下さい。
解決してくれる人が出て来れば大ヒーローになれる。
タグ: Julia言語
posted at 04:47:16

#Julia言語 【「でも結局C++とかFortranで書いた方が速いのでは?」という疑念】を持つ理由が不明
medium.com/codex/is-julia...
要約:事前の計画では、Fortranで書かれた気候モデルをJuliaで書き直すときに、3倍の速度低下を許容することにしていた。しかし、実際にはJuliaによって3倍速くなった。 twitter.com/hysterect/stat... pic.twitter.com/fcKcEvy7mP
タグ: Julia言語
posted at 05:02:48



#Julia言語 コードの自動生成が数値計算で果たす役割に関する専門家による入門的な解説動画へのリンクが、以下のリンク先にあります。
講演者のSteven G. JohnsonさんのMITでの講義もわかりやすく面白いです。宿題の例↓
nbviewer.jupyter.org/github/steveng...
↑ここでもFortranの5~6倍の計算速度が実現! twitter.com/genkuroki/stat...
タグ: Julia言語
posted at 05:19:55


私の出身高校では、男子全員が鳥海山の5合目まで早朝にバスで輸送されておろされて「高校校舎まで戻って来る」という行事があった。女子は10km先からスタートする。(うまいルール!)
高校1年のときに、女子組最後尾の高3の2人のお姉さんに追いついたら、「おかし、食べる?」と言われた😊 twitter.com/geoign/status/...
タグ:
posted at 05:36:28

Buitengebieden @buitengebieden
Tail controlled.. 😅 pic.twitter.com/rBMpnSSWmz
タグ:
posted at 06:41:56

非公開
タグ:
posted at xx:xx:xx

KURODA KENJI (켄지 쿠로다 @KURODA_KENJI
@sirius06135639 期末テストの問題用紙ですよ。この間違いは、よくあることなので目くじらを立てるつもりはなく、次に学校に行ったときに指摘する程度にします。
タグ:
posted at 06:43:18

#julialang
気になったので,スターリングの公式の比較(グラフ)
(ここ数日twitterで知ったコードの盛り合わせになってるww) pic.twitter.com/5Bm84uyraF
タグ: julialang
posted at 06:45:29

KURODA KENJI (켄지 쿠로다 @KURODA_KENJI
朝起きたら、ぷちバズっていて驚いた。
リツイートで聖画像がそもそも禁止されていないという指摘があったのですが、禁止されているという立場からの回答であるという前提で上記の回答案となります。
タグ:
posted at 06:57:42

KURODA KENJI (켄지 쿠로다 @KURODA_KENJI
なおムハンマドの肖像をめぐる風刺画問題以降の現象については拙編著『大学生・社会人のためのイスラーム講座』の「コラム8 イスラームの視覚芸術:ムハンマドの肖像を描くこと」においてクリスチャン・グリューバーの議論に沿いつつ解説しております(www.nakanishiya.co.jp/book/b383091.h...)。
タグ:
posted at 06:57:43


Masahiro Ono 小野 昌弘 @masahirono
英国の博打:免疫が左右するデルタ株流行のゆくえ(小野昌弘)
ワクチン接種が日本と比べてはるかに高い英国では、ワクチンによる免疫のデルタ株に対する有効性が夏の流行の結果を左右する。この背景を解説する。
#Yahooニュース
news.yahoo.co.jp/byline/onomasa...
タグ: Yahooニュース
posted at 08:26:02

Learning Epidemic Models That Extrapolate, AI4Pandemics www.juliabloggers.com/learning-epide... #juliabloggers
タグ: juliabloggers
posted at 08:45:02


Very high quality intro to Bayesian stats in #JuliaLang, w/ code
storopoli.io/Bayesian-Julia/
#Bravo #Respect twitter.com/JoseStoropoli/...
posted at 09:33:17

@genkuroki 下り坂を、走らされるのは、いくら高校生でも膝おかしくシソ…おつかれでした!
長距離走当日、「鳥海山、噴火しないカナ…」と、マジ泣きそうな思いでオモッたコ、いそう…
…自分は五合目から山頂まで飛ばせてホシイ!
実際には、地を這う蛇のようであっても…
学校には帰らない?!(笑)
タグ:
posted at 10:06:42

Julia set
色の付け方を変えてみました
#切り絵
#幾何学 pic.twitter.com/ZS7snRoorO
posted at 10:21:47

資産の分布は指数分布っぽい形になりがち。
総額一定の資産をある意味でランダムに分配すると指数分布が確率的に生じることが統計力学の教科書に書いてある。コンピュータで数値的に確認するのも容易。
貯蓄額が純粋に運で決まっていれば貯蓄額の分布はひどく不平等な指数分布っぽい形になるだろう。 twitter.com/magic_mackee/s...
タグ:
posted at 10:41:23

ストックではなくフロー(年間所得)の分布はなにがしかの政策が効いているような分布になっている。 twitter.com/genkuroki/stat...
タグ:
posted at 10:43:57


ランダムに1億円を1万人に配ったときの分布のプロット。
非常に不平等な指数分布に(近似的に)従う。
数学的註:「ランダムに配る」の意味は単体上の一様分布に従うという意味。ただしその単体は「x_i達がすべて0以上でかつx_1+…+x_n=n」という条件で定義されたものとする。
github.com/genkuroki/publ... pic.twitter.com/PCLRUfAX3a
タグ:
posted at 13:03:31

#Julia言語 ゼロアロケーションで単体上の一様乱数を作ることは一応非自明な問題で、上のツイートはその解答例ともみなされる。
ソースコード↓
github.com/genkuroki/publ...
タグ: Julia言語
posted at 13:07:45

今週28日29日に予定をされていた東北大学理学部のオープンキャンパスですが、コロナ禍の状況を鑑みて、対面式の企画は中止となり、オンラインイベントのみの開催となりました。28日29日の9時より模擬講義を配信予定です。視聴情報も含めて詳細は後で宣伝させて頂きます。
www.sci.tohoku.ac.jp/oc/
タグ:
posted at 13:10:51

物理学科からは、市川温子先生の「粒子と反粒子の違い」、今井正幸先生の「生きてるように動く物質」、関口仁子先生の「原子核物理の三体問題」の模擬講義配信を予定しております。
タグ:
posted at 13:14:27

#数楽 「x_iはすべて0以上、相加平均は1以下」という条件で一様乱数を生成すると指数分布に近似的に従う。c > -γ = -0.5772… のとき、さらに「相乗平均はexp(c)以上(⇔対数の加法平均がc以上)」という条件を追加するとガンマ分布が出て来る。 twitter.com/genkuroki/stat...
タグ: 数楽
posted at 13:14:43

@f_sei さらに進んで、これをルールだと思い込み
suugaku.at.webry.info/201102/article...
4人に5枚ずつ、で4×5だと20人になるから理解していない
などという馬鹿教師もいます。
タグ:
posted at 13:32:18

はっきり言っちゃうけど、「#Julia言語 よりFortranの方が速いのは当然である」みたいに思っている人達は全員丸ごと周回遅れ。
実際、Fortranコミュニティで
fortran-lang.discourse.group/t/simple-summa...
Simple summation 8x slower than in Julia
discourse.julialang.org/t/julia-gets-m...
のようなことが話題になっています。
タグ:
posted at 13:39:13


「かけ算には唯一に決まる正しい順序というものがある」という馬鹿げた教義を忘れたら楽になれるのに。😆 twitter.com/hocya3nebk/sta...
タグ:
posted at 13:56:36

あと、行列の積の計算について「MKL最強!」のように思っていると、Juliaに負けちゃう可能性が高くなります。
discourse.julialang.org/t/intel-c-c-co...
Multithreaded Julia matrix multiply (specifically, Octavian.jl github.com/JuliaLinearAlg...) “dominates” MKL < 100x100, and hangs on in performance
タグ:
posted at 13:58:44

@MMM140806 小学校でバカな事を教えられて(「単位のサンドイッチ」とか)、それを上書き訂正できずにその後躓いてしまう(あるいは躓いていることにも気付けない)犠牲者が少なくないようです。
タグ:
posted at 14:16:31

7月26日(月)の東京都における新規感染者報告数は1429人でした。週平均の対前週比は141%です。先週の月曜日は727人だったので先週同日比で1.97倍になりました。10万人あたりの感染者数の週累計は78.13人です。また、本日のL452R変異株の陽性件数は940件で、陽性率は52%でした。 pic.twitter.com/PlxOVIO2sp
タグ:
posted at 16:50:26

正しく教育を受けていれば、順序がどうあれkm/時と時間を掛け合わせると単位はkmだけ残るというのを理解しているはず。
単位の厳密な取り扱いは高校物理ぐらいまで行けば徹底的に叩き込まれるんだが、物理を未履修or理解しないまま教師になった人間が小学校の算数理科でデタラメ教えて以下悪循環。 twitter.com/genkuroki/stat...
タグ:
posted at 17:12:13

上で説明したように、高次元単体上の一様分布の射影から近似的に指数分布が得られ、資産分布の話への応用がある。
高次元球面上の一様分布の射影から近似的に正規分布が得られ(添付画像)、気体分子の速度の分布(Maxwell–Boltzmann分布)への応用がある。
github.com/genkuroki/publ... pic.twitter.com/uSUfBAQaY0
タグ:
posted at 17:59:13

「高齢者さえワクチンを接種すれば、若い人は接種しなくてもいいんじゃない?」とよく聞かれます。
ですが、
・ワクチンの効果は100%ではないため、感染が拡大すれば接種済みの高齢者にも飛び火します。
・若い人も重症化する事は稀にあります。国内でも基礎疾患がない20代や30代の死亡例もあります。 pic.twitter.com/7cC90JNKWf
タグ:
posted at 18:01:45

❌「コンパイラの性能的にJuliaはCやFortranより速い」という意味なら、明らかに言い過ぎで誤り。「同じ程度」と言っておけば安全。
しかし、Fortranで書かれた実際に使われている基本特殊函数ライブラリよりも速いコードを #Julia言語 で書くことがMITの講義の宿題の答えになっているのは事実。 twitter.com/hide5stm/statu...
タグ: Julia言語
posted at 18:22:16

Fortranで書かれた(統計でよく使われる)基本特殊函数ライブラリがFortranで書かれているという理由で速いだろうと思っていても、#Julia言語 を知っていれば、それよりも速いコードを書くことはMITでの講義の宿題レベルの問題になってしまうということ。
nbviewer.jupyter.org/github/steveng...
タグ: Julia言語
posted at 18:22:17

MITの講義の宿題の答え nbviewer.jupyter.org/github/steveng... のコードは古いので、現在の仕様が安定しているv1.0以上の #Julia言語 で動きません。
動くようにしたものが以下のリンク先のIn[2]にあります。
↓
nbviewer.jupyter.org/gist/genkuroki...
マクロ(コードの自動生成)を使っています。
タグ: Julia言語
posted at 18:38:11

続き。そのIn[2]のコードを他言語に移植する場合には、コードを自動生成しているマクロを使っている部分が問題になります。
マクロを使わないように書き直すこともできますが、それなりの手間が必要になります。人間にとって読み難いコードで良いなら @ macroexpand すればよいのですが。
タグ:
posted at 18:42:35



7h × 4km/h = 4km/h × 7h = 28km
自分が知っている交換則はこれ。
次元が変わる点はまったく理解不能。助数詞と単位の違いはさておき、サンドイッチが原因だとすれば、これが実害の一例ですね。 twitter.com/genkuroki/stat...
タグ:
posted at 19:32:17

※これは本当の患者の話ではありません。稀に若い人でも重症化する事実をベースに作った仮想の会話です。日本国内でも、20代や30代の方のICU入院、そして死亡した症例もあります。そのため、若い方にもコロナワクチンを強く推薦します。
タグ:
posted at 19:56:20

#Julia言語 スターリングの公式のプロットを私もやってみた。
log n! ≈ n log n が最も粗い近似なのだが、10²³のオーダーでは十分に実用的な近似になる。
log n! ≈ n log n - n + (1/2)log n + log√(2π) は実用的には「ほぼ等号」扱いしてよい近似とみなせる場合が多い。 twitter.com/iitenki_morute... pic.twitter.com/yOtfC4vqCD
タグ: Julia言語
posted at 21:26:25

@NicholasRennick 昨年20代の男性が呼吸器付けるほど重症化した場に立ち会いました。
最初接触時は風邪程度の症状だったのに、僅か1時間半程度で意識朦朧状態でした😱
本気でコロナヤバすぎでしょと感じましたね。
タグ:
posted at 21:53:34

Planet Earth in #JuliaLang, built with @MakiePlots.
Part of BeautifulMakie: github.com/lazarusA/Beaut... pic.twitter.com/OqQb1jVN6X
タグ: JuliaLang
posted at 22:00:00

Hi folks - the Introduction to Bayesian Data Analysis is delayed due to technical issues. We will advise accordingly on future updates.
In the meantime, you can check out the workshop repository here: github.com/kskyten/BayesW...
タグ:
posted at 23:35:14

Hi folks - After some technical difficulties, the Bayesian Data Analysis Workshop is now under way.
www.youtube.com/watch?v=W_Exvi...
タグ:
posted at 23:36:45