发明名称 基于能量梯度和APIT网格的GPSR路由算法
摘要 本发明涉及一种基于能量梯度和APIT网格的GPSR路由算法,其特征在于:汇聚节点在平面直角坐标系X轴和Y轴上的位置为(1000,1000);无线传感器节点组包括300个无线传感器节点(后简称“节点”),分别用Node(                                                <img file="948578dest_path_image001.GIF" wi="8" he="16" />)表示,<img file="993894dest_path_image001.GIF" wi="8" he="16" />=1,2,…,300;无线传感器节点组中有N个节点分布在400*400的事件区域中,事件区域在平面直角坐标系上对应的x轴和y轴范围分别为0~400和0~400。其改善热点路由造成的网络节点能耗不均的问题,通过预先设定节点能量阈值来减少全网节点死亡数,从而延长整个网络生命周期,提高数据传输效率。
申请公布号 CN104754685A 申请公布日期 2015.07.01
申请号 CN201510181816.3 申请日期 2015.04.17
申请人 长春理工大学 发明人 冯欣;刘壮;张昕;张剑飞;韩成;张晶晶;李腾;王雁龙;杨文龙
分类号 H04W40/10(2009.01)I;H04W40/24(2009.01)I 主分类号 H04W40/10(2009.01)I
代理机构 吉林长春新纪元专利代理有限责任公司 22100 代理人 王薇
主权项 基于能量梯度和APIT网格的GPSR路由算法,包括汇聚节点,无线传感器节点组,其特征在于:汇聚节点在平面直角坐标系X轴和Y轴上的位置为(1000,1000);无线传感器节点组包括300个无线传感器节点(后简称“节点”),分别用Node(<img file="81393dest_path_image001.GIF" wi="8" he="16" />)表示,<img file="282567dest_path_image001.GIF" wi="8" he="16" />=1,2,…,300;Node(<img file="865995dest_path_image001.GIF" wi="8" he="16" />)随机分布在1000*1000的网络区域中,(<img file="381290dest_path_image002.GIF" wi="45" he="32" />)表示Node(<img file="163301dest_path_image001.GIF" wi="8" he="16" />)在平面直角坐标系上的x轴和y轴坐标;无线传感器节点组中有N个节点分布在400*400的事件区域中,事件区域在平面直角坐标系上对应的x轴和y轴范围分别为0~400和0~400;无线传感器节点组中的300个节点和汇聚节点1的通信半径均为250;其具体的实现步骤如下:1)、对于无线传感器节点Node(<img file="473060dest_path_image001.GIF" wi="8" he="16" />),它的初始能量用<img file="606101dest_path_image003.GIF" wi="48" he="24" />表示,当前能量用<img file="659508dest_path_image004.GIF" wi="75" he="24" />表示,功率放大器的能耗用<img file="561604dest_path_image005.GIF" wi="53" he="24" />表示,自由空间消耗的能量用<img file="42264dest_path_image006.GIF" wi="41" he="24" />表示,发射电路消耗的能量用<img file="662602dest_path_image007.GIF" wi="57" he="24" />表示,<img file="254120dest_path_image001.GIF" wi="8" he="16" />=1,2,…,300;2)、汇聚节点1将自己在平面直角坐标系下的x轴和y轴坐标发送给无线传感器节点组中的300个节点,无线传感器节点组中300个节点记录汇聚节点的x轴和y轴坐标;3)、对于事件区域中N个节点,用<img file="948406dest_path_image008.GIF" wi="63" he="24" />表示,<img file="924934dest_path_image009.GIF" wi="11" he="16" />=1,2,…N,(<img file="704671dest_path_image010.GIF" wi="48" he="32" />)表示节点Event(<img file="99880dest_path_image009.GIF" wi="11" he="16" />)在平面直角坐标系上的x轴坐标和y轴坐标;根据公式<img file="976570dest_path_image011.GIF" wi="281" he="42" />计算<img file="799032dest_path_image008.GIF" wi="63" he="24" />到汇聚节点1的距离<img file="128382dest_path_image012.GIF" wi="75" he="32" />表示,<img file="327282dest_path_image009.GIF" wi="11" he="16" />=1,2,…N;将<img file="996161dest_path_image013.GIF" wi="27" he="16" />(<img file="51842dest_path_image009.GIF" wi="11" he="16" />)按照数值从小到大排序并形成<img file="806171dest_path_image009.GIF" wi="11" he="16" />所对应的点集队列Queue(<i>l</i>),<i>l</i>=1,2,…,N;将Queue中Queue(1)作为目的节点,记该点为D,<img file="543183dest_path_image014.GIF" wi="64" he="32" />表示目的节点D在平面直角坐标系下的x轴坐标和y轴坐标;4)、将汇聚节点1作为其到目的节点D的查询路径R的起点,记为节点R(1),无线传感器网络中将非事件区域300‑N个节点随机排列,构成非事件区域节点组,非事件区域节点组中的节点用Point<img file="128885dest_path_image015.GIF" wi="23" he="24" />表示,<img file="558730dest_path_image016.GIF" wi="9" he="16" />=1,2,…,300‑N<i>,</i>(<img file="800355dest_path_image017.GIF" wi="48" he="32" />)表示非事件区域节点组Point<img file="137795dest_path_image018.GIF" wi="295" he="32" />;根据公式<img file="781266dest_path_image019.GIF" wi="270" he="42" />计算Point<img file="178750dest_path_image015.GIF" wi="23" he="24" />到汇聚节点1的距离<img file="907671dest_path_image020.GIF" wi="41" he="24" />,z=1,2,…,300‑N,设满足<img file="986486dest_path_image020.GIF" wi="41" he="24" />≤250的非事件区域节点组中的节点有M个,用Neighbor1 (<img file="546780dest_path_image021.GIF" wi="12" he="24" />)表示,<img file="318427dest_path_image021.GIF" wi="12" he="24" />=1,2,…,M,(<img file="269065dest_path_image022.GIF" wi="48" he="32" />)表示Neighbor1(<img file="216817dest_path_image021.GIF" wi="12" he="24" />)在平面直角坐标系上的x轴和y轴坐标,根据公式<img file="569301dest_path_image023.GIF" wi="246" he="42" />计算<img file="511850dest_path_image024.GIF" wi="48" he="24" />,<img file="12101dest_path_image021.GIF" wi="12" he="24" />=1,2,…,M,如果<img file="432718dest_path_image025.GIF" wi="60" he="24" />是<img file="905288dest_path_image026.GIF" wi="48" he="32" />最小数值,那么Neighbor1 (<img file="81054dest_path_image027.GIF" wi="16" he="24" />)作为查询路径R的第二个节点用R(2)表示,在平面直角坐标系上的x轴和y轴坐标为(<img file="6285dest_path_image028.GIF" wi="69" he="32" />);5)、根据公式<img file="230593dest_path_image029.GIF" wi="252" he="42" />计算Point<img file="354407dest_path_image015.GIF" wi="23" he="24" />到R(2)的距离<img file="638757dest_path_image030.GIF" wi="41" he="24" />,z=1,2,…,300‑N,设满足<img file="113601dest_path_image030.GIF" wi="41" he="24" />≤250m的非事件区域节点组中的节点有L个,用Neighbor2(<img file="141600dest_path_image031.GIF" wi="9" he="16" />)表示,<img file="385499dest_path_image031.GIF" wi="9" he="16" />=1,2,…,L,(<img file="575172dest_path_image032.GIF" wi="45" he="32" />)表示Neighbor2(<img file="474995dest_path_image031.GIF" wi="9" he="16" />)在平面直角坐标系上的x轴和y轴坐标,根据公式<img file="103423dest_path_image033.GIF" wi="239" he="42" />计算<img file="405091dest_path_image034.GIF" wi="48" he="24" />,<img file="765665dest_path_image031.GIF" wi="9" he="16" />=1,2,…,L,如果<img file="215101dest_path_image035.GIF" wi="57" he="24" />是<img file="584903dest_path_image036.GIF" wi="29" he="16" />中最小数值,那么Neighbor2(<img file="475498dest_path_image037.GIF" wi="15" he="16" />)作为查询路径R的第三个节点R(3);6)、重复步骤5,寻找查询路径R中的节点R (a),<img file="355378dest_path_image038.GIF" wi="69" he="24" />,R(<img file="964213dest_path_image039.GIF" wi="11" he="24" />)为目的节点D时,产寻结束,查询路径R长<img file="200023dest_path_image039.GIF" wi="11" he="24" />,共有<img file="210704dest_path_image039.GIF" wi="11" he="24" />个节点,依次为R (1),R (2),…,R(<img file="178660dest_path_image039.GIF" wi="11" he="24" />);7)、事件区域中除目的节点D外剩余N‑1个节点,构成非目的节点组,非目的节点组中的节点用U_D<img file="337109dest_path_image040.GIF" wi="24" he="24" />表示,k=1,2,…,N‑1,<img file="48713dest_path_image041.GIF" wi="63" he="32" />表示非目的节点组U_D<img file="913901dest_path_image042.GIF" wi="296" he="32" />,根据公式<img file="115075dest_path_image043.GIF" wi="246" he="42" />计算<img file="698503dest_path_image044.GIF" wi="48" he="24" />,k=1,2,…,N‑1;8)、目的节点D将汇聚节点1沿查询路径R传来的数据洪泛传给非目的节点组U_D<img file="948219dest_path_image040.GIF" wi="24" he="24" />中的N‑1个节点,根据公式<img file="995809dest_path_image045.GIF" wi="285" he="42" />式中,<img file="305568dest_path_image046.GIF" wi="12" he="16" />的值为大于等于3000且小于等于4000的整数,计算目的节点D到非目的节点组中N‑1个节点消耗的能量,用<img file="376292dest_path_image047.GIF" wi="64" he="24" />表示,k=1,2,…,N‑1;根据公式<img file="492016dest_path_image048.GIF" wi="302" he="21" />计算目的节点D当前剩余能量,用<img file="331796dest_path_image049.GIF" wi="79" he="24" />表示,式中<img file="874772dest_path_image050.GIF" wi="12" he="24" />=1,2,…N‑1;9)、根据公式<img file="167213dest_path_image051.GIF" wi="285" he="42" />式中,<img file="24311dest_path_image046.GIF" wi="12" he="16" />的值为大于等于3000且小于等于4000的整数,计算事件区域中N‑1个节点每个节点到目的节点D的能量消耗,用<img file="780914dest_path_image052.GIF" wi="64" he="24" />表示,<img file="432476dest_path_image050.GIF" wi="12" he="24" />=1,2,…,N‑1;根据公式<img file="477792dest_path_image053.GIF" wi="231" he="21" />计算事件区域中N‑1个节点中每个节点当前剩余能量,用<img file="938248dest_path_image054.GIF" wi="77" he="24" />表示,<img file="487041dest_path_image050.GIF" wi="12" he="24" />=1,2,…,N‑1;10)、将查询路径R中<img file="575083dest_path_image039.GIF" wi="11" he="24" />个节点从后往前重新排列,构成反向路径R’,R’(1)= R(<img file="904433dest_path_image039.GIF" wi="11" he="24" />), R’(2)= R(<img file="103333dest_path_image055.GIF" wi="37" he="24" />),…, R’(<i>b</i>)= R(<img file="568949dest_path_image056.GIF" wi="6" he="32" />);目的节点D把收集到的数据沿反向路径R’传送到汇聚节点,反向路径R’的起点R’(1)为事件区域中目的节点D,终点R’(<img file="827892dest_path_image057.GIF" wi="12" he="24" />)是汇聚节点,R’中的各节点在平面直角坐标系上的坐标用(<img file="582222dest_path_image058.GIF" wi="53" he="32" />)表示,<img file="381551dest_path_image059.GIF" wi="11" he="16" />=1,2,…,<img file="904936dest_path_image039.GIF" wi="11" he="24" />;11)、根据公式<img file="334780dest_path_image060.GIF" wi="266" he="42" />式中,s=1,2,…,<img file="373143dest_path_image061.GIF" wi="13" he="16" />‑1,计算反向路径R’中每两个节点之间的距离,用<img file="913846dest_path_image062.GIF" wi="47" he="24" />表示,<img file="557317dest_path_image059.GIF" wi="11" he="16" />=1,2,…,<img file="954800dest_path_image061.GIF" wi="13" he="16" />‑1;12)、根据公式<img file="683722dest_path_image063.GIF" wi="279" he="42" />式中,<img file="824853dest_path_image046.GIF" wi="12" he="16" />的值为大于等于3000且小于等于4000的整数,计算反向查询路径R’中每个节点的能量消耗,用<img file="322831dest_path_image064.GIF" wi="61" he="24" />表示,<img file="828898dest_path_image059.GIF" wi="11" he="16" />=1,2,…,<img file="107433dest_path_image061.GIF" wi="13" he="16" />‑1;根据公式<img file="989938dest_path_image065.GIF" wi="225" he="21" />计算反向查询路径R’中每个节点当前剩余能量,用<img file="401809dest_path_image066.GIF" wi="76" he="24" />表示,<img file="344358dest_path_image059.GIF" wi="11" he="16" />=1,2,…,<img file="782292dest_path_image061.GIF" wi="13" he="16" />‑1;13)、依次重复步骤10~12,直到至少出现以下两种情况中的一个:(1)如果事件区域中的目的节点D当前剩余能量<img file="265226dest_path_image049.GIF" wi="79" he="24" />小于等于0,从Queue中选择Queue(<i>l</i>+1)代替原来的目的节点D,<i>l</i>=1,2,…,N‑1;用节点Queue(<i>l</i>+1)的坐标代替原目的节点的坐标<img file="800113dest_path_image014.GIF" wi="64" he="32" />;(2)对反向路径R’中的每个节点设定能量阈值0.2,如果反向路径R’中的某一个节点剩余能量<img file="647983dest_path_image066.GIF" wi="76" he="24" />小于等于0.2,该节点记为R’(<img file="635531dest_path_image067.GIF" wi="12" he="16" />)(<img file="859838dest_path_image068.GIF" wi="11" he="16" />为1~<img file="186915dest_path_image061.GIF" wi="13" he="16" />‑1中的一个值);以节点R’(<img file="533582dest_path_image067.GIF" wi="12" he="16" />)为顶点,节点R’(<img file="946109dest_path_image067.GIF" wi="12" he="16" />)与节点R’(<img file="708529dest_path_image069.GIF" wi="37" he="16" />)的连线为边,用[R’(<img file="952428dest_path_image067.GIF" wi="12" he="16" />)<img file="407680dest_path_image070.GIF" wi="6" he="16" />R’(<img file="307503dest_path_image069.GIF" wi="37" he="16" />)]表示;右手伸开,掌心向上,大拇指指向边[R’(<img file="935931dest_path_image067.GIF" wi="12" he="16" />)<img file="972020dest_path_image070.GIF" wi="6" he="16" />R’(<img file="598173dest_path_image069.GIF" wi="37" he="16" />)]的方向,从四指的方向上找到H个节点,用A(<img file="47609dest_path_image071.GIF" wi="12" he="16" />)表示,<img file="151831dest_path_image071.GIF" wi="12" he="16" />=1,2,…,H;根据公式<img file="373253dest_path_image072.GIF" wi="272" he="42" />式中,(<img file="170308dest_path_image073.GIF" wi="80" he="32" />)表示节点R’(<img file="779143dest_path_image069.GIF" wi="37" he="16" />)在平面坐标系上的x轴和y轴坐标,(<img file="14953dest_path_image074.GIF" wi="48" he="32" />)表示节点组A(<img file="25634dest_path_image071.GIF" wi="12" he="16" />)中每个节点在平面坐标系上的x轴和y轴坐标;计算节点组A(<img file="993590dest_path_image071.GIF" wi="12" he="16" />)到节点R’(<img file="152039dest_path_image069.GIF" wi="37" he="16" />)的距离,用<img file="598064dest_path_image075.GIF" wi="45" he="24" />表示,<img file="728831dest_path_image071.GIF" wi="12" he="16" />=1,2,…,H;选择<img file="930005dest_path_image075.GIF" wi="45" he="24" />中数值最小的节点,用a表示;将节点a更新顶点R’(<img file="513433dest_path_image067.GIF" wi="12" he="16" />),顶点R’(<img file="825466dest_path_image067.GIF" wi="12" he="16" />)更新节点R’(<img file="810739dest_path_image069.GIF" wi="37" he="16" />),节点a与节点R’(<img file="120498dest_path_image067.GIF" wi="12" he="16" />)的连线作为边更新边[R’(<img file="253539dest_path_image067.GIF" wi="12" he="16" />)<img file="306946dest_path_image070.GIF" wi="6" he="16" />R’(<img file="146726dest_path_image069.GIF" wi="37" he="16" />)],用上面同样的方法找下一个点,依次找点并连线,直到找到的点连线围成一个多边形T,从节点R’(<img file="689702dest_path_image069.GIF" wi="37" he="16" />)开始,顺时针遍历多边形T,遍历到的第一个节点作为新的节点代替反向路径上节点R’(<img file="982143dest_path_image067.GIF" wi="12" he="16" />),反向路径R’被更新;14)、重复步骤9~13,直到Queue中N个节点中每个节点的当前剩余能量<img file="839241dest_path_image054.GIF" wi="77" he="24" />(<img file="595844dest_path_image050.GIF" wi="12" he="24" />=1,2,…,N)小于等于0为止;通过以上步骤可以建立查询路径R和反向路径R’,通过反向路径R’中每个节点的能量阈值更新路径,避免出现热点路由而引起的节点能耗不均匀问题。
地址 130022 吉林省长春市卫星路7186号科技大厦B座1603室