Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Java関数に相当するものは何ですか
Double EndLat; Double StartLat; Math.toRadians(EndLat - StartLat);
目的-cで?
#include <math.h> (EndLat - StartLat) * M_PI / 180.0;
頻繁に使用する場合は、これを関数に入れたいと思うかもしれません
まあ Math.toRadians(a) は角度 a からラジアンを計算するようです。
十分な基本的な数学のテキストによると、同等のコードは次のようになります。
結果 = a * 3.14159265358979323846 / 180.0