Friday, July 28, 2006

Prison Break考据篇



在Prison Break中,监狱里有一个很神秘的人物,就是D.B.Cooper,在监狱中的名字是Charles Westmoreland. 这老头人不错,可惜最后倒在了越狱前的最后一道关前。

实际上,历史上D. B. Cooper这个人是真实存在的,他的事迹和电视里传说的一样。1971年,有人以D. Cooper的名字劫持了一架727,他要了20万美元(这数目远小于电视里提到的数目了)的由20美元的钞票组成的现金和四个降落伞,条件满足后他命令飞行员将飞机飞往墨西哥,然后从空中跳下去了,之后就永远消失在人们的视野中。D. B. Cooper是记者报到的时候出现的typo. D. B. Cooper一案是世界上迄今唯一没有被破获的劫机案。之后的几十年里,出现了不少关于D. B. Cooper的影视和音乐作品,他甚至变成了一个大英雄。

http://www.usnews.com/usnews/doubleissue/mysteries/cooper.htm

From the 7/24/00 issue of USN&WR

Skyjacker at large
A Florida widow thinks she has found him


BY DOUGLAS PASTERNAK

It was the day before Thanksgiving, Nov. 24, 1971. As Northwest Airlines Flight 305, from Portland, Ore., to Seattle, sped along the runway preparing for takeoff, the man in Seat 18C, wearing sunglasses and a dark suit, handed a flight attendant a note. It said he had a bomb and threatened to blow up the Boeing 727 unless he received $200,000 cash and four parachutes when the plane landed. The man in Seat 18C purchased his ticket under the name "Dan Cooper."

After receiving his booty at the Seattle-Tacoma Airport, the man released the 36 passengers and two members of the flight crew. He ordered the pilot and remaining crew to fly to Mexico. At 10,000 feet, with winds gusting at 80 knots and a freezing rain pounding the airplane, Dan Cooper–mistakenly identified as D.B. Cooper by a reporter–walked down the rear stairs and parachuted into history.

What followed was one of the most extensive and expensive manhunts in the annals of American crime. For five months, federal, state, and local police combed dense hemlock forests north of Portland. D.B. Cooper became an American folk icon–the inspiration for books, rock songs, and even a 1981 movie. Over the past three decades, the Federal Bureau of Investigation has investigated more than 1,000 "serious suspects" along with assorted crackpots and deathbed confessors. Most–but not all–have been ruled out. The case was back in the news just last month when FBI agents investigated a skull discovered nearly 20 years ago along the Columbia River. It turned out to belong to a woman, possibly an American Indian. Today, the D.B. Cooper case remains the world's only unsolved skyjacking.

In March 1995, a Florida antique dealer named Duane Weber lay dying of polycystic kidney disease in a Pensacola hospital. He called his wife, Jo, to his bed and whispered: "I'm Dan Cooper." Jo, who had learned in 17 years of marriage not to pry too deeply into Duane's past, had no idea what her secretive husband meant. Frustrated, he blurted out: "Oh, let it die with me!" Duane died 11 days later. Jo sold his van two months after his death. The new owner discovered a wallet hidden in the overhead console. It contained a U.S. Navy "bad conduct discharge" in Duane's name and a Social Security card and prison-release form from the Missouri State Penitentiary, in the name of "John C. Collins." Duane had told Jo that he had served time for burglary under the name John Collins. Still, says Jo, a real-estate agent in Pace, Fla., Duane rarely spoke of his past. "His life started with me, and that was it," she says.


The FBI sketch strongly resembles a photo of Duane Weber.

In April 1996, Jo discussed Duane's criminal and military past with a friend. She also mentioned that just before he died, Duane had revealed the cause of an old knee injury. "I got it jumping out of a plane," Jo recalls him saying. "Did you ever think he might be D.B. Cooper?" the friend asked.

Handwriting match. In May 1996, Jo checked out a library book on D.B. Cooper. "I did not realize D.B. Cooper was known as Dan Cooper," Jo says. The book listed the FBI's description: mid-40s, 6 feet tall, 170 pounds, black hair, a bourbon drinker, a chain smoker. At the time of the hijacking, Duane Weber was 47, 6 feet, 1 inch tall, and weighed around 185 pounds. He had black hair, drank bourbon, and chain-smoked.

The similarities between a younger Duane and the FBI's composite drawings struck Jo. "It's about as close a match as you can get," agrees Frank Bender, a criminal forensic reconstructionist who has worked with the FBI for 20 years.

Jo never knew Duane to go to the library. Yet in pencil in the book's margins was what looked to her like Duane's handwriting. On one page he had written the name of a town in Washington where a placard from the rear stairs of Flight 305 had landed. "I knew right off the bat that handwriting was his," says Anne Faass, who worked with Duane for five years.

Jo called the FBI the night she read the D.B. Cooper book. "They just blew me off," she says. Eventually she began a dialogue with Ralph Himmelsbach, the FBI agent in charge of the case from 1971 until his retirement in 1980. At his urging, the FBI opened a file on Duane Weber in March 1997. They interviewed Jo, as well as one of Duane's former wives and his brother. They compared his fingerprints with the 66 unaccounted-for prints on Flight 305. None matched, although the FBI has no way to know if any of the prints were Cooper's. Himmelsbach finds Jo Weber, who has agreed to take a polygraph test, to be credible. There is no reward money to motivate her. He thinks she simply wants to learn the truth about her spouse. "The facts she has really seem to fit," he says. But the FBI dropped its investigation of Weber in July 1998. More "conclusive evidence" would be needed to continue, they say.

Though the facts are few, the circumstantial evidence is compelling. Retired FBI agent Himmelsbach believes the skyjacker must certainly have had a criminal record, military training, and familiarity with the Northwest. U.S. News has confirmed that Duane Weber served in the Army in the early 1940s. He also did time in at least six prisons from 1945 to 1968 for burglary and forgery. One prison was McNeil Island in Steilacoom, Wash.–20 miles from the Seattle-Tacoma airport.

The skyjacking was a desperate act by a desperate man. In 1971, Duane Weber's emotional and physical health were failing. He was on the verge of separating from his fifth wife and had been diagnosed with kidney disease; he was not expected to live past 50. Himmelsbach believes the skyjacking may have been a criminal's last hurrah and says Weber is one of the best suspects he has come across.

A skeptic at first, Jo Weber now believes her husband of 17 years was D.B. Cooper. "If he is not," she says, "he sure did send me on the wildest ride any widow has ever been on."



劫机犯逃之夭夭
一个佛罗里达的寡妇认为自己发现了他
事情发生在感恩节的前夜,1971年11月24日。一架西北航空公司的305航班在跑到上径直加速,准备从波特兰飞往西雅图。一个坐在18C位置上的戴着墨镜身穿深色西服的中年男子递给机组人员一张纸条,上面写道他有一颗炸弹并威胁要炸掉飞机,除非在飞机降落后给他提供20万美元现金和四个降落伞。这个坐在18C的男子买票时用的名字是Dan Cooper。

当他的要求在S-T机场被满足后,他释放了36名乘客和2名机组人员,而后他命令飞行员将飞机飞往墨西哥。当飞机达到10000英尺高风速达到80哩/时并伴有冻雨时,Dan Cooper 从飞机上跳了下去。他的名字却被一名记者错误地报道为D.B.Cooper从而写进了历史。

接下来发生的就是美国刑侦史上规模最庞大花销最昂贵的大搜捕。在接下来的5个月里,联邦政府、州警还有地方警察在波特兰北部茂密的针叶林里进行了规模空前的大搜捕但一无所获。D.B.Cooper逐渐成为了美国人的偶像,他成为了小说和摇滚的创作灵感甚至于1981年拍成了电影。在过去的30年里,联邦调查局调查了超过 1000名嫌疑犯还有那些自称是D.B.Cooper的人,但绝大多数都已经排除。这个案子重新回到人们的视野中是因为上个月FBI在调查一个在哥伦比亚河旁发现的20年前的一个头骨的案子。不过事后证实那个头骨应该是一个印第安妇女的。直到今天,D.B.Cooper这个案子是世界上唯一的悬而未决的劫机案。

在1995年3月,一个佛罗里达的叫Duane Weber 古董商在他弥留之际对自己的夫人Jo说自己就是Dan Cooper。在Duane死后两个月,Jo卖掉了他的小货车,新买主在驾驶室的顶棚里发现了一个皮夹,里面有一张以Duane名字的美国海军解雇书,一张社会保障卡和一张以John C. Collins名字的密苏里州立监狱的假释证明。Jo后来回忆道Duane曾跟他说过他曾以John C. Collins的名字因入室行窃坐过牢,他还告诉她自己在佛州的Pace有一处不动产。

在1996年的4月,Jo和一个朋友在议论Duane的过去时回忆道,在Duane离世之前他曾跟他透露过自己的膝伤是因为从飞机上跳下来的缘故。

这片报道美国海军报2000年7月24日

Friday, July 21, 2006

关于阳历转换阴历(转贴)

http://www.goodsgy.com/articles/art1087.html
公历转换农历的算法

作者:不详 出处:不详 更新日期:2005-9-20 共阅4155次

//JavaScript语法


<script language="JavaScript" >
var CalendarData=new Array(20);
var madd=new Array(12);
var TheDate=new Date();
var tgString="甲乙丙丁戊己庚辛壬癸";
var dzString="子丑寅卯辰巳午未申酉戌亥";
var numString="一二三四五六七八九十";
var monString="正二三四五六七八九十冬腊";
var weekString="日一二三四五六";
var sx="鼠牛虎兔龙蛇马羊猴鸡狗猪";
var cYear;
var cMonth;
var cDay;
var cHour;
var cDateString;
var DateString;
var Browser=navigator.appName;
function init()
{
CalendarData[0]=0x41A95;
CalendarData[1]=0xD4A;
CalendarData[2]=0xDA5;
CalendarData[3]=0x20B55;
CalendarData[4]=0x56A;
CalendarData[5]=0x7155B;
CalendarData[6]=0x25D;
CalendarData[7]=0x92D;
CalendarData[8]=0x5192B;
CalendarData[9]=0xA95;
CalendarData[10]=0xB4A;
CalendarData[11]=0x416AA;
CalendarData[12]=0xAD5;
CalendarData[13]=0x90AB5;
CalendarData[14]=0x4BA;
CalendarData[15]=0xA5B;
CalendarData[16]=0x60A57;
CalendarData[17]=0x52B;
CalendarData[18]=0xA93;
CalendarData[19]=0x40E95;
madd[0]=0;
madd[1]=31;
madd[2]=59;
madd[3]=90;
madd[4]=120;
madd[5]=151;
madd[6]=181;
madd[7]=212;
madd[8]=243;
madd[9]=273;
madd[10]=304;
madd[11]=334;
}
function GetBit(m,n)
{
return (m>>n)&1;
}
function e2c()
{
var total,m,n,k;
var isEnd=false;
var tmp=TheDate.getYear();
if (tmp<1900) tmp+=1900;
total=(tmp-2001)*365
+Math.floor((tmp-2001)/4)
+madd[TheDate.getMonth()]
+TheDate.getDate()
-23;
if (TheDate.getYear()%4==0&&TheDate.getMonth()>1)
total++;
for(m=0;;m++)
{
k=(CalendarData[m]<0xfff)?11:12;
for(n=k;n>=0;n--)
{
if(total<=29+GetBit(CalendarData[m],n))
{
isEnd=true;
break;
}
total=total-29-GetBit(CalendarData[m],n);
}
if(isEnd)break;
}
cYear=2001 + m;
cMonth=k-n+1;
cDay=total;
if(k==12)
{
if(cMonth==Math.floor(CalendarData[m]/0x10000)+1)
cMonth=1-cMonth;
if(cMonth>Math.floor(CalendarData[m]/0x10000)+1)
cMonth--;
}
cHour=Math.floor((TheDate.getHours()+3)/2);
}
function GetcDateString()
{ var tmp="";
tmp+=tgString.charAt((cYear-4)%10); //年干
tmp+=dzString.charAt((cYear-4)%12); //年支
tmp+="年(";
tmp+=sx.charAt((cYear-4)%12);
tmp+=")";
if(cMonth<1)
{
tmp+="闰";
tmp+=monString.charAt(-cMonth-1);
}
else
tmp+=monString.charAt(cMonth-1);
tmp+="月";
tmp+=(cDay<11)?"初":((cDay<20)?"十":((cDay<30)?"廿":"卅"));
if(cDay%10!=0||cDay==10)
tmp+=numString.charAt((cDay-1)%10);
if(cHour==13)tmp+="夜";
tmp+=dzString.charAt((cHour-1)%12);
tmp+="时";
cDateString=tmp;
return tmp;
}
function GetDateString()
{
var tmp="";
var t1=TheDate.getYear();
if (t1<1900)t1+=1900;
tmp+=t1
+"-"
+(TheDate.getMonth()+1)+"-"
+TheDate.getDate()+" "
+TheDate.getHours()+":"
+((TheDate.getMinutes()<10)?"0":"")
+TheDate.getMinutes()
+" 星期"+weekString.charAt(TheDate.getDay());
DateString=tmp;
return tmp;
}
init();
e2c();
GetDateString();
GetcDateString();
document.write(DateString,"
",cDateString);
</script>




//关于农历

农 历
  农历是我国的一种历法,又称夏历、中历、旧历,俗称阴历。定月的方法是用朔望月周期给出,朔所在日为初一,朔望月长约29天半,所以农历大月30天,小月29天。农历平年有十二个月,全年354天或355天,闰年为十三个月,其中某一月为闰月,月名依前一月名而定,如前月是八月,闰月则为闰八月。闰年全年383天或384天。设置闰月的方法是:农历月份中无“中气”的月份则是闰月。
农历平年、闰年的月数、天数一览表

年 月数 大月天数 小月天数 全年天数 闰月设置方法
平年 12 30 29 354 大约19年中7个闰月
闰年 13 30 29 383(或384) 无中气月份为闰月

二十四节气中四季“节气”和“中气”一览表

四季 春 夏 秋 冬
节气 立春 惊蛰 清明 立夏 芒种 小暑 立秋 白露 寒露 立冬 大雪 小寒
中气 雨水 春分 谷雨 小满 夏至 大暑 处暑 秋分 霜降 小雪 冬至 大寒
  农历又根据太阳的位置,把太阳年分成二十四个节气,反映寒冷暑热的气候变化,以便家事活动,所以农历实为阴阳历。


如何转换阴阳历?
  很多人都一直在找换阴阳历的公式。我也尝试过。曾读过「高平子」天文前辈所着「学历散论」了解古历的变更和阴阳历的缺陷。才知道由於月球转动的不稳定不规则,确定无公式可寻。这也是古代中国每百年必改历的原因。
阴历最大的问题是在如何置闰。好像不难,因为阴历基本法则如下:
 * 月朔日即是初一
 * 月以中气得名
 * 以包含雨水中气月为正月,即是「寅」月
 * 月无中气者为闰月,以前月同名

  如果,日月转动循还有规则的话, 推演一套阴阳历转换的公式并不难。问题在有时一个太阴月比一个太阳月还要长。如此一个太阴月就有可能包括两个中气。此双中气月後的阴历月名就全部乱掉了,直到下一个「假」闰月後才调整过来。

  一般人接触到的阴阳历是民用历法,它是政府颁令的以东经120度计算的历法或称中原标准时间或北京时。如果,我们用不同时区、不同经度为子午线来重新计算阴阳历,民用历法的置闰法则出了很大的问题。不同时区的闰月可能落在不同月。换言之,在一百年内,任何两个时区的闰月顺序模式是会不相同的。

  高平子前辈书中提到了「历理置闰法」。如果应用历理置闰法到不同时区,则所有不同时区的闰月都落在相同月。如此不同时区、不同经度的阴阳历置闰之问题就消失了。民用置闰和历理置闰的不同是:

  * 在民用置闰,如果月朔日和中气同一天,则该阴历月包含那个中气。
  * 在历理置闰,如果月朔日和中气同一天,月朔日时间必须在中气时间之前,则该阴历月才包含那个中气。

  简言之,民用置闰比较月朔和中气日期;历理置闰比较月朔和中气日期、时、分、秒。由此可知,没有精确的太阳和月亮的时间数字,阴历的闰月可能会排错了。

  基於这些理由,我着手寻找天文公式计算精确的太阳和月亮在纬度的时间。当年没有网路,发了大半年於美国南加州各大图书馆及大学,找寻答案。1993年出版了「中美天文万年历」一书。书中精确的天文日月时间只从1900到2010年。因恐2011後时间误差超过一分钟,不够精确,不敢印出。今年2002从网路资讯,确定太阳和月亮时间的精确度後,百忙中重新整理资料,提供给需要阴阳历转换公式的朋友。

  整理出的太阳和月亮时间数字是从西元1年到2246年。有历理和中国民用两套历法。数字内容清清楚楚的看出民用历法的敝端。例如,从西元1600年到2246年,民用历法双中气的阴历月有22个,历理历法只有5个。民用历法甚至在2033、2128和2242年中,三个月之间居然跑出两个双中气;换言之,三个月中多出两个「假」闰月。前後12个阴历月中有三个闰月,闰月的去留造成许多学者的讨论和困恼。历理历法在此三年中,却没有发现到双中气阴历月。闰月的去留只要把双中气月後的「假」闰月取消,则历理历法近乎於完美。


  由此可知,民用历法问题很大,应该废除。上次阴阳历重大改历在1645年,已经超过350年。随着天文科学的进步,中国阴阳历应该使用较精确的历理历法。免得後代子孙再浪费时间讨论置闰去留的问题。

  阴阳历应用在八字算命、紫微斗数、农民历、遁甲历最多。很多人不知道排八字只用阳历而不用阴历。发了许多时间在研究阴阳历的转换。其实八字只使用太阳中节气,和月亮没有任何关系。紫微斗数则需要阴历日期去排命盘。美国时区的阴历日期有一半和中国时区的阴历日期差一天,因为时差超过12小时;初一就可能在不同日之故。有位在加拿大职业算命的朋友,精通八字和紫微斗数,研究其女命盘。八字论父母,合情合理。斗数父母宫,看不出自己影子。後来,在中美天文万年历一书发现了「差一天」之解答。

  曾有一位退休博士用了近三十年找寻阴阳历的公式,问遍两岸各大天文台,得不到答案,直到发现中美天文万年历一书。最後,希望我重新整理的中国阴阳历的天文数字和原始程式,能给有求知欲於阴阳历转换方法的读友一个答案,以免得不到答案而遗憾终身。


中国阴阳历的天文数字和原始程式用简单英文阐述,
请从下述 Chinese Lunar Calendar 进入

------------------------------------------------------------------
高平子 Kao Ping Tse”1888-1970〔是中国近代最有成就的天文学者之一。他没有接受正规的天文教育。凭着对天文的酷爱,自己研读天文书籍。因为他对天文的贡献,在他的百年冥诞,月球的一个环形月坑以他的名字为名。位置在月球东经87.6度,南纬6.7度, 直径34公里,为国争光。

Wednesday, July 19, 2006

Linux/Unix,日历以及宗教

很久都没更新了,前一阵事忙,后来有次看到关于linux/Unix日历的小百科,有趣,想转来却发现居然blog系统有问题,这次总算发出来了。

在linux下执行cal 9 1752,会看到很奇怪的输出结果
$ cal 9 1752
September 1752
S M Tu W Th F S
1 2 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30

就是说9月2日到14日之间的11天都蒸发了,windows下由于开始的纪年是1980年,所以看不到这个结果。这不是bug,而是8g。具体是与历法发展的历史有关。下面是转贴的一段文字:
--------
儒略日是由法国学者 Joseph Justus Scaliger (1540-1609)发明的, 名称可能是取自 Scaliger 的父亲, 意大利学者Julius Caesar Scaliger (1484-1558)。 天文学家已经用儒略周期为自 4713 BC 一月一日以来的每一天赋予了一个唯一的数字。 这就是所谓的儒略日(JD)。 JD 0 指定为 4713 BC 一月一日正午 UTC 到 4713 BC 一月二日正午 UTC 的 24 小时。

"儒略日(julian Day)" 与"儒略历(Julian Calendar)"不同。 儒略历是 Julius Caesar 在 45 BC 发明的。一直用到大约 1582 年, 这时各国开始使用罗马历法。在儒略历里面, 一年是近似 365 1/4 天 = 365.25 天。 这样大约每 128 年就有一天的误差。

不断积累的历法错误促使教皇格里高利十三世(Gregory XIII)按照与弥撒议会 ( Council of Trent)一致的精神改革了历法。 在罗马历法里,一年是近似 365 + 97 / 400 天 = 365.2425 天。 因此对应于罗马历法,大约要 3300 年,才会积累一天的误差。

近似的 365+97/400 是通过利用下面的规则, 规定每 400 年有 97 个闰年实现的:


每个可被 4 整除的年是一个闰年。
不过,可被 100 整除的年不是闰年。
但是,可以被 400 整除的年还是闰年。


因此,1700,1800,1900,2100 和 2200 年都不是闰年。而1600,2000,和 2400年是闰年。 相比而言,旧式的 Julian 历法里面只有能被 4 整除的年是闰年。

1582 二月,罗马教廷要求从 1582 年十月减去十天, 因此1852(应为1582)年十月四日后面紧跟着就是十五日。 在意大利,波兰,葡萄牙 和西班牙都这样处理了。 其他天主教国家也很快跟着这么做了,但是新教国家不愿意修改, 而且希腊等东正教国家直到20世纪初才修改。 这个改革在英国及其殖民地(包括现在的 USA)在 1752年执行了。 这样 1752 年九月二日后面跟着 1752 年九月十四日。 这就是为什么 Unix 系统的cal生成下面的输出:

$ cal 9 1752
September 1752
S M Tu W Th F S
1 2 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30

注意: SQL 标准声称 "在日期时间字面'datetime literal'的定义上, '日期时间(datetime)值' 中的日期和时间根据罗马历法受自然法则的约束 "。 在 1752-09-03 和 1752-09-13 之间的日子, 尽管被罗马教廷的教令取消了,但为了和 "自然法则"相一致,因而是有效的日期。

在世界的不同的地方,发明了许多不同的历法,有许多比罗马历法系统还早。 例如,中国历法的最早应用可以追溯到公元前14世纪。 传说黄帝在 2637 BC 就发明了这个历法。 中华人民共和国使用罗马历法用于民用。中国历法用于决定节日/节气。

----
补充:事后,好事者发现emacs中的日历却没有这特点,还专门发信去问。得到的答复是,没有问题,因为作者认为(应该不是那长得特麻原彰幌的Richard Stallman)作为同一种日历是不该出现这种跳跃的,比如我如果采用格利高里历法,那么每一天都是按照此历顺推。日期中的跳跃,应该只在改变历法的时候才会出现,这话也有道理。所以说这毕竟还是公说公有理,婆说婆有理的事情了。

----


中学的时候,对历法的“研究”很是痴迷,起因正是对编程的爱好。小学时到一师兄家里,他家有一台PC1500的袖珍电脑,上面带小打印机的那种,打印纸宽度就和现在商店里打印的收据差不多,不过纸的质量好得多。师兄编程给我打了一个日历,印象中月份用彩笔画出来,整个日历就一长条,但很好看。于是我就被毒害了,当时觉得自己设计程序,听着很神圣的样子,而似乎能打印日历就是编程的最高境界了。而后来我上初一,用的微机课本,最后一个大的project就是讲如何打印任何一年的年历,更加深了我的印象。

到了初中那年暑假,正是闲着,父亲单位上也配了这种袖珍计算机,父亲有时候用他打印一些简单的开方表什么的。到了我手里可就成了宝贝了,我还弄到一本详细讲解PC1500编程的宝典。暑假里就想自己写一个可以打印任何一年年历的程序。阳历是很快就写出来了,问题是雄心勃勃的我还希望能加上中国的传统节日和阴历。其实阳历的计算很简单,就是用365.2425天就可以搞定,但任何一年的阴历就很复杂了。当时一直没有办法找到任何关于阴阳历转换的算法资料,后来就只好作罢。这事情在幼小的心灵里形成了一种叫情结的东西。后来我大四的时候还想起来这事情,有网络在手,第一想法就是去搜,这才发现阴阳历的转化好象比我想得要困难一些。当时还在北大学报上搜到一篇关于阴阳历转换的文章,真没想到原来这还是一坑,可以在北大学报上灌水呢。