CN110138839B - Internet of things address fast searching method based on eight-Diagram-array binary tree arrangement of book of changes - Google Patents
Internet of things address fast searching method based on eight-Diagram-array binary tree arrangement of book of changes Download PDFInfo
- Publication number
- CN110138839B CN110138839B CN201910306459.7A CN201910306459A CN110138839B CN 110138839 B CN110138839 B CN 110138839B CN 201910306459 A CN201910306459 A CN 201910306459A CN 110138839 B CN110138839 B CN 110138839B
- Authority
- CN
- China
- Prior art keywords
- binary tree
- internet
- things
- array
- layer
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
- G06F16/953—Querying, e.g. by the use of web search engines
- G06F16/9537—Spatial or temporal dependent retrieval, e.g. spatiotemporal queries
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L61/00—Network arrangements, protocols or services for addressing or naming
- H04L61/09—Mapping addresses
- H04L61/25—Mapping addresses of the same type
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/12—Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks
Landscapes
- Engineering & Computer Science (AREA)
- Databases & Information Systems (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Theoretical Computer Science (AREA)
- Medical Informatics (AREA)
- General Health & Medical Sciences (AREA)
- Computing Systems (AREA)
- Data Mining & Analysis (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Health & Medical Sciences (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
Description
技术领域technical field
本发明涉及计算机网络领域中的物联网地址搜索领域,尤其涉及一种基于易经八卦阵二叉树排布的物联网地址快速搜索方法。The invention relates to the field of Internet of Things address search in the field of computer networks, in particular to a fast search method for Internet of Things addresses based on I Ching gossip array binary tree arrangement.
背景技术Background technique
《易经》是中华民族宝贵的文化遗产,其包含了上古时期人们对宇宙和人生社会的思想认识、哲学理念和辩证法。现代科学的许多重大发现和突破,如二进制、原子结构、生物遗传DNA等学科理念,都可以从八卦和六十四卦模型变化中发现与之对应的形态与哲学思维。The Book of Changes is a precious cultural heritage of the Chinese nation. It contains people's ideological understanding, philosophical concepts and dialectics of the universe and life society in ancient times. Many major discoveries and breakthroughs in modern science, such as binary, atomic structure, biological genetic DNA and other disciplinary concepts, can be found in the corresponding patterns and philosophical thinking from the changes in the gossip and sixty-four trigrams.
太极图卦爻画的变化是相对先天八卦的卦爻画而来的,其实质是想说明“阳长阴消,阴长阳消”及“重阴必阳,重阳必阴”的哲学思想。太极图的卦序:乾一,兑二,离三,震四,巽五,坎六,艮七,坤八。采用阿拉伯数字“0”和“1”从上而下代替“阴爻”和“阳爻”时,太极图的卦序也遵循二进制算法,从乾到坤遵循二进制加法,从坤到乾遵循二进制减法。The change of the hexagram and Yao painting of Taiji map is relative to the hexagram of innate gossip. The order of the hexagrams in the Tai Chi map: Gan 1, Dui 2, Li 3, Zhen 4, Xun 5, Kan 6, Gen 7, Kun 8. When the Arabic numerals "0" and "1" are used to replace "Yin Yao" and "Yang Yao" from top to bottom, the order of the hexagrams in the Taiji diagram also follows the binary algorithm, from Gan to Kun follows binary addition, and from Kun to Qian follows binary subtraction.
因此可以肯定的是,太极图的创作者看懂了先天八卦图中的二进制递进关系,从而有规律地重新排列了先天八卦的卦爻画的顺序(禅变卦爻符号顺序),重述了卦爻符号的二进制递进关系。直到莱布尼茨,《易经》这个迷才揭开了,即伏羲使用的两种线符,其实就是二进制的基本要素。太极图旁证了二进制亦是周易本义之一。Therefore, it is certain that the creator of Taijitu understood the binary progressive relationship in the innate gossip, and thus regularly rearranged the order of the congenital gossip (the order of the symbols of the Zen-changed trigrams), and restated the The binary progression relation of the hexagram and Yao symbols. It was not until Leibniz that the mystery of the "Book of Changes" was revealed, that is, the two symbols used by Fuxi were actually the basic elements of binary. The Taiji map provides circumstantial evidence that binary is also one of the original meanings of Zhouyi.
《易经》是我国古代现存最早的一部奇特的哲学专著。《易经》的卦爻符号是以阴爻和阳爻为基本符号构成的一个严整、有序的符号系统。现在令阳爻用阿拉伯数字“1”代替,阴爻用阿拉伯数字“0”代替,按卦爻规律,自下向上依次用“1”和“0”代替八卦图每卦中的“阳爻”和“阴爻”,即得到:乾卦为B0111,兑卦为B11l0,离卦为B1101,等等。The Book of Changes is the earliest extant philosophical monograph in ancient my country. The hexagram symbol of "Book of Changes" is a strict and orderly symbol system composed of yin and yang lines as the basic symbols. Now let the Yang Yao be replaced by the Arabic numeral "1", and the Yin Yao by the Arabic numeral "0". According to the rule of hexagrams, "1" and "0" are used to replace the "Yang Yao" in each hexagram of the Eight Diagrams from bottom to top. And "Yin Yao", namely: Qian Gua is B0111, Dui Gua is B11l0, Li Gua is B1101, and so on.
显然,远古时代八卦卦序遵循二进制算法,从乾一、兑二,到坤八遵循二进制加法。八卦两两相交便为六十四卦,六十四卦同样具备二进制算法的两种基本运算即加法与减法算术运算,因此六十四卦符号系统同样属于二进制算法。Obviously, the ancient gossip sequence followed the binary algorithm, from Gan Yi, Dui Er, to Kun Ba followed binary addition. The intersection of the eight trigrams is the sixty-four trigrams. The sixty-four trigrams also have two basic operations of binary arithmetic, namely addition and subtraction arithmetic operations, so the symbol system of the sixty-four trigrams also belongs to the binary arithmetic.
物联网提供了挖掘模糊大数据条件,大量的数据里面又包含海量的物联网信息传递,而模糊大数据中有很多信息是不精准的,这是由于人们所掌握的物联网大数据越来越多。但是这些整体数据却非常有价值,而使这些价值从冰山底层浮现出来的工具就是数据挖掘,比如应用正态分布这个统计学里的牛顿定律。通过海量的数据进行挖掘探索,实际上就是预测一种另外新意,这个预测新意如同《易经》中的象、数、理、占,通过太极、阴阳、五行、干支、八卦等一系列的范畴模式来推演,揭示事物本质的运动规律。The Internet of Things provides the conditions for mining fuzzy big data. A large amount of data contains a large amount of Internet of Things information transmission. However, a lot of information in fuzzy big data is inaccurate. many. But these overall data are very valuable, and the tools that make these values emerge from the bottom of the iceberg are data mining, such as applying Newton's law in statistics, the normal distribution. Mining and exploration through massive data is actually predicting a new meaning. This new meaning of forecasting is like the image, number, reason, and accounting in the "Book of Changes". Models are used to deduce and reveal the laws of motion of the essence of things.
如今在数据爆发式增长的时代,数据的量不是问题,重要的是要在茫茫数据中确定哪些维度的数据是所需要统计的。当数据量大了之后会出现各种各样看似都服从正态分布的数据,要有足够的分辨率才不会被数据所淹没,要分辨哪些是与通信行业有着潜在联系的,摆在面前至关重要的是物联网信息通讯,需要解决快速搜索物联网物理地址通讯问题。Today, in the era of explosive data growth, the amount of data is not a problem. What is important is to determine which dimensions of data need to be counted in the vast data. When the amount of data is large, there will be all kinds of data that seem to obey the normal distribution. There must be enough resolution to not be overwhelmed by the data. It is necessary to distinguish which ones are potentially related to the communication industry. The most important thing in front is the information communication of the Internet of Things, and it is necessary to solve the problem of quickly searching for the physical address communication of the Internet of Things.
现代科技进入到大数据物联网时代,物联网这个热词,与计算机嵌入式系统密切相关,物联网的大数据以几何级数增长,在科技太不发达、人类尚未开化的远古、上古时代,人类用八卦、河图洛书实现“物联网大数据”,现在用计算机做到“物联网大数据”信息通讯。用于存储大数据的“心”,实际上是人的大脑,现在交由计算机来做,计算机可以收集、处理、贮存如爆发性增长的信息。这些信息有可能为科学创造巨大的价值。Modern technology has entered the era of big data and the Internet of Things. The buzzword of the Internet of Things is closely related to computer embedded systems. The big data of the Internet of Things has grown exponentially. Humans use gossip and Hetu Luoshu to realize "Internet of Things big data", and now use computers to achieve "Internet of Things big data" information communication. The "heart" used to store big data is actually the human brain, which is now entrusted to computers, which can collect, process, and store information such as explosive growth. This information has the potential to create enormous value for science.
计算机嵌入式物联网系统应用领域包括:工业控制、医疗仪器、数字家庭、消费电子、汽车电子、无线通信、定位导航、智能机器人等领域。例如,冰箱、洗衣机等家电采用单片机组成嵌入式系统,通过物联网连接到手机或者服务器,实现远程控制家电。控制多个家电设备,搜索速度快,传输数据要少,要求性能可靠,成本低廉,这是成千上万嵌入式单片机控制方案。The application fields of computer-embedded Internet of Things systems include: industrial control, medical instruments, digital homes, consumer electronics, automotive electronics, wireless communications, positioning and navigation, intelligent robots and other fields. For example, home appliances such as refrigerators and washing machines use single-chip microcomputers to form embedded systems, which are connected to mobile phones or servers through the Internet of Things to realize remote control of home appliances. Controlling multiple home appliances requires fast search speed, less data transmission, reliable performance and low cost. This is a control scheme for thousands of embedded microcontrollers.
单片机的种类繁多,从低端到高端,有以51单片机为代表的8位单片机和以ARM为代表的32位单片机,不同档次的单片机实现网络接口的方法不同。对于像ARM等高端处理器一般都可以运行嵌入式操作系统,例如嵌入式Linux。对于无操作系统要求的单片机如何实现网络接入,下面将这些方案按TCP/IP协议栈的不同归结为两大类:第一类是传统的软件TCP/IP协议栈方案;第二类是最新的硬件TCP/IP协议栈方案。There are many types of single-chip microcomputers, from low-end to high-end, there are 8-bit single-chip microcomputers represented by 51 and 32-bit single-chip microcomputers represented by ARM. Different grades of single-chip microcomputers have different methods for implementing network interfaces. For high-end processors such as ARM, embedded operating systems, such as embedded Linux, can generally be run. As for how to implement network access for single-chip microcomputers without operating system requirements, these solutions can be classified into two categories according to the difference of TCP/IP protocol stacks: the first type is the traditional software TCP/IP protocol stack solution; the second type is the latest The hardware TCP/IP protocol stack solution.
物联网采用ZigBee协议,用普通单片机可以实现城际间网络通信,当然需要电信手机卡载荷实现广域互联网方案。ZigBee是WPAN网络,为近距离范围内的设备建立无线连接,把几米到几十米范围内的多个设备通过无线方式连接在一起,使他们可以相互通信甚至接入LAN或者Internet。通过手机电信卡,可以实现城际间物联网通讯。The Internet of Things adopts the ZigBee protocol, and the inter-city network communication can be realized by ordinary single-chip microcomputers. Of course, the telecommunications mobile phone card load is required to realize the wide-area Internet solution. ZigBee is a WPAN network that establishes a wireless connection for devices within a short range, and connects multiple devices within a range of several meters to tens of meters through wireless means, so that they can communicate with each other and even access the LAN or the Internet. Through the mobile phone telecommunication card, the inter-city Internet of Things communication can be realized.
ZigBee针对WPAN网络。致力于近距离、低复杂度、低数据速率、低成本的无线网络技术。ZigBee技术应用到商用电子、住宅及智能建筑、工业设备监测、PC外设、医疗传感设备、玩具以及游戏等其他无线传感和控制领域当中。ZigBee目标是能够建立基于互操作平台和配置文件的可伸缩、低成本嵌入式基础架构。ZigBee targets WPAN networks. Committed to short-range, low complexity, low data rate, low cost wireless network technology. ZigBee technology is used in commercial electronics, residential and intelligent buildings, industrial equipment monitoring, PC peripherals, medical sensing equipment, toys and games and other wireless sensing and control fields. The ZigBee goal is to be able to build scalable, low-cost embedded infrastructures based on interoperable platforms and profiles.
网卡物理地址MAC码是由TCP/IP协议全球惟一的一个固定地址来分配的,未经认证和授权的厂家无权生产网卡。每块网卡都有一个固定的卡号,并且任何正规厂家生产的网卡上都直接标明了卡号,一般为一组12位的16进制数。其中前6位代表网卡的生产厂商。The MAC code of the physical address of the network card is allocated by a unique fixed address in the world of the TCP/IP protocol. Manufacturers without certification and authorization have no right to produce network cards. Each network card has a fixed card number, and any network card produced by a regular manufacturer is directly marked with the card number, generally a group of 12-digit hexadecimal numbers. The first 6 digits represent the manufacturer of the network card.
发明内容SUMMARY OF THE INVENTION
本发明的目的在于提供一种基于易经八卦阵二叉树排布的物联网地址快速搜索方法。本发明能够用三步操作快速搜索链接单片机物理地址,通过单片机接口实现物联网通信。The purpose of the present invention is to provide a fast search method for Internet of Things addresses based on I Ching Bagua array binary tree arrangement. The invention can quickly search and link the physical address of the single-chip microcomputer with three-step operation, and realize the Internet of Things communication through the single-chip microcomputer interface.
本发明的目的能够通过以下技术方案实现:The object of the present invention can be realized through the following technical solutions:
一种基于易经八卦阵二叉树排布的物联网地址快速搜索方法,包括步骤:A method for quickly searching Internet of Things addresses based on I Ching gossip array binary tree arrangement, comprising the steps of:
构建易经八卦阵二叉树并按照易经八卦阵二叉树对物联网地址进行排布;Build the I-Ching Bagua Array binary tree and arrange the IoT addresses according to the I-Ching Bagua Array binary tree;
根据易经八卦阵二叉树搜索物联网地址,包括:Search IoT addresses according to the I Ching Bagua Array binary tree, including:
1、将物联网地址转化为二进制形式,判别物联网地址最后一位是奇数还是偶数;1. Convert the IoT address into binary form, and determine whether the last digit of the IoT address is odd or even;
2、从物联网地址位数判断地址对应在八卦阵二叉树中的层数;2. Judging the number of layers in the binary tree of the gossip array corresponding to the address from the number of IoT addresses;
3、根据八卦阵二叉树族类公式及对应层数确定所搜索的物理地址所在位置。3. Determine the location of the searched physical address according to the binary tree family formula of the Bagua array and the number of corresponding layers.
具体地,所述构建的易经八卦阵二叉树结构为:Specifically, the I Ching Bagua array binary tree structure constructed is:
八卦与数学中的二进制二叉树排布阵有关,六十四卦正是从0到63这64个自然数的完整二进制数组成八卦阵二叉树排布阵图:The gossip is related to the binary tree arrangement in mathematics. The sixty-four trigrams are exactly the complete binary numbers of the 64 natural numbers from 0 to 63 to form the gossip array binary tree arrangement diagram:
第一层是太极;第二层是两仪,(B10)代表阴、(B01)代表阳;第三层是四象,(B100)代表老阴、(B101)代表少阳、(B110)代表少阴、(B111)代表老阳;第四层是八卦,分别为坤(B1000)、艮(B1001)、坎(B1010)、巽(B1011)、震(B1100)、离(B1101)、兑(B1110)、乾(B1111);第五层是十六相数,分别从15(B01111)到30(B11110);第六层是三十二相数,分别从31(B011111)到62(B111110);第七层是六十四卦,分别从63(B0111111)到126(B1111110);B表示二进制。The first layer is Taiji; the second layer is Liangyi, (B10) represents Yin, (B01) represents Yang; the third layer is Sixiang, (B100) represents Laoyin, (B101) represents Shaoyang, (B110) represents Shaoyin and (B111) represent Laoyang; the fourth layer is gossip, which are Kun (B1000), Gen (B1001), Kan (B1010), Xun (B1011), Zhen (B1100), Li (B1101), Dui ( B1110), dry (B1111); the fifth layer is the number of sixteen phases, from 15 (B01111) to 30 (B11110); the sixth layer is the number of thirty-two phases, from 31 (B011111) to 62 (B111110) ; The seventh layer is the sixty-four hexagrams, from 63 (B0111111) to 126 (B1111110); B represents binary.
在本发明中,八卦阵二叉树物理地址查询区域由单片机和服务器点对点通信。每个设备都有一个确定的物理地址,物理地址跟随设备嵌入到单片机中,寻址范围由单片机内部寄存器地址发送,通过以太网通信连接到服务器,由企业的服务器点对点操控单片机,实现物联网查询到单片机实时监控设备。单片机物理地址是由二进制数值转换成Asics码进行传输。In the present invention, the physical address query area of the gossip array binary tree is communicated point-to-point by the single-chip microcomputer and the server. Each device has a definite physical address. The physical address follows the device and is embedded in the single-chip microcomputer. The addressing range is sent by the internal register address of the single-chip microcomputer. It is connected to the server through Ethernet communication. To the microcontroller real-time monitoring equipment. The physical address of the microcontroller is converted from binary values into Asics codes for transmission.
八卦阵二叉树二进制权值表如表1所示,在所述权值表中,层数(级数)是指对应2n幂指数的权值,称为n的幂指数范围,同时层数(级数)又是所在层的寻址范围。在八卦阵二叉树对应十进制数值中,物理地址寻址范围是以2n幂指数递增,例如n=6时,寻址从63至126绝对地址中寻址,这个地址一共有64个物理地址数值查找。The binary weight table of the binary tree of the Bagua Array is shown in Table 1. In the weight table, the number of layers (series) refers to the weight corresponding to the 2 n power exponent, which is called the range of the power exponent of n. At the same time, the number of layers ( series) is the addressing range of the layer in which it is located. In the octagram array binary tree corresponding to the decimal value, the physical address addressing range is incremented by the power of 2 n . For example, when n=6, the addressing is addressed from 63 to 126 absolute addresses, and this address has a total of 64 physical address values. .
表1Table 1
本发明可以推广到2n寻址范围,n趋于有限值,具体数值由单片机寻址物理地址位数决定。The present invention can be extended to 2 n addressing range, n tends to a finite value, and the specific value is determined by the number of physical address bits addressed by the single-chip microcomputer.
具体地,根据八卦阵二叉树排布阵可以推导出族类公式,族类公式有规律性:每扩展一层,会增加2n个族类,因此增加2n条族类公式,其中n对应层(级)权值。本发明中八卦阵二叉树排布族类公式与层(级)关系如表2所示,可延伸推出n层新增族类公式。Specifically, the family formula can be deduced according to the binary tree arrangement of the gossip array. The family formula has regularity: every time a layer is expanded, 2 n families will be added, so 2 n family formulas will be added, where n corresponds to the layer. (level) weight. In the present invention, the relationship between the family formula and the layer (level) of the binary tree arrangement of the Bagua array is shown in Table 2, and the new family formula of n layers can be extended.
表2Table 2
目前推导是N=6级,共推导64条族类公式。The current derivation is N=6 levels, and a total of 64 family formulas have been derived.
具体地,当n=6时,易经八卦阵二叉树有64个族类,因此所构建的易经八卦阵二叉树中的族类计算公式如下所示:Specifically, when n=6, the I Ching gossip array binary tree has 64 families, so the calculation formula of the families in the I Ching gossip array binary tree constructed is as follows:
按奇数和偶数分类排列Sort by odd and even numbers
奇数排列(按从左到右排列):Odd numbers (from left to right):
χ1=2n-1,n≥1χ 1 =2 n -1, n≥1
χ2=2n+1-33,n≥5χ 2 =2 n+1 -33, n≥5
χ3=2n+15,n≥5χ 3 =2 n +15, n≥5
χ4=2n+1-17,n≥4χ 4 =2 n+1 -17, n≥4
χ5=2n+7,n≥4χ 5 =2 n +7, n≥4
χ6=2n+1-25,n≥5χ 6 =2 n+1 -25, n≥5
χ7=2n+23,n≥5χ 7 =2 n +23, n≥5
χ8=2n+1-9,n≥3χ 8 =2 n+1 -9, n≥3
χ9=2n+3,n≥3χ 9 =2 n +3, n≥3
χ10=2n+1-29,n≥5χ 10 =2 n+1 -29, n≥5
χ11=2n+19,n≥5χ 11 =2 n +19, n≥5
χ12=2n+1-13,n≥4χ 12 =2 n+1 -13, n≥4
χ13=2n+11,n≥4χ 13 =2 n +11, n≥4
χ14=2n+1-21,n≥5χ 14 =2 n+1 -21, n≥5
χ15=2n+27,n≥5χ 15 =2 n +27, n≥5
χ16=2n+1-5,n≥2χ 16 =2 n+1 -5, n≥2
χ17=2n+1+1,n≥2χ 17 =2 n+1 +1, n≥2
χ18=2n+1-31,n≥5χ 18 =2 n+1 -31, n≥5
χ19=2n+17,n≥5χ 19 =2 n +17, n≥5
χ20=2n+1-15,n≥4χ 20 =2 n+1 -15, n≥4
χ21=2n+9,n≥4χ 21 =2 n +9, n≥4
χ22=2n+1-23,n≥5χ 22 =2 n+1 -23, n≥5
χ23=2n+25,n≥5χ 23 =2 n +25, n≥5
χ24=2n+1-7,n≥3χ 24 =2 n+1 -7, n≥3
χ25=2n+5,n≥3χ 25 =2 n +5, n≥3
χ26=2n+1-27,n≥5χ 26 =2 n+1 -27, n≥5
χ27=2n+21,n≥5χ 27 =2 n +21, n≥5
χ28=2n+1-11,n≥4χ 28 =2 n+1 -11, n≥4
χ29=2n+13,n≥4χ 29 =2 n +13, n≥4
χ30=2n+1-19,n≥5χ 30 =2 n+1 -19, n≥5
χ31=2n+29,n≥5χ 31 =2 n +29, n≥5
χ32=2n+1-3,n≥1χ 32 =2 n+1 -3, n≥1
偶数排列(按从左到右排列):Even numbers (from left to right):
χ33=2n+0,n≥1χ 33 =2 n +0, n≥1
χ34=2n+1-32,n≥5χ 34 =2 n+1 -32, n≥5
χ35=2n+16,n≥5χ 35 =2 n +16, n≥5
χ36=2n+1-16,n≥4χ 36 =2 n+1 -16, n≥4
χ37=2n+8,n≥4χ 37 =2 n +8, n≥4
χ38=2n+1-24,n≥5χ 38 =2 n+1 -24, n≥5
χ39=2n+1-24,n≥5χ 39 =2 n+1 -24, n≥5
χ40=2n+1-8,n≥3χ 40 =2 n+1 -8, n≥3
χ41=2n+4,n≥3χ 41 =2 n +4, n≥3
χ42=2n+1-28,n≥5χ 42 =2 n+1 -28, n≥5
χ43=2n+20,n≥5χ 43 =2 n +20, n≥5
χ44=2n+1-10,n≥4χ 44 =2 n+1 -10, n≥4
χ45=2n+12,n≥4χ 45 =2 n +12, n≥4
χ46=2n+1-20,n≥5χ 46 =2 n+1 -20, n≥5
χ47=2n+28,n≥5χ 47 =2 n +28, n≥5
χ48=2n+1-4,n≥2χ 48 =2 n+1 -4, n≥2
χ49=2n+2,n≥2χ 49 =2 n +2, n≥2
χ50=2n+130,n≥5χ 50 =2 n+1 30, n≥5
χ51=2n+18,n≥5χ 51 =2 n +18, n≥5
χ52=2n+1-16,n≥4χ 52 =2 n+1 -16, n≥4
χ53=2n+10,n≥4χ 53 =2 n +10, n≥4
χ54=2n+1-22,n≥5χ 54 =2 n+1 -22, n≥5
χ55=2n+26,n≥5χ 55 =2 n +26, n≥5
χ56=2n+1-6,n≥3χ 56 =2 n+1 -6, n≥3
χ57=2n+6,n≥3χ 57 =2 n +6, n≥3
χ58=2n+1-26,n≥5χ 58 =2 n+1 -26, n≥5
χ59=2n+22,n≥5χ 59 =2 n +22, n≥5
χ60=2n+1-12,n≥4χ 60 =2 n+1 -12, n≥4
χ61=2n+14,n≥4χ 61 =2 n +14, n≥4
χ62=2n+1-18,n≥5χ 62 =2 n+1 -18, n≥5
χ63=2n+30,n≥5χ 63 =2 n +30, n≥5
χ64=2n+1-2,n≥1χ 64 =2 n+1 -2, n≥1
其中,χi表示第i个族类所对应的计算公式,n表示层数(级数)。Among them, χ i represents the calculation formula corresponding to the ith family, and n represents the number of layers (series).
本发明相较于现有技术,具有以下的有益效果:Compared with the prior art, the present invention has the following beneficial effects:
1、为了解决物联网传输效率,本发明提出了用易经八卦阵二叉树排布方法快速搜索物联网,使得能够用三步操作快速便捷查找到单片机物理地址。1. In order to solve the transmission efficiency of the Internet of Things, the present invention proposes to use the I Ching Bagua array binary tree arrangement method to quickly search the Internet of Things, so that the physical address of the single-chip microcomputer can be quickly and conveniently found in three steps.
附图说明Description of drawings
图1是本发明中易经八卦阵二叉树的结构示意图。Fig. 1 is the structure schematic diagram of the I Ching gossip array binary tree in the present invention.
图2是本发明中易经八卦阵二叉树排布阵为奇数阵列的示意图。FIG. 2 is a schematic diagram of an odd-numbered array in which the I Ching Bagua array binary tree is arranged in an array according to the present invention.
图3是本发明中易经八卦阵二叉树排布阵为偶数阵列的示意图。FIG. 3 is a schematic diagram of an even-numbered array of the I Ching gossip array binary tree arrangement in the present invention.
具体实施方式Detailed ways
下面结合实施例及附图对本发明作进一步详细的描述,但本发明的实施方式不限于此。The present invention will be described in further detail below with reference to the embodiments and the accompanying drawings, but the embodiments of the present invention are not limited thereto.
实施例Example
一种基于易经八卦阵二叉树排布的物联网地址快速搜索方法,包括步骤:A method for quickly searching Internet of Things addresses based on I Ching gossip array binary tree arrangement, comprising the steps of:
构建易经八卦阵二叉树并按照易经八卦阵二叉树对物联网地址进行排布;Build the I-Ching Bagua Array binary tree and arrange the IoT addresses according to the I-Ching Bagua Array binary tree;
根据易经八卦阵二叉树搜索物联网地址,包括:Search IoT addresses according to the I Ching Bagua Array binary tree, including:
1、将物联网地址转化为二进制形式,判别物联网地址最后一位是奇数还是偶数;1. Convert the IoT address into binary form, and determine whether the last digit of the IoT address is odd or even;
2、从物联网地址位数判断地址对应在八卦阵二叉树中的层数;2. Judging the number of layers in the binary tree of the gossip array corresponding to the address from the number of IoT addresses;
3、根据八卦阵二叉树族类公式及对应层数确定所搜索的物理地址所在位置。3. Determine the location of the searched physical address according to the binary tree family formula of the Bagua array and the number of corresponding layers.
在本实施例中,构建的易经八卦阵二叉树结构如图1所示,具体为:In this embodiment, the constructed I Ching Bagua array binary tree structure is shown in Figure 1, specifically:
八卦与数学中的二进制二叉树排布阵有关,六十四卦正是从0到63这64个自然数的完整二进制数组成八卦阵二叉树排布阵图:The gossip is related to the binary tree arrangement in mathematics. The sixty-four trigrams are exactly the complete binary numbers of the 64 natural numbers from 0 to 63 to form the gossip array binary tree arrangement diagram:
第一层是太极;第二层是两仪,(B10)代表阴、(B01)代表阳;第三层是四象,(B100)代表老阴、(B101)代表少阳、(B110)代表少阴、(B111)代表老阳;第四层是八卦,分别为坤(B1000)、艮(B1001)、坎(B1010)、巽(B1011)、震(B1100)、离(B1101)、兑(B1110)、乾(B1111);第五层是十六相数,分别从15(B01111)到30(B11110);第六层是三十二相数,分别从31(B011111)到62(B111110);第七层是六十四卦,分别从63(B0111111)到126(B1111110)。The first layer is Taiji; the second layer is Liangyi, (B10) represents Yin, (B01) represents Yang; the third layer is Sixiang, (B100) represents Laoyin, (B101) represents Shaoyang, (B110) represents Shaoyin and (B111) represent Laoyang; the fourth layer is gossip, which are Kun (B1000), Gen (B1001), Kan (B1010), Xun (B1011), Zhen (B1100), Li (B1101), Dui ( B1110), dry (B1111); the fifth layer is the number of sixteen phases, from 15 (B01111) to 30 (B11110); the sixth layer is the number of thirty-two phases, from 31 (B011111) to 62 (B111110) ; The seventh layer is the sixty-four hexagrams, from 63 (B0111111) to 126 (B1111110).
所述易经八卦阵二叉树的奇数阵列和偶数阵列的结构分别如图2和图3所示。The structures of the odd-numbered array and the even-numbered array of the I Ching gossip array binary tree are respectively shown in FIG. 2 and FIG. 3 .
具体地,根据八卦阵二叉树排布阵可以推导出族类公式,族类公式有规律性:每扩展一层,会增加2n个族类,因此增加2n条族类公式,其中n对应层(级)权值。本发明中八卦阵二叉树排布族类公式与层(级)关系如表2所示,可延伸推出n层新增族类公式。Specifically, the family formula can be deduced according to the binary tree arrangement of the gossip array. The family formula has regularity: every time a layer is expanded, 2 n families will be added, so 2 n family formulas will be added, where n corresponds to the layer. (level) weight. In the present invention, the relationship between the family formula and the layer (level) of the binary tree arrangement of the Bagua array is shown in Table 2, and the new family formula of n layers can be extended.
目前推导是N=6级,共推导64条族类公式。The current derivation is N=6 levels, and a total of 64 family formulas have been derived.
具体地,当n=6时,易经八卦阵二叉树有64个族类,因此所构建的易经八卦阵二叉树中的族类计算公式如下所示:Specifically, when n=6, the I Ching gossip array binary tree has 64 families, so the calculation formula of the families in the I Ching gossip array binary tree constructed is as follows:
按奇数和偶数分类排列Sort by odd and even numbers
奇数排列(按从左到右排列):Odd numbers (from left to right):
χ1=2n-1,n≥1χ 1 =2 n -1, n≥1
χ2=2n+1-33,n≥5χ 2 =2 n+1 -33, n≥5
χ3=2n+15,n≥5χ 3 =2 n +15, n≥5
χ4=2n+1-17,n≥4χ 4 =2 n+1 -17, n≥4
χ5=2n+7,n≥4χ 5 =2 n +7, n≥4
χ6=2n+1-25,n≥5χ 6 =2 n+1 -25, n≥5
χ7=2n+23,n≥5χ 7 =2 n +23, n≥5
χ8=2n+1-9,n≥3χ 8 =2 n+1 -9, n≥3
χ9=2n+3,n≥3χ 9 =2 n +3, n≥3
χ10=2n+1-29,n≥5χ 10 =2 n+1 -29, n≥5
χ11=2n+19,n≥5χ 11 =2 n +19, n≥5
χ12=2n+1-13,n≥4χ 12 =2 n+1 -13, n≥4
χ13=2n+11,n≥4χ 13 =2 n +11, n≥4
χ14=2n+1-21,n≥5χ 14 =2 n+1 -21, n≥5
χ15=2n+27,n≥5χ 15 =2 n +27, n≥5
χ16=2n+1-5,n≥2χ 16 =2 n+1 -5, n≥2
χ17=2n+1+1,n≥2χ 17 =2 n+1 +1, n≥2
χ18=2n+1-31,n≥5χ 18 =2 n+1 -31, n≥5
χ19=2n+17,n≥5χ 19 =2 n +17, n≥5
χ20=2n+1-15,n≥4χ 20 =2 n+1 -15, n≥4
χ21=2n+9,n≥4χ 21 =2 n +9, n≥4
χ22=2n+1-23,n≥5χ 22 =2 n+1 -23, n≥5
χ23=2n+25,n≥5χ 23 =2 n +25, n≥5
χ24=2n+1-7,n≥3χ 24 =2 n+1 -7, n≥3
χ25=2n+5,n≥3χ 25 =2 n +5, n≥3
χ26=2n+1-27,n≥5χ 26 =2 n+1 -27, n≥5
χ27=2n+21,n≥5χ 27 =2 n +21, n≥5
χ28=2n+1-11,n≥4χ 28 =2 n+1 -11, n≥4
χ29=2n+13,n≥4χ 29 =2 n +13, n≥4
χ30=2n+1-19,n≥5χ 30 =2 n+1 -19, n≥5
χ31=2n+29,n≥5χ 31 =2 n +29, n≥5
χ32=2n+1-3,n≥1χ 32 =2 n+1 -3, n≥1
偶数排列(按从左到右排列):Even numbers (from left to right):
χ33=2n+0,n≥1χ 33 =2 n +0, n≥1
χ34=2n+1-32,n≥5χ 34 =2 n+1 -32, n≥5
χ35=2n+16,n≥5χ 35 =2 n +16, n≥5
χ36=2n+1-16,n≥4χ 36 =2 n+1 -16, n≥4
χ37=2n+8,n≥4χ 37 =2 n +8, n≥4
χ38=2n+1-24,n≥5χ 38 =2 n+1 -24, n≥5
χ39=2n+1-24,n≥5χ 39 =2 n+1 -24, n≥5
χ40=2n+1-8,n≥3χ 40 =2 n+1 -8, n≥3
χ41=2n+4,n≥3χ 41 =2 n +4, n≥3
χ42=2n+1-28,n≥5χ 42 =2 n+1 -28, n≥5
χ43=2n+20,n≥5χ 43 =2 n +20, n≥5
χ44=2n+1-10,n≥4χ 44 =2 n+1 -10, n≥4
χ45=2n+12,n≥4χ 45 =2 n +12, n≥4
χ46=2n+1-20,n≥5χ 46 =2 n+1 -20, n≥5
χ47=2n+28,n≥5χ 47 =2 n +28, n≥5
χ48=2n+1-4,n≥2χ 48 =2 n+1 -4, n≥2
χ49=2n+2,n≥2χ 49 =2 n +2, n≥2
χ50=2n+130,n≥5χ 50 =2 n+1 30, n≥5
χ51=2n+18,n≥5χ 51 =2 n +18, n≥5
χ52=2n+1-16,n≥4χ 52 =2 n+1 -16, n≥4
χ53=2n+10,n≥4χ 53 =2 n +10, n≥4
χ54=2n+1-22,n≥5χ 54 =2 n+1 -22, n≥5
χ55=2n+26,n≥5χ 55 =2 n +26, n≥5
χ56=2n+1-6,n≥3χ 56 =2 n+1 -6, n≥3
χ57=2n+6,n≥3χ 57 =2 n +6, n≥3
χ58=2n+1-26,n≥5χ 58 =2 n+1 -26, n≥5
χ59=2n+22,n≥5χ 59 =2 n +22, n≥5
χ60=2n+1-12,n≥4χ 60 =2 n+1 -12, n≥4
χ61=2n+14,n≥4χ 61 =2 n +14, n≥4
χ62=2n+1-18,n≥5χ 62 =2 n+1 -18, n≥5
χ63=2n+30,n≥5χ 63 =2 n +30, n≥5
χ64=2n+1-2,n≥1χ 64 =2 n+1 -2, n≥1
其中,χi表示第i个族类所对应的计算公式,n表示层数(级数)。Among them, χ i represents the calculation formula corresponding to the ith family, and n represents the number of layers (series).
在本实施例中,把239转换成二进制,239=B11101111,(1)因为末尾是奇数,绝对地址在“八卦阵二叉树总图”左边;(2)B11101111二进制是8位,在第7层,取n=7。奇数公式中选择“按层(N级)分类排列”取N=4,在16条公式中选公式(17),χ4=2n+1-17,n≥4………(17),把n=7代入公式(17),计算结果是239。解析:公式(17)是在第4层建立,按照族类可以看出有数据:15=B01111;47=B101111;111=B1101111;239=B11101111…,这些数值代入公式(17)均满足公式要求,从这些数据可以看出,B01111是族类的二进制数据都相同,加一层前面数字加1,加二层前面数据加11,以此类推,加n层前面数据加n个1,这就是递推公式规律,按递推公式查找物理地址,只要给出二进制位数,末尾奇偶数,就可以确定物理地址的层数和位置,对嵌入式芯片物理地址查找方便快捷。In this embodiment, 239 is converted into binary, 239=B11101111, (1) because the end is an odd number, the absolute address is on the left side of the “Bagua Array Binary Tree General Map”; (2) B11101111 binary is 8 bits, in the seventh layer, Take n=7. In the odd-numbered formula, choose "sort by layer (N-level)" to take N=4, choose formula (17) among the 16 formulas, χ 4 =2 n+1 -17, n≥4......(17), put Substitute n=7 into formula (17), and the calculation result is 239. Analysis: Formula (17) is established in the fourth layer. According to the family, it can be seen that there are data: 15=B01111; 47=B101111; 111=B1101111; , from these data, it can be seen that B01111 is the same family of binary data, add the number in front of one layer and add 1, add the data in front of the second layer and add 11, and so on. According to the recursive formula law, the physical address is searched according to the recursive formula. As long as the binary digits and the odd and even numbers at the end are given, the layer number and position of the physical address can be determined, and the physical address search of the embedded chip is convenient and fast.
上述实施例为本发明较佳的实施方式,但本发明的实施方式并不受上述实施例的限制,其他的任何未背离本发明的精神实质与原理下所作的改变、修饰、替代、组合、简化,均应为等效的置换方式,都包含在本发明的保护范围之内。The above-mentioned embodiments are preferred embodiments of the present invention, but the embodiments of the present invention are not limited by the above-mentioned embodiments, and any other changes, modifications, substitutions, combinations, The simplification should be equivalent replacement manners, which are all included in the protection scope of the present invention.
Claims (1)
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201910306459.7A CN110138839B (en) | 2019-04-17 | 2019-04-17 | Internet of things address fast searching method based on eight-Diagram-array binary tree arrangement of book of changes |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201910306459.7A CN110138839B (en) | 2019-04-17 | 2019-04-17 | Internet of things address fast searching method based on eight-Diagram-array binary tree arrangement of book of changes |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| CN110138839A CN110138839A (en) | 2019-08-16 |
| CN110138839B true CN110138839B (en) | 2020-08-18 |
Family
ID=67570093
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN201910306459.7A Active CN110138839B (en) | 2019-04-17 | 2019-04-17 | Internet of things address fast searching method based on eight-Diagram-array binary tree arrangement of book of changes |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN110138839B (en) |
Families Citing this family (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN110390128B (en) * | 2019-06-10 | 2022-03-29 | 华南理工大学 | Three-step rapid address searching construction method for arrangement of binary tree in eight-Diagram array of book of changes |
| CN112787898B (en) * | 2020-12-29 | 2022-03-04 | 美的集团股份有限公司 | Device data communication method, device, electronic device and storage medium |
Citations (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US6697103B1 (en) * | 1998-03-19 | 2004-02-24 | Dennis Sunga Fernandez | Integrated network for monitoring remote objects |
| CN107741881A (en) * | 2017-11-02 | 2018-02-27 | 吉林大学 | Fast Calculation Method of Zernike Moment Based on GPU |
Family Cites Families (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101370023A (en) * | 2007-08-15 | 2009-02-18 | 凤凰微电子(中国)有限公司 | WAP website connection method |
-
2019
- 2019-04-17 CN CN201910306459.7A patent/CN110138839B/en active Active
Patent Citations (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US6697103B1 (en) * | 1998-03-19 | 2004-02-24 | Dennis Sunga Fernandez | Integrated network for monitoring remote objects |
| CN107741881A (en) * | 2017-11-02 | 2018-02-27 | 吉林大学 | Fast Calculation Method of Zernike Moment Based on GPU |
Also Published As
| Publication number | Publication date |
|---|---|
| CN110138839A (en) | 2019-08-16 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN103473334B (en) | Data storage method, inquiry method and system | |
| CN110138839B (en) | Internet of things address fast searching method based on eight-Diagram-array binary tree arrangement of book of changes | |
| CN1139027C (en) | Systems and methods for intermittently communicating diagnostic information from user input devices | |
| US20140074819A1 (en) | Optimal Data Representation and Auxiliary Structures For In-Memory Database Query Processing | |
| CN111914470B (en) | Multi-element monitoring time series regression prediction method for energy chemical production system | |
| CN104980440B (en) | Big data transmission method for active distribution network based on content filtering and multi-agent cooperation | |
| Qi et al. | Using Huffman coding method to visualize and analyze DNA sequences | |
| CN113870046A (en) | Power equipment fault diagnosis method and equipment | |
| CN113704616B (en) | Information pushing method and device, electronic equipment and readable storage medium | |
| CN118585341A (en) | A cloud computing resource scheduling method, system, device and medium based on enhanced Cougar optimization algorithm | |
| WO2023202149A1 (en) | State selection method and system for finite state entropy encoding, and storage medium and device | |
| CN112883651A (en) | System-level testability design multi-objective optimization method based on improved PBI method | |
| CN109165006A (en) | The design optimization and hardware implementation method and system of Softmax function | |
| CN112101612A (en) | Prediction method of town gas usage, storage medium and terminal equipment | |
| CN113791756B (en) | Revolution method, storage medium, device and board | |
| CN110390128A (en) | A Construction Method of Binary Tree Arrangement Array Based on I Ching Bagua Array | |
| US11748255B1 (en) | Method for searching free blocks in bitmap data, and related components | |
| CN113761300B (en) | Message sampling method, device, equipment and medium based on bitmap calculation | |
| CN115687344A (en) | Acceleration device and acceleration method based on FPGA-based perfect hash construction | |
| CN209895329U (en) | multiplier | |
| Li et al. | Decentralized online learning with compressed communication for near-sensor data analytics | |
| CN117596066A (en) | A lightweight IoT zombie host detection method based on second-level domain names | |
| CN118555142B (en) | Multi-interface data processing method and system based on FPGA | |
| CN115759236B (en) | Model training method, information sending method, device, equipment and medium | |
| CN118862016A (en) | A symbolic regression method based on multi-form genetic programming |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| GR01 | Patent grant | ||
| GR01 | Patent grant |