Floyd-Warshall算法描述 1)适用范围: a)APSP(All Pairs Shortest Paths) b)稠密图效果最佳 c)边权可正可负 2)算法描述: a)初始化:dis[u,v]=w[u,v] b)For k:=1 to n For i:=1 to n For j:=1 to n If dis[i,j]>dis[i,k]+dis[k,j] Then Dis[I,j]:=dis[I,k]+dis[k,j] c)算法结束:dis即为所有点对的最短路径矩阵 3)算法小结:此算法简单有效,由于三重循环结构紧凑,对于稠密图,效率要高于执行|V|次Dijkstra算法。时间复杂度O(n^3)。 考虑下列变形:如(I,j)∈E则dis[I,j]初始为1,else初始为0,这样的Floyd算法最后的最短路径矩阵即成为一个判断I,j是否有通路的矩阵。更简单的,我们可以把dis设成boolean类型,则每次可以用“dis[I,j]:=dis[I,j]or(dis[I,k]and dis[k,j])”来代替算法描述中的蓝色部分,可以更直观地得到I,j的连通情况。
标签: Floyd-Warshall Shortest Pairs Paths
上传时间: 2013-12-01
上传用户:dyctj
--文件名:mine4.vhd。 --功能:实现4种常见波形正弦、三角、锯齿、方波(A、B)的频率、幅度可控输出(方波 --A的占空比也是可控的),可以存储任意波形特征数据并能重现该波形,还可完成 --各种波形的线形叠加输出。 --说明: SSS(前三位)和SW信号控制4种常见波形种哪种波形输出。4种波形的频率、 --幅度(基准幅度A)的调节均是通过up、down、set按键和4个BCD码置入器以及一 --个置入档位控制信号(ss)完成的(AMP的调节范围是0~5V,调节量阶为1/51V)。 --其中方波的幅度还可通过u0、d0调节输出数据的归一化幅值(AMP0)进行进一步 --细调(调节量阶为1/(51*255)V)。方波A的占空比通过zu、zp按键调节(调节 --量阶1/64*T)。系统采用内部存储器——RAM实现任意输入波形的存储,程序只支 --持键盘式波形特征参数置入存储,posting 为进入任意波置入(set)、清除(clr)状态 --控制信号,SSS控制存储波形的输出。P180为预留端口,
上传时间: 2017-02-09
上传用户:z1191176801
basic.c */ /**//* Project:NeuroBasic, basic package*//**/ /* Survey:This is a simple Basic b-code compiler which*/ /*can be used as a comfortable command shell for */ /* any program. The actual compiler is found in */ /*compiler.c.*/ /*The functions m_fctptr() and user_server()*/ /*build an interface to an
标签: basic NeuroBasic Project package
上传时间: 2017-02-15
上传用户:xymbian
"Readers can pick up this book and become familiar with C++ in a short time. Stan has taken a very broad and complicated topic and reduced it to the essentials that budding C++ programmers need to know to write real programs. His case study is effective and provides a familiar thread throughout the book.
标签: familiar Readers become short
上传时间: 2014-01-19
上传用户:luke5347
该程序用以查找任意两个整数之间的所有素数。 Prime number finder can find all primes between a and b and will write the results to the file PRIMES.TXT
上传时间: 2014-01-14
上传用户:cccole0605
C++ Primer, Fourth Edition By Stanley B. Lippman, Josée Lajoie, Barbara E. Moo ............................................... Publisher: Addison Wesley Professional Pub Date: February 14, 2005 Print ISBN: 0-201-72148-1 Pages: 912
上传时间: 2017-08-02
上传用户:yxgi5
随着光伏发电系统快速发展,以及电动汽车充电桩的普及,传统的剩余电流保护器无法满足实际需求。介绍了一款B型剩余电流保护器,采用磁调制剩余电流互感器和零序电流互感器采集剩余电流。根据GB/T 22794—2017标准要求,可识别1 kHz及以下的正弦交流、带和不带直流分量的脉动直流、平滑直流等剩余电流信号。经信号调理电路将电压信号送到单片机进行采集和判断。通过试验测试,该样机在测试精度和速度上均符合国家标准的相关要求。The rapid development of photovoltaic power generation systems and the popularity of electric vehicle charging piles make the traditional residual current protective devices unable to meet the actual demand.This paper proposed a type B residual current protective device,which uses the magnetically modulated residual current transformer and the zero sequence current transformer to acquire the residual current.According to the requirements of GB/T 22794—2017,the type B residual current protective device can detect sinusoidal AC residual current of 1kHz and below 1kHz,pulsating DC residual current with and without DC component,smooth DC residual current and so on.The signal processing circuit sends the voltage signal to the MCU for acquisition and judgment.Through experimental tests,the device meets the relevant requirements of national standards in terms of test accuracy and speed.
标签: 电流保护器
上传时间: 2022-03-27
上传用户:
21世纪大学新型参考教材系列 集成电路B 荒井
上传时间: 2013-04-15
上传用户:eeworm
家电维修(最基础的教程B)1-20.Torrent
上传时间: 2013-06-10
上传用户:eeworm
jk-b交通信号控制机原理图
上传时间: 2013-07-13
上传用户:eeworm