MenoData / Time4J

Advanced date, time and interval library for Java with sun/moon-astronomy and calendars like Chinese, Coptic, Ethiopian, French Republican, Hebrew, Hijri, Historic Christian, Indian National, Japanese, Julian, Korean, Minguo, Persian, Thai, Vietnamese
GNU Lesser General Public License v2.1
424 stars 62 forks source link

Hijra conversion not correct #501

Closed rizgan closed 8 years ago

rizgan commented 8 years ago

Hi,

10 Dhul-Hijjah 1462 according to http://www.al-habib.info/islamic-calendar/ummulqura/islamic-calendar-ummulqura-2040-ce.htm

will be in 14 December 2040 but not in 15 December 2040 according to Time4J.

Maybe I made wrong conversion?

MenoData commented 8 years ago

Thank you very much for your feedback. Well, there are different sources, see here:

The website of van Gent confirms your observation given on the website al-habib.info, namely AH-1462-12-10 = 2040-12-14, but:

The website of van Gent seems to use an older version of original data. And the only real authoritative source for umalqura calendar is the KACST in Saudi-Arabia. Its published calendar conversion tool says:

umalqura_1462-12-10

Finally, I have also added an extra test for the date in question including a comparison of Time4J and Java-8 (which contains a built-in umalqura calendar). Both Time4J and Java-8 are in close agreement, see also referencing commit for this issue. As far as I know, Oracla had got the umalqura data directly from the KACST (I remember vaguely such a message from Roger Riggs - Oracle, one of the project leaders of JSR-310 but cannot say now where to find this mail - probably somewhere on the threeten mailing list).

Conclusion: The KACST sometimes seems to change the underlying astronomical rules for conversion so we can never be too sure if dates so far in the future will still be correct. And the KACST has already changed the rules in the past several times, see also the website of van Gent.

rizgan commented 8 years ago

Hello,

Thank you very much for your job!

I have made a Yezidi calendar http://www.yezidicalendar.com/ using you great framework. If you are interested in it and want to add also yezidi holy dayes in Time4J I will be very glad to send you source codes.

Best regards, Rizgan

2016-05-07 22:57 GMT+03:00 Meno Hochschild notifications@github.com:

Thank you very much for your feedback. Well, there are different sources, see here:

The website of van Gent https://www.staff.science.uu.nl/%7Egent0113/islam/ummalqura.htm confirms your observation given on the website al-habib.info, namely AH-1462-12-10 = 2040-12-14, but:

The website of van Gent seems to use an older version of original data. And the only real authoritative source for umalqura calendar is the KACST in Saudi-Arabia. Its published calendar conversion tool says:

[image: umalqura_1462-12-10] https://cloud.githubusercontent.com/assets/3025695/15094234/4c28762a-149e-11e6-9bb7-c973710ae4f5.png

Finally, I have also added an extra test for the date in question including a comparison of Time4J and Java-8 (which contains a built-in umalqura calendar). Both Time4J and Java-8 are in close agreement, see also referencing commit for this issue.

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub https://github.com/MenoData/Time4J/issues/501#issuecomment-217665299

Здравствуйте,

С уважением,

MenoData commented 8 years ago

Great to hear about Yesidi calendar. I would be graceful to look at your work and will take into consideration to adopt it in Time4J. Maybe you can also give some web references in English (sorry, my language skills are limited to some European languages only).

MenoData commented 8 years ago

Have forgotten to say how you can contribute here. One good possibility is to open a pull request. Or if not possible otherwise then send the source code of your Yezidi calendar to mhochschild@gmx.de About copyright, we would share LGPL-licence for this calendar (you as primary author and me as co-author for any kind of code improvements and refactoring).

About size requirements and location of this calendar: I am not quite sure if the standard calendar package is the right place. Keep in mind that many more calendars will be implemented in the future by Time4J/A, and Time4A is already big. The standard package net.time4j.calendar is rather intended for calendars handled/implemented by ICU4J and Java-8. We could think about a package net.time4j.calendar.extra (in calendar- or in misc-module). Actually I am thinking of a new major release of Time4A to set up a modular structure again so mobile phone users can themselves decide which (calendar) features they want to embed in their apps. However, all this is not set in stone yet and subject to discussions and evaluation.

Anyway, I am now closing this issue because the original question related to umalqura calendar has already been answered. About Yezidi calendar feel free to open a pull request or a new issue.