jyotisham / jyotisha

Python tools for the astronomical / astrological vedAnga of Hindus
MIT License
88 stars 54 forks source link

separate 3-fold division #143

Open vvasuki opened 11 months ago

vvasuki commented 11 months ago
    self.puurvaahna3 = get_interval(start_jd=jd_sunrise, end_jd=jd_sunset, part_index=0, num_parts=3)
    self.madhyaahna3 = get_interval(start_jd=jd_sunrise, end_jd=jd_sunset, part_index=1, num_parts=3)
    self.aparaahna3 = get_interval(start_jd=jd_sunrise, end_jd=jd_sunset, part_index=2, num_parts=3)

does not belong in FifteenFoldDivision . Please create a new class called ThreeFoldDivision and use it.

karthikraman commented 11 months ago

In principle, it's a fifteen-fold division, right, like the preceding lines of braahma, praatah, sangava etc.?

Maybe this would set it better?

    self.puurvaahna3 = get_interval(start_jd=jd_sunrise, end_jd=jd_sunset, part_index=range(0, 5), num_parts=15)
    self.madhyaahna3 = get_interval(start_jd=jd_sunrise, end_jd=jd_sunset, part_index=range(5,10), num_parts=15)
    self.aparaahna3 = get_interval(start_jd=jd_sunrise, end_jd=jd_sunset, part_index=range(10,15), num_parts=15)

I can make a ThreeFoldDivision also. But then should we make a FiveFoldDivision also? I liked the current organisation with Eight alone separate, as it's genuinely different.

vvasuki commented 11 months ago

In principle, it's a fifteen-fold division, right, like the preceding lines of braahma, praatah, sangava etc.? .... I can make a ThreeFoldDivision also. But then should we make a FiveFoldDivision also?

But the name-clash involving madhya and apara ahnas makes it ugly. Better separate both of them (> 3fold, 5fold) out - that way there's no confusion as to what's being referred.