New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

adds Baal Hatanya zmanim #127

Merged
merged 4 commits into from Jun 19, 2018

Conversation

Projects
None yet
2 participants
@yparitcher
Contributor

yparitcher commented Jun 4, 2018

adds methods to calculate zmanim per most chabad rabbonim based on the Baal Hatanya. the computed zmanim are like https://www.chabad.org/calendar/zmanim_cdo/aid/143790/jewish/Zmanim-Halachic-Times.htm

the sunrise and sunset methods were added as private methods, as they are not published in calendars and are only used to calculate the other zmanim

* there is at least one day where the sun does not rise, and one where it does not set, a null will be
* returned. See detailed explanation on top of the {@link AstronomicalCalendar} documentation.
*/
public Date getChatzosBaalHatanya() {

This comment has been minimized.

@KosherJava

KosherJava Jun 4, 2018

Owner

@yparitcher
This method is not needed. Since the sunrise and sunset offset are identical, chatzos will be at the exact same time as the regular chatzos method.

This comment has been minimized.

@yparitcher

yparitcher Jun 4, 2018

Contributor

i originaly thought the same, however when i tested it, the chatzos times are between 200 ms and one second apart depending on location, date, and which calculator is used. therefore i added it for complete acuracy, although you are right that most users will never tell the difference.

This comment has been minimized.

@KosherJava

KosherJava Jun 18, 2018

Owner

@yparitcher the minor differences for getChatzosBaalHatanya is due to rounding and are really irrelevant. They will only confuse. Please also update the minor conflict (due to a recent change that I introduced - sorry).
Thanks

@@ -27,6 +27,7 @@ The KosherJava Zmanim API has benn ported to:
* JavaScript / TypeScript - https://github.com/BehindTheMath/KosherZmanim
* Ruby - https://github.com/pinnymz/ruby-zmanim
* Scala - https://github.com/nafg/jewish-date
* C - https://github.com/yparitcher/libzmanim

This comment has been minimized.

@KosherJava

KosherJava Jun 18, 2018

Owner

@yparitcher very cool and thanks. I will hopefully merge this later.

yparitcher added some commits Jun 19, 2018

@yparitcher

This comment has been minimized.

Contributor

yparitcher commented Jun 19, 2018

fixed

@KosherJava

Thank you @yparitcher for this work that will be appreciated by many users. A special thanks for porting this to C as well.

@KosherJava KosherJava merged commit fb1d64c into KosherJava:master Jun 19, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment