write (*,*) *' put # of nodes and aver degree in two comma-separated columns' write (*,*) *' of a file named coef.txt & coef.out will compute the Bollobasi' write (*,*) *' and Riordan (2003) expected value of the clustering coefficient' write (*,*) *' for a scale-free network with these parameters' pause open (1,file='coef.txt') open (2,file='coef.out') do i=1,100 read (1,*,end=1,err=2) a, b c=((b-1)*(log10(a)**2))/(8*a) write (*,'(F20.0,F7.1,f15.10)') a, b, c write (2,'(F20.0,F7.1,f15.10)') a, b, c enddo 2 write (*,*) ' error in coef.txt file' stop 1 write (*,*) *' Number of Nodes Aver Degree Expected Clustering' write (2,*) *' Number of Nodes Aver Degree Expected Clustering' end