| 查看: 618 | 回复: 5 | |||
| 当前主题已经存档。 | |||
[交流]
【求助】小世界网络的模拟程序
|
|||
|
自己用fortran写了一个程序,但运行速度太慢, 如果哪位有,请发到wqfscience@yahoo.com.cn 不胜感激。 [ Last edited by lvzhu2007 on 2008-9-18 at 15:42 ] |
» 猜你喜欢
UV压敏胶开发
已经有6人回复
8月时间戳变的,举个手。玩一下,释放压力
已经有3人回复
有没有H口的?有收到消息的吗?
已经有3人回复
十年后又回来了,论文投稿求助
已经有3人回复
纯娱乐,不喜欢勿喷
已经有10人回复
面上再次挂了,太难了,躺也躺不了,倦也卷不过,小学校之殇!
已经有26人回复
面上提前没消息,有中的吗
已经有18人回复
娱乐
已经有4人回复
系统今天又提示维护了,估计离放榜不远了
已经有16人回复
一个有机合成实验室都需要哪些设备?
已经有10人回复
2楼2008-09-18 15:41:26
3楼2008-09-18 18:39:13
4楼2008-09-18 19:15:58

5楼2008-10-03 09:35:43
★
wuli8(金币+1,VIP+0):鼓励新虫!(*^__^*) ……
wuli8(金币+1,VIP+0):鼓励新虫!(*^__^*) ……
|
我也正在编写关于小世界模型的fortran程序,可是得出来的结总是不对,我的方向是非线性动力学,能否把你的程序给我发下,huiy_chen@stu.snnu.edu.cn,不胜感激!我的代码如下: program main implicit none c ****************************************************** c creat a small-world network c ns is the number of edges c n is the number of vertex c kh is the nearest edges that connected to vertex i c ****************************************************** integer i,j,ns,n,jj,kh,k real*8 p integer G(1:10,1:10) real*8 R(1:100) ns=0 write(*,*)"n=" read(*,*) n write(*,*)"kh=" read(*,*) kh write(*,*)"p=" read(*,*)p do j=1,n do i=1,n G(i,j)=0 end do end do do i=1,n do jj=1,kh j=i+jj if(j.gt.n)j=j-n G(i,j)=1 G(j,i)=1 ns=ns+1 end do end do c****************************************************************** c add edges randomly,ns denotes the degree of vertex c****************************************************************** do i=1,n-kh-1 do j=i+kh+1,n if(G(i,j).eq.1.d0) cycle call random_seed() do k=1,1000 call random_number(R(k)) if(R(k).le.p)then G(i,j)=1 G(j,i)=1 ns=ns+1 write(*,*) ns end if end do end do end do end |
6楼2008-11-12 10:55:48










回复此楼