home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
DP Tool Club 26
/
CD_ASCQ_26_1295.iso
/
vrac
/
hebrd103.zip
/
HEBRDATE.DOC
< prev
next >
Wrap
Text File
|
1995-10-06
|
11KB
|
213 lines
HebrDate 1.03
Hebrew Date Calculator
Copyright (c) Irving Maron 1995 All Rights Reserved
(1) Introduction.
HEBRDATE.EXE operates under MS-DOS, or compatible. It can obtain the current
system clock date (common or Gregorian date), convert it to the current
Hebrew date, and print the Hebrew date to the screen. It can be used to
calculate conversions between Hebrew date, Gregorian date and Julian date,
and to calculate the Gregorian dates of Hebrew anniversaries. It can process
text files to find lines containing dates, and to append defined date
conversions to each line. It can provide a list of Jewish holidays for any
Gregorian year, or for any Julian year before 1921. (The Julian calendar was
in use in Russia as late as 1917, and in England and the colonies until
1752.)
(2) HebrDate Command Summary.
Syntax: [drive:][path]hebrdate [Command]
Command Output (to screen)
----------------------------------------------------------------------------
No command Current Hebrew date.
/c Opens date calculator. Follow directions on screen.
/g, /gs Command line Gregorian date to Hebrew date.
/h, /hs Command line Hebrew date to Gregorian date.
/j, /js Command line Julian date to Hebrew date.
/<year> List of Jewish holidays for Gregorian <year> (e.g., /1492)
/<year>j List of Jewish holidays for Julian <year> (e.g., /1492j)
/y List of Jewish holidays for current (Gregorian) year.
/m List of Jewish holidays for current month, plus holidays.
for next month if current day-of-month 15th or greater.
/? or /help Command summary (also displayed if command unrecognized).
----------------------------------------------------------------------------
NOTE: Commands /h and /hs, above, are new in Version 1.03; commands /y and
/m were /h and /hr in Version 1.02.
(3) Detailed Description of HebrDate Commands.
(3.1) Command: no command
For the current Hebrew date, enter [drive:][path]hebrdate at the DOS prompt,
or add [drive:][path]hebrdate at the end of AUTOEXEC.BAT to see the current
Hebrew date on the screen at bootup (if you don't boot up directly into
WINDOWS or some application, of course).
(3.2) Command: /c
To use HebrDate as a calculator, enter the command [drive:][path]hebrdate/c
at the DOS prompt, and follow the directions on the screen. Whenever
HebrDate is used as a calculator, all computing activity is written to an
ASCII text file, named HEBRDATE.LOG, in the current directory.
(3.3) Commands: /g, /gs, /h, /hs, /j, /js
Converting from Gregorian or Julian date to Hebrew date and Hebrew date to
Gregorian date can also be done on the command line (i.e., at the DOS
prompt). To do this, enter the command [drive:][path]hebrdate/x, where "x"
is "g", "h" or "j", and then, at the blinking cursor prompt, enter the date
to be converted in mm-dd-yyyy or mm/dd/yyyy format. The corresponding
Hebrew date will be printed in response to the "g" or "j" commands, or
Gregorian date in response to the "h" command, and the cursor will then
blink for another input. Command returns to DOS when you default (i.e.,
press Enter with nothing typed on the line). The format for the date in
response to the /g, /h or/j commands consists of "name-of-month, day year".
For dates in the mm-dd-yyyy or mm/dd/yyyy format, append "s" to the
commands, as shown above.
These commands can also be used to process Gregorian, Hebrew or Julian
dates contained in text (ASCII) files, appending the corresponding
converted dates to each line of text where a date appears. The dates to be
converted must be in the mm-dd-yyyy or mm/dd/yyyy format. To do the text
file processing for a Gregorian to Hebrew conversion, enter (at DOS prompt)
"[drive:][path]hebrdate/g < infile.txt > outfile.txt"
(without the double quote symbols, of course), where infile.txt is the name
of the file containing the input data, and outfile.txt is the name assigned
to the results file (where infile.txt and outfile.txt can be replaced by
whatever filenames you prefer). The outfile.txt file will contain all the
data in infile.txt plus additional entries at the end of each line,
consisting of the Hebrew date corresponding to each Gregorian date in the
line.
To do text file processing for Julian date to Hebrew date, use "/j" instead
of "/g" in the command at the DOS prompt; for processing Hebrew date to
Gregorian, use /h.
To print the converted dates in the mm-dd-yyyy or mm/dd/yyyy formats, use
/gs, /hs or /js (i.e., append "s" to the basic command). To print the date
within parentheses, add a "p" after the "s".
Text File Processing Caveats:
Dates in the input file must be preceded and followed by at least one
space.
A comma in any line of data acts as a signal to the program not to process
any dates that may be present in the line. Lines containing a comma will be
flagged in the output file by the comment "Comma noted ...".
Any date in the input text file that is invalid or is out-of-range
(earlier than 1/1/1 of the Gregorian calendar) will be ignored.
Text File Processing Example: Let infile.txt consist of the following:
Ref.No. Name Date-of-Birth Birthplace Date-of-Death
------------------------------------------------------
102.34 Joe1 1/25/1904 Russia 9/12/1976
203.45 Joe2 4/14/1911 Poland 12/14/1984
. . . . .
. . . . .
. . . . .
591.76 JoeN 12/23/1898 Germany 4/19/1943
Then outfile.txt will be (in response to the /gs command):
Ref.No. Name Date-of-Birth Birthplace Date-of-Death
------------------------------------------------------
102.34 Joe1 1/25/1904 Russia 9/12/1976 11/08/5664 06/17/5736
203.45 Joe2 4/14/1911 Poland 12/14/1984 01/16/5671 09/20/5745
. . . . .
. . . . .
. . . . .
591.76 JoeN 12/23/1898 Germany 4/19/1943 10/10/5659 01/14/5703
The 6th column in outfile.txt is the Hebrew "Date-of-Birth" column, and the
7th column is the Hebrew "Date-of-Death" column.
(3.4) Commands: /<year>, /<year>j, /y, /m
To obtain a list of Jewish holidays in any Gregorian year, enter
[drive:][path]hebrdate/<year> at the DOS prompt, where <year> is the
numerical year (e.g., 1492 or 1995 or 350).
For a list of Jewish holidays in the current Gregorian (Common) year,
replace /<year> with /y. For a list of Jewish holidays in the current month,
plus the holidays in the following month if the current day-of-month is the
15th or greater, use /m instead of /y.
To obtain a list of Jewish holidays in a Julian year, proceed as above but
append the letter "j" to the numerical year (e.g., 1492j instead of 1492).
The holiday lists can be saved to a file or printed out to hardcopy by
redirecting the output of the commands to a file or printer, using the
greater-than sign (>) and name of file or device (lpt1 for printer
connected to lpt1), the same as with MS-DOS commands.
(4) Note on Earliest Observance of Jewish Holidays.
For the religious holidays not described in the Torah, the earliest year in
which each holiday appears in the various holiday lists produced by HebrDate
is intended to be more-or-less historically correct, but is based only on
the search of a few reference sources. Any corrections anyone wants to offer
will be appreciated. The information on the earliest observance for the
Israeli national holidays was obtained from the Government of Israel
Information Service. The earliest observances used in HebrDate are as
follows:
(Since HebrDate goes back only to the Gregorian year 1, any earliest
observance prior to that date is noted as "no problem". Dates are
Gregorian, or C.E.)
Tu B'Shevat - 200 (Date when Rabbi Judah HaNasi published traditions
of Mishna, where Tu B'Shevat is discussed.)
Purim, Pesach - no problem
Yom Ha'Shoah - 1950
Yom Hazikaron - 1948
Yom Ha'Atzma'ut - 1948
Lag Ba'Omer - 138 (Marks pause in Hadrian's oppression after Bar Kochba
revolt of 131-5; Hadrian died in 138.)
Yom Yerushalayim - 1967
Shavuot, Tisha B'Av, Rosh Hashana, Yom Kippur - no problem
Sukkot, Shemini Atzeret, Hanukkah - no problem
Simchat Torah - no problem (Although Simchat Torah in its present form
was not defined until a few hundred years ago,
it apparently started with the 1 year cycle of
Torah reading during the Babylonian exile, and
was no doubt brought back to Israel with the
returning exiles.)
(5) Slightly Technical Note on Holidays in the Distant Future.
The Jewish holidays for Gregorian years are produced by this program only
for years up to the Gregorian year 6460. (This should cover most early
planning needs.) The current Hebrew calendar drifts forward relative to the
Gregorian calendar (and the seasons) at the average rate of 4.32 days per
thousand years (based upon a least-squares straight-line fit to the
Gregorian day-of-year corresponding to fixed Hebrew dates, using yearly data
from Gregorian 1 to Gregorian 7000). By the Gregorian year 6461 (Hebrew year
10222), the drift will have amounted to 28 days since year 1 of the
Gregorian calendar. There will no doubt be a one-time calendar fix
instituted at that time to slip back 28 days (e.g., by dropping Adar-II
from the year 10222 and adding one day to Adar-I to make a 31-day Adar),
but until we know for sure, we'll quit at 6460 CE.
* * * * * * * * * *
The date calculation source coding for HEBRDATE.EXE is based upon algorithms
described by the Lisp code in "Calendrical Calculations" by Nachum Dershowitz
and Edward M. Reingold, Software---Practice & Experience, vol. 20, no. 9
(September, 1990), pp. 899--928 (with 5/19/93 correction by EMR).
HEBRDATE.EXE is freeware. Permission is granted for unrestricted
noncommercial use.
Irving Maron
Mount Laurel, NJ
Compuserve address: 76614,2666
e-mail address: 76614.2666@compuserve.com
October 5, 1995
Tishri 11, 5756