Date Functions, version 1.2 for Russ Webb's RPN Calculator.
Copyright (c) 1997 by Marvin E. Wilborne III

Overview
========

This function set allows you to manipulate dates on the stack using a subset
of the functions available in the Julian Day functions, available at

        http://www3.gamewood.net/mew3/pilot/rpn/

You will need Russ Webb's RPN calculator (which is seperately registered
shareware) and is available at:

        http://kale.ee.cornell.edu/pilot/

The functions are provided in an easy to install PDB file and are
automatically loaded into RPN when you install the file then hotsync.

Detailed Function Explanation
=============================

Function        Result

-               Take two dates in the x and y position and compute the
                difference in days.  The dates should be in MM.DDYYYY
                format.

                The result will be negative if the second date entered is
                before the first date.

                The function can be used for all dates between and including
                15 October 1582 and 31 December 9999.

                Example:  "How many days between the Declaration of
                Independence and the Bicentennial celebration?"
                7.041776        <ENTER>
                7.041976        <->
                73048.000000    (answer is in days)

+               Take a date in the y position and a number of days (positive
                or negative in the x position, add them giving a new date.

                For negative days, the date computed will be in the past
                relative to the date entered, for positive days, the date
                will be in the future relative to the date entered.

                Example:  "What date was 10000 days after the Declaration of
                Independence?"

                7.041776        <ENTER>
                10000           <+>
                11.211803       (answer 11/21/1803, November 21, 1803)

                Exampe:  "What date was 10000 days before the Declaration of
                Independence?"

                7.041776        <ENTER>
                -10000          <+/-> then <+> (i.e. change sign then use +)
                2.161749        (answer is February 16, 1749)
                
T-              Compute the difference in days from the date in the x
                position (top of the stack) and today.  Great because you
                only have to enter the future or past date.

                The answer will be negative days if the date is BEFORE today,
                and it will be positive if the date is AFTER today.

                Example:  "How many days ago was the Declaration of
                Independence?"

                7.041776        <T->
                -80789.0        (answer from 9/13/1997 in days)

                Example:  "How many days until January 1, 2000?"

                1.012000        <T->
                840.0           (answer from 9/13/1997 in days)

T+              Compute the date from today with the number of days in the x
                position on the stack.  If the days are negative, the date
                will be in the past.  If the days are positive, the date will
                be in the future.

                10000.0         <T+>
                1.292025        (January 29, 2025 is 10000 days from
                                9/13/1997)

TDY             Put today's date on the stack

DOW             Tell me the day of the week for a date in stack position x.

                Example:  "What day of the week is Jan 1, 2000 on?"

                1.012000        <DOW>
                6.0             6 = Saturday, 0 = Sunday, 1 = Monday, ...

                Example:  "What day of the week did Neil Armstrong walk on
                the moon?"

                11.211969       <DOW>
                5.0             Friday.

dy              Day of Year/Days left in Year function.

                Put a date on the stack and press this button (or drag a
                date on to this button) and you'll get the day of year for
                the date and the number of days remaining in the year.

                Example:  "What day of the yeard did Neil Armstrong walk on
                the moon?"

                11.211969       <DY>
                325.0           Day of the year...
                40.0            Days remaining in 1969

wy              Week of year function.

                This function takes a date and returns the week of the year.

                Example:  "What week was the Declaration of Indepence
                signed?"

                7.041776        <WY>
                27.0            The 27th week.

!               My favorite function, I like to call it the OUCH! function.
                When pressed it will tell you the number of days until
                January 1, 2000--when some programs may stop working.
                (This program is year 2000 compliant, it is not year 10000
                compliant!)

?               About functions, function.  Title and e-mail address.


Registration
============

This function set is Shareware.  You can download it and use it for 30 days
without registering.  If you continue to use it after 30 days, please
register by sending $5.00 to:

        Marvin E. Wilborne III
        124 Matthew Circle
        Danville, VA 24540

You can register this software on-line at PilotGear at this URL:
        http://www2.viaweb.com/pilotgearsw/allap1.html

        Or call, toll free, 800-741-9070

If you've already registered a RPN function set that I've developed, then
you're already registered for these.  I call it cross registering.

Address comments or questions by e-mail to:

        wilborne@gamewood.net

Legal Notice
============

This software is copyrighted (c) 1997 by Marvin E. Wilborne III. Furthermore,
I make  no warranty with respect to the quality of this software, nor do I
warrant that its operation will be error-free. The author claims no liability
for data loss or any other problems caused directly or indirectly by use of
this application.

This function set may be freely distributed provided that this file is
included with the PDB file that contains the functions.
