def jcal2jd(year, month, day):
 year = int(year)
 month = int(month)
 day = int(day)
 jd = (367 * year)
 x = ipart(((month - 9) / 7.0))
 jd -= ipart(((7 * ((year + 5001) + x)) / 4.0))
 jd += ipart(((275 * month) / 9.0))
 jd += day
 jd += (1729777 - 2400000.5)
 jd -= 0.5
 return (MJD_0, jd)

def jcal2jd ( year , month , day ) : year = int ( year ) month = int ( month ) day = int ( day ) jd = ( 367 * year ) x = ipart ( ( ( month - 9 ) / 7.0 ) ) jd -= ipart ( ( ( 7 * ( ( year + 5001 ) + x ) ) / 4.0 ) ) jd += ipart ( ( ( 275 * month ) / 9.0 ) ) jd += day jd += ( 1729777 - 2400000.5 ) jd -= 0.5 return ( MJD_0 , jd )
julian calendar date to julian date .