More Date Stuff

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Dennis M. Marks

    More Date Stuff

    I've been updating by date stuff at my web site using much of the
    information obtained here. Would you please check it for any errors.

    The two pages are "Yearly Calendar" and "Date Calculator".
    There is no year validation on the "Yearly Calendar" but it is only
    correct for years 1 and up. There is full validation in the "Date
    Calculator" but I limited the dates to years 1-9999.

    I did not allow years before the year 1 since I am still confused about
    leap year calculation for B.C. dates.

    --
    Dennis M. Marks

    Replace domain.invalid with dcsi.net


    -----= Posted via Newsfeeds.Com, Uncensored Usenet News =-----
    http://www.newsfeeds.com - The #1 Newsgroup Service in the World!
    -----== Over 100,000 Newsgroups - 19 Different Servers! =-----
  • Dr John Stockton

    #2
    Re: More Date Stuff

    JRS: In article <20042004150834 2953%denmarks@d omain.invalid>, seen in
    news:comp.lang. javascript, Dennis M. Marks <denmarks@domai n.invalid>
    posted at Tue, 20 Apr 2004 15:08:34 :[color=blue]
    >I've been updating by date stuff at my web site using much of the
    >information obtained here. Would you please check it for any errors.
    >
    >The two pages are "Yearly Calendar" and "Date Calculator".
    >There is no year validation on the "Yearly Calendar" but it is only
    >correct for years 1 and up. There is full validation in the "Date
    >Calculator" but I limited the dates to years 1-9999.
    >
    >I did not allow years before the year 1 since I am still confused about
    >leap year calculation for B.C. dates.[/color]

    Read "The Calendar FAQ", linked from my site.

    In the proleptic Gregorian astronomical calendar, the same rules apply
    throughout. But one must allow for, or prevent, the different behaviour
    of the % operator with a negative argument. Similarly for the quasi-
    proleptic Julian.

    Convert between astronomical and Christian by adding/subtracting 1 for
    year numbers before Year 1.

    For the civil calendar, you can allow for the Julian-Gregorian change,
    varying with locality; the change from Roman to Arabic numerals; the
    change from AUC to AD dates; the miscalculations affecting 45BC..4AD;
    the Year of Confusion, etc.

    Then there is the matter of Sweden 1700-1712, Alaska 1867, and other
    more recent funny goings-on in the Pacific.

    --
    © John Stockton, Surrey, UK. ?@merlyn.demon. co.uk Turnpike v4.00 MIME. ©
    Web <URL:http://www.merlyn.demo n.co.uk/> - w. FAQish topics, links, acronyms
    PAS EXE etc : <URL:http://www.merlyn.demo n.co.uk/programs/> - see 00index.htm
    Dates - miscdate.htm moredate.htm js-dates.htm pas-time.htm critdate.htm etc.

    Comment

    • Mick White

      #3
      Re: More Date Stuff

      Dennis M. Marks wrote:[color=blue]
      > I've been updating by date stuff at my web site using much of the
      > information obtained here. Would you please check it for any errors.
      >
      > The two pages are "Yearly Calendar" and "Date Calculator".
      > There is no year validation on the "Yearly Calendar" but it is only
      > correct for years 1 and up. There is full validation in the "Date
      > Calculator" but I limited the dates to years 1-9999.
      >
      > I did not allow years before the year 1 since I am still confused about
      > leap year calculation for B.C. dates.
      >[/color]

      Date calculator doesn't work in Mac Safari 1.1, interesting, though.
      Mick


      Comment

      • Dennis M. Marks

        #4
        Re: More Date Stuff

        In article <v8Chc.71196$M3 .10005@twister. nyroc.rr.com>, Mick White
        <mwhite13@roche ster.rr.com> wrote:
        [color=blue]
        > Date calculator doesn't work in Mac Safari 1.1, interesting, though.
        > Mick[/color]

        Please explain the error. I do not have Safari.

        --
        Dennis M. Marks

        Replace domain.invalid with dcsi.net


        -----= Posted via Newsfeeds.Com, Uncensored Usenet News =-----
        http://www.newsfeeds.com - The #1 Newsgroup Service in the World!
        -----== Over 100,000 Newsgroups - 19 Different Servers! =-----

        Comment

        • Dennis M. Marks

          #5
          Re: More Date Stuff

          In article <E$PNjFAS1mhAFw x5@merlyn.demon .co.uk>, Dr John Stockton
          <spam@merlyn.de mon.co.uk> wrote:
          [color=blue]
          > In the proleptic Gregorian astronomical calendar, the same rules apply
          > throughout. But one must allow for, or prevent, the different behaviour
          > of the % operator with a negative argument. Similarly for the quasi-
          > proleptic Julian.[/color]

          The year 4AD is a leap year. From there the years are 3AD 2AD 1AD 1BC
          2BC 3BC 4BC etc. No year 0 in Gregorian Calendar.

          Is 4BC a leap year or is it 1BC(0 astrom) and 5BC(-4 astrom)? Maybe 1BC
          wouldn't be a leap year due to century rule or maybe it is a leap year
          due to the 400 year rule.

          --
          Dennis M. Marks

          Replace domain.invalid with dcsi.net


          -----= Posted via Newsfeeds.Com, Uncensored Usenet News =-----
          http://www.newsfeeds.com - The #1 Newsgroup Service in the World!
          -----== Over 100,000 Newsgroups - 19 Different Servers! =-----

          Comment

          • Dr John Stockton

            #6
            Re: More Date Stuff

            JRS: In article <21042004152955 8309%denmarks@d omain.invalid>, seen in
            news:comp.lang. javascript, Dennis M. Marks <denmarks@domai n.invalid>
            posted at Wed, 21 Apr 2004 15:29:55 :[color=blue]
            >In article <E$PNjFAS1mhAFw x5@merlyn.demon .co.uk>, Dr John Stockton
            ><spam@merlyn.d emon.co.uk> wrote:
            >[color=green]
            >> In the proleptic Gregorian astronomical calendar, the same rules apply
            >> throughout. But one must allow for, or prevent, the different behaviour
            >> of the % operator with a negative argument. Similarly for the quasi-
            >> proleptic Julian.[/color]
            >
            >The year 4AD is a leap year. From there the years are 3AD 2AD 1AD 1BC
            >2BC 3BC 4BC etc. No year 0 in Gregorian Calendar.[/color]

            You should read the references which have been given to you, and
            endeavour to understand what is written there and here. I used the word
            "astronomic al" for a purpose; I have already referred to it in this
            thread. There is no year in the gap below; there is no 0 AD nor 0 BC,
            but there is a Year 0.
            3 BC 2 BC 1 BC 1 AD 2 AD 3 AD common
            -2 -1 0 +1 +2 +3 astro
            DCCLI DCCLII DCCLIII DCCLIV DCCLV DCCLVI actual

            On the proleptic Gregorian calendar, 4 AD is leap.
            On the proleptic Gregorian astronomical calendar, +4 is leap.
            On the proleptic Julian calendar, 4 AD is leap.
            On the proleptic Julian astronomical calendar, +4 is leap.
            On the actual calendar of the time, DCCLVII AUC ought to have been Leap;
            but, in fact, it was not.
            All of those refer to the same physical year, but with a 2 physical day
            shift between Gregorian & Julian.
            [color=blue]
            >Is 4BC a leap year or is it 1BC(0 astrom) and 5BC(-4 astrom)? Maybe 1BC
            >wouldn't be a leap year due to century rule or maybe it is a leap year
            >due to the 400 year rule.[/color]

            4 BC is astronomical year -3; it is not Leap, on both proleptic
            calendars. Actually, it should probably not have been Leap; it also was
            not Leap, but for a different reason.

            5 BC is astronomical year -4; it is Leap, on both proleptic calendars.
            Actually, it should probably have been Leap; but it also was not Leap,
            for the same reason.

            1 BC is astronomical year 0; it is Leap, on both proleptic calendars,
            like 2000. Actually, it should probably have been Leap; it also was not
            Leap, for the same reason.


            Javascript does not need to store the year in a Date Object, but a
            millisecond count. When handling the year as a type Number, the
            proleptic astronomical Gregorian calendar is used. when handling the
            year as part of a string, the proleptic non-astronomical Gregorian
            calendar is used.

            This is in accordance with a famous, but perhaps mythical, statement by
            Winston Churchill, although the situation is as yet incomplete

            --
            © John Stockton, Surrey, UK. ?@merlyn.demon. co.uk Turnpike v4.00 MIME. ©
            Web <URL:http://www.merlyn.demo n.co.uk/> - w. FAQish topics, links, acronyms
            PAS EXE etc : <URL:http://www.merlyn.demo n.co.uk/programs/> - see 00index.htm
            Dates - miscdate.htm moredate.htm js-dates.htm pas-time.htm critdate.htm etc.

            Comment

            Working...