Skip to content

Commit 0ed8d22

Browse files
authored
Add getMisheyakir12Point85Degrees()
This is marked as deprecated to alert developers using it that it should not be used without alerting the users that it is a "bisha'as hadchak" zman.
1 parent d810cfa commit 0ed8d22

File tree

1 file changed

+57
-2
lines changed

1 file changed

+57
-2
lines changed

src/main/java/com/kosherjava/zmanim/ComplexZmanimCalendar.java

Lines changed: 57 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
22
* Zmanim Java API
3-
* Copyright (C) 2004-2025 Eliyahu Hershfeld
3+
* Copyright (C) 2004-2026 Eliyahu Hershfeld
44
*
55
* This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General
66
* Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option)
@@ -105,7 +105,7 @@
105105
*
106106
* <h2>See documentation from the {@link ZmanimCalendar} parent class</h2>
107107
*
108-
* @author &copy; Eliyahu Hershfeld 2004 - 2025
108+
* @author &copy; Eliyahu Hershfeld 2004 - 2026
109109
*/
110110
public class ComplexZmanimCalendar extends ZmanimCalendar {
111111

@@ -195,6 +195,17 @@ public class ComplexZmanimCalendar extends ZmanimCalendar {
195195
* @see #getMisheyakir11Point5Degrees()
196196
*/
197197
protected static final double ZENITH_11_POINT_5 = GEOMETRIC_ZENITH + 11.5;
198+
199+
/**
200+
* The zenith of 12.85&deg; below {@link #GEOMETRIC_ZENITH geometric zenith} (90&deg;). This is used for calculating
201+
* <em>misheyakir</em> according to some opinions. This calculation is based on the position of the sun slightly less
202+
* than 57 minutes before {@link #getSunrise() sunrise} in Jerusalem <a href=
203+
* "https://kosherjava.com/2022/01/12/equinox-vs-equilux-zmanim-calculations/">around the equinox / equilux</a>, which
204+
* calculates to 12.85&deg; below {@link #GEOMETRIC_ZENITH geometric zenith}.
205+
*
206+
* @see #getMisheyakir12Point85Degrees()
207+
*/
208+
protected static final double ZENITH_12_POINT_85 = GEOMETRIC_ZENITH + 12.86;
198209

199210
/**
200211
* The zenith of 13.24&deg; below {@link #GEOMETRIC_ZENITH geometric zenith} (90&deg;). This calculation is used for
@@ -1123,6 +1134,50 @@ public Date getAlos19Point8Degrees() {
11231134
public Date getAlos16Point1Degrees() {
11241135
return getSunriseOffsetByDegrees(ZENITH_16_POINT_1);
11251136
}
1137+
1138+
/**
1139+
* This method returns <em>misheyakir</em> based on the position of the sun {@link #ZENITH_12_POINT_85 12.85&deg;}
1140+
* below {@link #GEOMETRIC_ZENITH geometric zenith} (90&deg;). This is based on the position of the sun slightly
1141+
* later than 57 minutes before {@link #getSunrise() sunrise} in Jerusalem <a href=
1142+
* "https://kosherjava.com/2022/01/12/equinox-vs-equilux-zmanim-calculations/">around the equinox / equilux</a>. This
1143+
* <em>zman</em> is mentioned for use <b><em>bish'as hadchak</em></b> in the Birur Halacha <a href=
1144+
* "https://hebrewbooks.org/pdfpager.aspx?req=50535&st=&pgnum=88">Tinyana</a> and <a href=
1145+
* "https://hebrewbooks.org/pdfpager.aspx?req=50537&st=&pgnum=31">Tlisa'ah</a> in Orach Chaim siman 18 as 12.85&deg;.
1146+
* Actual calculations show it to be slightly more than 12.9&deg;, but the Birur Halacha indicates that 12.85&deg; is a
1147+
* slight <em>chumra</em> (on a <em>bedieved</em> time) VS the 12.9&deg; that 57 minutes calculates as (a difference of
1148+
* about 14 seconds at the equinox/equilux in Jerusalem). The <em>zman</em> of 12.9&deg; is also mentioned in the Piskei
1149+
* Tshuvos siman 18, page 190 (where a typo indicates that this is the degree equivalent to 60 minutes before sunrise,
1150+
* when in fact at that point the sun is about 13.5&deg; below the horizon). The 57 minute based time is mentioned by the
1151+
* Minchas Yitzchak <a href="https://hebrewbooks.org/pdfpager.aspx?req=1601&st=&pgnum=21">vol. 9, siman 9</a> as 15 minutes
1152+
* before <em>alos hashachar</em> (though he is not clear what location he refers to, and does not mention a degree-based
1153+
* conversion). The Kaf Hachaim <a href="https://hebrewbooks.org/pdfpager.aspx?req=8140&st=&pgnum=81">vol.1 siman 18, no.
1154+
* 18</a> states that in Yerushalayim 60 fixed minutes are used year round. Calculations show that 60 fixed minutes in
1155+
* Yerushalayim ranges from 13.5&deg; at the spring equinox to 11.5&deg; at the summer solstice. 57-minute
1156+
* <em>misheyakir</em> range from 12.9&deg; at the winter equinox to 11&deg; at the summer solstice.
1157+
* Analysis of the difference between 12.85&deg; and 12.9&deg;, shows that the maximum difference occurs at the summer
1158+
* solstice. In Lakewood, NJ at a latitude of 40.096&deg;, the maximum difference throughout the year is 23 seconds.
1159+
* In the winter where there is the greatest need for very early <em>misheyakir</em> times, the difference is in the 16
1160+
* second range. Going north to Montreal at latitude 45.5&deg;, the maximum is 29 seconds and is about 18 seconds in the
1161+
* winter. Moving farther north to the elevation of Vilnius at a latitude of 54.68&deg;, things change. Firstly, around the
1162+
* summer solstice it will not reach that far below the horizon. On the dates that both can be calculated, the maximum
1163+
* difference can be pretty high on one or two days of the year (around Jul 8), with about a week having over a two minute
1164+
* difference between the two. Even at the latitude of Vilna, from Dec - March, the difference is about 22 seconds.
1165+
*
1166+
* @deprecated This method returns a very early <em>misheyakir</em> time that should only be used <b><em>bish'as
1167+
* hadchak</em></b>. <em>Lechatchila</em>, a later <em>zman</em> should be used. There is no current plan to remove
1168+
* this method from the API, and this deprecation is intended to notify developers to add an alert to users of
1169+
* the risk of using it.
1170+
*
1171+
* @return The <code>Date</code> of <em>misheyakir</em>. If the calculation can't be computed such as northern and
1172+
* southern locations even south of the Arctic Circle and north of the Antarctic Circle where the sun may
1173+
* not reach low enough below the horizon for this calculation, a <code>null</code> will be returned. See
1174+
* detailed explanation on top of the {@link AstronomicalCalendar} documentation.
1175+
* @see #ZENITH_12_POINT_85
1176+
*/
1177+
@Deprecated // (forRemoval=false) // add back once Java 9 is the minimum supported version
1178+
public Date getMisheyakir12Point85Degrees() {
1179+
return getSunriseOffsetByDegrees(ZENITH_12_POINT_85);
1180+
}
11261181

11271182
/**
11281183
* This method returns <em>misheyakir</em> based on the position of the sun when it is {@link #ZENITH_11_DEGREES

0 commit comments

Comments
 (0)