jd_to_ordinal(jd, sg=GREGORIAN)
public
Convert a Julian Day Number to an Ordinal Date.
jd is the Julian Day Number to
convert. sg specifies the Day of Calendar Reform.
Returns the corresponding Ordinal Date as [year,
day_of_year]
# File lib/date.rb, line 385
def self.jd_to_ordinal(jd, sg=GREGORIAN)
y = jd_to_civil(jd, sg)[0]
doy = jd - civil_to_jd(y - 1, 12, 31, fix_style(jd, sg))
return y, doy
end