[iPhone] julian > Gregorian day
+ (float)julianToDayCalendar:(float)Julian
{
float a, b, c, d, e, m, day;
a = Julian + 32044;
b = floor(((4 * a) + 3) / 146097);
c = a - floor((146097 * b) / 4);
d = floor(((4 * c) + 3) / 1461);
e = c - floor((1461 * d) / 4);
m = floor(((5 * e) + 2) / 153);
day = e - floor(((153 * m) + 2) / 5) +1;
return day;
}
댓글
댓글 쓰기