APP下载

基于周易的骰子预测算法实现

2016-01-05王日宏吴佩龙

电脑知识与技术 2015年29期

王日宏++吴佩龙

摘要:《周易》是中国传统文化之首,其内容十分丰富,涉及范围非常广泛。周易预测是运用八卦来预测自然界、社会和人本身的各种信息。八卦预测信息的方法,不仅经历的漫长的岁月,而且演变出许多种类。而周易骰子预测算法,是周易预测最基本的方法之一。此研究介绍了周易的基本概念,并通过研究周易八卦和莱布尼茨二进制的关系,将周易骰子预测算法应用于计算机,实现对信息简单的预测,最后得出相应的预测结果。

关键词:周易八卦;骰子预测;二进制

中图分类号:TP305 文献标识码:A 文章编号:1009-3044(2015)29-0200-02

The Achievement on Computer Based on ZhouYi Sieve Forecast Diagrams

WANG Ri-hong,WU Pei-long

(School of Computer Engineering,Qingdao Technological University, Qingdao 266033, China)

Abstract: ZhouYi has been the leader of traditional chinese culture for thousand years,it is rich in content and vast in range. It can forecast many kinds of information includeing natural world,social and human beings by applying Eight Diagrams. After going through a long time for its evolution, the method it used to forecast information has generated several kinds, the Sieve Algorithm of ZhouYi is the basest method among them. The article aimed at puting the Sieve Algorithm of ZhouYi into computer's using and predicting the simple information,conducting the result by researching the relationship between ZhouYi and Binary raised by Leibniz.

Key words:ZhouYi Eight Diagrams;Sieve forecast;Binary

1703年德国自然科学家莱布尼兹首次发现二进制,后来从传教士白晋信中获得有关《易经》和伏羲八卦的资料,从而正式发表关于二进制的论文。题目是“二进制位计算的阐述”,附题是“关于只用0与1兼用其用处及伏羲氏所用数字的意义”,莱布尼兹意料不到他发现的二进制会在中国的伏羲先天六十四卦图中早有表述和使用[1]。

老子说,道生一,一生二,二生三,三生万物,万物负阴而抱阳,冲气以为和[4]。这段话所指的,就是《易经》利用阴阳创造万物的基本思想与过程。现代计算机所应用的,正是宇宙创造万物的阴阳原理。在《周易》“系辞上传”中也记载有:“易有太极,是生两仪;两仪生四象,四象生八卦[5]”。可以这样解读:“宇宙混沌之初,产生阴阳二气,进而出现春夏秋冬四时,产生天、地、雷、风、水、火、山、泽等自然现象。”这里阳爻和阴爻合称两仪,每次取两爻共22=4种不同组合为之四象(少阳,太阳,少阴,太阴),每次取三爻共23=8种不同组合为之八卦(乾,坤,震,巽,坎,离,艮,兑),最后八卦俩俩组合成26=64种不同卦象[6]。……

登录APP查看全文