排斥耦合混沌振子中的稳定振幅奇异态和死亡奇异态


Stable amplitude chimera states and chimera death in repulsively coupled chaotic oscillators

阅读

下载地址:

复现

figure 1

image-20230101222126213

module Lorenz
    implicit none
    real,parameter :: h=0.001
    integer,parameter :: MaxT=2500000,T_trans=2000000,N=3,M=2
    real(kind=8) :: x(M,N)
    integer :: p=1
    integer,allocatable :: neighbour_matrix(:,:)
contains

    subroutine x0()
        implicit none
        integer :: i
        real :: x1,x2,x3
        call random_seed()
        do i=1,M,1
            call random_number(x1)
            call random_number(x2)
            call random_number(x3)
            x(i,1)=31.0*x1-14.0
            x(i,2)=44.0*x2-20.0
            x(i,3)=23.0*x3-1
            write(20,*) x(i,1),x(i,2),x(i,3)
        end do
    end subroutine x0

    subroutine fnf(xx,fx,i)
        implicit none
        real(kind=8) :: xx(N),fx(N)
        integer :: t,j,i
        real(kind=8) :: a,b,c,coupling,epsilon
        coupling=0.0
        epsilon=-3.16
        do j=1,M,1
            coupling=coupling+neighbour_matrix(i,j)*(x(j,1)-x(i,1))
        end do
        a=10.0
        b=2.0
        c=28.0
        fx(1)=a*(xx(2)-xx(1))+(epsilon/real(p))*coupling
        fx(2)=c*xx(1)-xx(1)*xx(3)-xx(2)
        fx(3)=xx(1)*xx(2)-b*xx(3)
        return
    end subroutine fnf


    subroutine rk4(x,t)
        implicit none
        integer :: i,j,t
        real(kind=8) :: x(M,N),xx(N),fx(N)
        real(kind=8) :: kx1(N),kx2(N),kx3(N),kx4(N)
        do i=1,M,1
            xx=x(i,:)
            call fnf(xx,fx,i)
            kx1=h*fx
            xx=x(i,:)+0.5*kx1
            call fnf(xx,fx,i)
            kx2=h*fx
            xx=x(i,:)+0.5*kx2
            call fnf(xx,fx,i)
            kx3=h*fx
            xx=x(i,:)+kx3
            call fnf(xx,fx,i)
            kx4=h*fx
            x(i,:)=x(i,:)+(kx1+2.0*kx2+2.0*kx3+kx4)/6.0
        end do
        return
    end subroutine rk4

    !max与min
    subroutine Max_Min(xxx,max,min)
        implicit none
        real(kind=8) :: max(M),min(M),xxx(M)
        integer :: i
        do i=1,M,1
            if(max(i)<xxx(i)) then
                max(i)=xxx(i)
            end if
            if(min(i)>xxx(i)) then
                min(i)=xxx(i)
            end if
        end do
        return
    end subroutine Max_Min

    !建立网络矩阵
    subroutine neighbour(K)
        implicit none
        integer :: K !单节点K个邻居
        integer :: i,j,number
        allocate(neighbour_matrix(M,M))
        !初始化网络矩阵
        neighbour_matrix=0
        do i=1,M-1,1
            do j=i+1,M,1
                if(abs(i-j)<=K/2.or.abs(i-j)>=M-K/2) then
                    neighbour_matrix(i,j)=1
                    neighbour_matrix(j,i)=1
                end if
            end do
        end do
        !输出矩阵
        do i=1,M,1
            do j=1,M,1
                write(10,"(I2)",advance='no') neighbour_matrix(i,j)
            end do
            write(10,*)
        end do
        return
    end subroutine neighbour

end module Lorenz



program main
    use Lorenz
    implicit none
    integer :: i,j,t
    real(kind=8) :: max(M),min(M)
    open(10,file="neighbour_matrix.txt")
    open(20,file="x0.txt")
    open(30,file="c_M_max_min.txt")
    open(40,file="t_x_y_z_1.txt")
    open(50,file="t_x_y_z_2.txt")
    max=-1000.0
    min=1000.0
    call x0()
    call neighbour(2*p)
    do t=1,MaxT,1
        call rk4(x,t)
        if(t>T_trans) then
            call Max_Min(x(:,1),max,min)
            write(40,"(4(F15.6))") (t-T_trans)*h,x(1,1),x(1,2),x(1,3)
            write(50,"(4(F15.6))") (t-T_trans)*h,x(2,1),x(2,2),x(2,3)
        end if
    end do
    do j=1,M,1
        write(30,*) j,max(j),min(j)
    end do
end program main

figure 1_A

image-20230101223146447

figure 1_B

image-20230101224545656

figure 1_C

image-20230101225021689

figure 1_D

image-20230101225334808

figure 1_E

image-20230101223322350

figure 1_F

image-20230101224417108

figure 1_G

image-20230101224845586

figure 1_H

image-20230101225542335

figure 2

image-20230102102649706

module Lorenz
    implicit none
    real,parameter :: h=0.001
    integer,parameter :: MaxT=2006000,T_trans=2003000,N=3,M=100
    real(kind=8) :: x(M,N)
    integer :: p=35
    integer,allocatable :: neighbour_matrix(:,:)
contains

    subroutine x0()
        implicit none
        integer :: i
        real :: x1,x2,x3
        call random_seed()
        do i=1,M,1
            call random_number(x1)
            call random_number(x2)
            call random_number(x3)
            x(i,1)=31.0*x1-14.0
            x(i,2)=44.0*x2-20.0
            x(i,3)=23.0*x3-1
            write(20,*) x(i,1),x(i,2),x(i,3)
        end do
    end subroutine x0

    subroutine fnf(xx,fx,i)
        implicit none
        real(kind=8) :: xx(N),fx(N)
        integer :: t,j,i
        real(kind=8) :: a,b,c,coupling,epsilon
        coupling=0.0
        epsilon=-6.0
        do j=1,M,1
            coupling=coupling+neighbour_matrix(i,j)*(x(j,1)-x(i,1))
        end do
        a=10.0
        b=2.0
        c=28.0
        fx(1)=a*(xx(2)-xx(1))+(epsilon/real(2.0*p))*coupling
        fx(2)=c*xx(1)-xx(1)*xx(3)-xx(2)
        fx(3)=xx(1)*xx(2)-b*xx(3)
        return
    end subroutine fnf


    subroutine rk4(x,t)
        implicit none
        integer :: i,j,t
        real(kind=8) :: x(M,N),xx(N),fx(N)
        real(kind=8) :: kx1(N),kx2(N),kx3(N),kx4(N)
        do i=1,M,1
            xx=x(i,:)
            call fnf(xx,fx,i)
            kx1=h*fx
            xx=x(i,:)+0.5*kx1
            call fnf(xx,fx,i)
            kx2=h*fx
            xx=x(i,:)+0.5*kx2
            call fnf(xx,fx,i)
            kx3=h*fx
            xx=x(i,:)+kx3
            call fnf(xx,fx,i)
            kx4=h*fx
            x(i,:)=x(i,:)+(kx1+2.0*kx2+2.0*kx3+kx4)/6.0
        end do
        return
    end subroutine rk4

    !max与min
    subroutine Max_Min(xxx,max,min)
        implicit none
        real(kind=8) :: max(M),min(M),xxx(M)
        integer :: i
        do i=1,M,1
            if(max(i)<xxx(i)) then
                max(i)=xxx(i)
            end if
            if(min(i)>xxx(i)) then
                min(i)=xxx(i)
            end if
        end do
        return
    end subroutine Max_Min

    !建立网络矩阵
    subroutine neighbour(K)
        implicit none
        integer :: K !单节点K个邻居
        integer :: i,j,number
        allocate(neighbour_matrix(M,M))
        !初始化网络矩阵
        neighbour_matrix=0
        do i=1,M-1,1
            do j=i+1,M,1
                if(abs(i-j)<=K/2.or.abs(i-j)>=M-K/2) then
                    neighbour_matrix(i,j)=1
                    neighbour_matrix(j,i)=1
                end if
            end do
        end do
        !输出矩阵
        do i=1,M,1
            do j=1,M,1
                write(10,"(I2)",advance='no') neighbour_matrix(i,j)
            end do
            write(10,*)
        end do
        return
    end subroutine neighbour

end module Lorenz



program main
    use Lorenz
    implicit none
    integer :: i,j,t
    real(kind=8) :: max(M),min(M)
    open(10,file="neighbour_matrix.txt")
    open(20,file="x0.txt")
    open(30,file="c_M_max_min.txt")
    open(40,file="t_x_y_z_1.txt")
    open(50,file="t_x_y_z_2.txt")
    open(60,file="i_t_x_y_z.txt")
    max=-1000.0
    min=1000.0
    call x0()
    call neighbour(2*p)
    do t=1,MaxT,1
        call rk4(x,t)
        if(t>T_trans) then
            call Max_Min(x(:,1),max,min)
            write(40,"(4(F15.6))") (t-T_trans)*h,x(1,1),x(1,2),x(1,3)
            write(50,"(4(F15.6))") (t-T_trans)*h,x(2,1),x(2,2),x(2,3)
            do i=1,M,1
                if(mod(t,1)==0) then
                    write(60,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                end if    
            end do    
        end if
    end do
    do j=1,M,1
        write(30,*) j,max(j),min(j)
    end do
end program main

figure 2_A

image-20230102102615900

image-20230102104937983

figure 2_B

image-20230102104419415

figure 2_C

image-20230102222250586

figure 2_D

image-20230102121005038

figure 2_E

image-20230102122928726

figure 2_F

image-20230102225211041

figure 3

image-20230102222547601

module Lorenz
    implicit none
    real,parameter :: h=0.001
    integer,parameter :: MaxT=2030000,T_trans=2000000,N=3,M=100
    real(kind=8) :: x(M,N)
    integer :: p=1
    integer,allocatable :: neighbour_matrix(:,:)
contains

    subroutine x0()
        implicit none
        integer :: i
        real :: x1,x2,x3
        call random_seed()
        do i=1,M,1
            call random_number(x1)
            call random_number(x2)
            call random_number(x3)
            x(i,1)=31.0*x1-14.0
            x(i,2)=44.0*x2-20.0
            x(i,3)=23.0*x3-1.0
            write(20,*) x(i,1),x(i,2),x(i,3)
        end do
    end subroutine x0

    subroutine fnf(xx,fx,i)
        implicit none
        real(kind=8) :: xx(N),fx(N)
        integer :: t,j,i
        real(kind=8) :: a,b,c,coupling,epsilon
        coupling=0.0
        epsilon=-3.05
        do j=1,M,1
            coupling=coupling+neighbour_matrix(i,j)*(x(j,1)-x(i,1))
        end do
        a=10.0
        b=2.0
        c=28.0
        fx(1)=a*(xx(2)-xx(1))+(epsilon/real(2.0*p))*coupling
        fx(2)=c*xx(1)-xx(1)*xx(3)-xx(2)
        fx(3)=xx(1)*xx(2)-b*xx(3)
        return
    end subroutine fnf


    subroutine rk4(x,t)
        implicit none
        integer :: i,j,t
        real(kind=8) :: x(M,N),xx(N),fx(N)
        real(kind=8) :: kx1(N),kx2(N),kx3(N),kx4(N)
        do i=1,M,1
            xx=x(i,:)
            call fnf(xx,fx,i)
            kx1=h*fx
            xx=x(i,:)+0.5*kx1
            call fnf(xx,fx,i)
            kx2=h*fx
            xx=x(i,:)+0.5*kx2
            call fnf(xx,fx,i)
            kx3=h*fx
            xx=x(i,:)+kx3
            call fnf(xx,fx,i)
            kx4=h*fx
            x(i,:)=x(i,:)+(kx1+2.0*kx2+2.0*kx3+kx4)/6.0
        end do
        return
    end subroutine rk4

    !max与min
    subroutine Max_Min(xxx,max,min)
        implicit none
        real(kind=8) :: max(M),min(M),xxx(M)
        integer :: i
        do i=1,M,1
            if(max(i)<xxx(i)) then
                max(i)=xxx(i)
            end if
            if(min(i)>xxx(i)) then
                min(i)=xxx(i)
            end if
        end do
        return
    end subroutine Max_Min

    !建立网络矩阵
    subroutine neighbour(K)
        implicit none
        integer :: K !单节点K个邻居
        integer :: i,j,number
        allocate(neighbour_matrix(M,M))
        !初始化网络矩阵
        neighbour_matrix=0
        do i=1,M-1,1
            do j=i+1,M,1
                if(abs(i-j)<=K/2.or.abs(i-j)>=M-K/2) then
                    neighbour_matrix(i,j)=1
                    neighbour_matrix(j,i)=1
                end if
            end do
        end do
        !输出矩阵
        do i=1,M,1
            do j=1,M,1
                write(10,"(I2)",advance='no') neighbour_matrix(i,j)
            end do
            write(10,*)
        end do
        return
    end subroutine neighbour

end module Lorenz



program main
    use Lorenz
    implicit none
    integer :: i,j,t
    real(kind=8) :: max(M),min(M)
    open(10,file="neighbour_matrix.txt")
    open(20,file="x0.txt")
    open(30,file="c_M_max_min.txt")
    open(40,file="t_x_y_z_14.txt")
    open(50,file="t_x_y_z_15.txt")
    open(60,file="i_t_x_y_z.txt")
    open(70,file="i_t_x_y_z_kuaizhao.txt")
    max=-10000.0
    min=10000.0
    call x0()
    call neighbour(2*p)
    do t=1,MaxT,1
        call rk4(x,t)
        if(t>T_trans) then
            call Max_Min(x(:,1),max,min)
            write(40,"(4(F15.6))") (t-T_trans)*h,x(14,1),x(14,2),x(14,3)
            write(50,"(4(F15.6))") (t-T_trans)*h,x(15,1),x(15,2),x(15,3)
            do i=1,M,1
                if((t-T_trans)*h==20) then
                    write(70,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                end if
                if(mod(t,50)==0) then
                    write(60,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                end if
            end do
        end if
    end do
    do j=1,M,1
        write(30,*) j,max(j),min(j)
    end do
end program main

figure 3_A

image-20230105203454895

figure 3_B

image-20230105211118411

figure 3_C

image-20230105223518523

figure 3_D

image-20230105233019355

figure 3_E

image-20230105204332550

figure 3_F

image-20230105210421236

figure 3_G

image-20230105222426405

figure 3_H

image-20230105233330815

figure 3_I

image-20230105203855511

figure 3_J

image-20230105214153019

figure 3_K

image-20230105231558231

figure 3_L

image-20230105235735628

figure 4

image-20230102224543895

module Lorenz
    implicit none
    real,parameter :: h=0.001
    integer,parameter :: MaxT=2030000,T_trans=2000000,N=3,M=100
    real(kind=8) :: x(M,N)
    integer :: p=4
    integer,allocatable :: neighbour_matrix(:,:)
contains

    subroutine x0()
        implicit none
        integer :: i
        real :: x1,x2,x3
        call random_seed()
        do i=1,M,1
            call random_number(x1)
            call random_number(x2)
            call random_number(x3)
            x(i,1)=31.0*x1-14.0
            x(i,2)=44.0*x2-20.0
            x(i,3)=23.0*x3-1.0
            write(20,*) x(i,1),x(i,2),x(i,3)
        end do
    end subroutine x0

    subroutine fnf(xx,fx,i)
        implicit none
        real(kind=8) :: xx(N),fx(N)
        integer :: t,j,i
        real(kind=8) :: a,b,c,coupling,epsilon
        coupling=0.0
        epsilon=-5.90
        do j=1,M,1
            coupling=coupling+neighbour_matrix(i,j)*(x(j,1)-x(i,1))
        end do
        a=10.0
        b=2.0
        c=28.0
        fx(1)=a*(xx(2)-xx(1))+(epsilon/real(2.0*p))*coupling
        fx(2)=c*xx(1)-xx(1)*xx(3)-xx(2)
        fx(3)=xx(1)*xx(2)-b*xx(3)
        return
    end subroutine fnf


    subroutine rk4(x,t)
        implicit none
        integer :: i,j,t
        real(kind=8) :: x(M,N),xx(N),fx(N)
        real(kind=8) :: kx1(N),kx2(N),kx3(N),kx4(N)
        do i=1,M,1
            xx=x(i,:)
            call fnf(xx,fx,i)
            kx1=h*fx
            xx=x(i,:)+0.5*kx1
            call fnf(xx,fx,i)
            kx2=h*fx
            xx=x(i,:)+0.5*kx2
            call fnf(xx,fx,i)
            kx3=h*fx
            xx=x(i,:)+kx3
            call fnf(xx,fx,i)
            kx4=h*fx
            x(i,:)=x(i,:)+(kx1+2.0*kx2+2.0*kx3+kx4)/6.0
        end do
        return
    end subroutine rk4

    !max与min
    subroutine Max_Min(xxx,max,min)
        implicit none
        real(kind=8) :: max(M),min(M),xxx(M)
        integer :: i
        do i=1,M,1
            if(max(i)<xxx(i)) then
                max(i)=xxx(i)
            end if
            if(min(i)>xxx(i)) then
                min(i)=xxx(i)
            end if
        end do
        return
    end subroutine Max_Min

    !建立网络矩阵
    subroutine neighbour(K)
        implicit none
        integer :: K !单节点K个邻居
        integer :: i,j,number
        allocate(neighbour_matrix(M,M))
        !初始化网络矩阵
        neighbour_matrix=0
        do i=1,M-1,1
            do j=i+1,M,1
                if(abs(i-j)<=K/2.or.abs(i-j)>=M-K/2) then
                    neighbour_matrix(i,j)=1
                    neighbour_matrix(j,i)=1
                end if
            end do
        end do
        !输出矩阵
        do i=1,M,1
            do j=1,M,1
                write(10,"(I2)",advance='no') neighbour_matrix(i,j)
            end do
            write(10,*)
        end do
        return
    end subroutine neighbour

end module Lorenz



program main
    use Lorenz
    implicit none
    integer :: i,j,t
    real(kind=8) :: max(M),min(M)
    open(10,file="neighbour_matrix.txt")
    open(20,file="x0.txt")
    open(30,file="c_M_max_min.txt")
    open(40,file="t_x_y_z_14.txt")
    open(50,file="t_x_y_z_15.txt")
    open(60,file="i_t_x_y_z.txt")
    open(70,file="i_t_x_y_z_kuaizhao.txt")
    open(80,file="i_t_x_y_z_all.txt")
    max=-10000.0
    min=10000.0
    call x0()
    call neighbour(2*p)
    do t=1,MaxT,1
        call rk4(x,t)
        if(t>T_trans) then
            call Max_Min(x(:,1),max,min)
            write(40,"(4(F15.6))") (t-T_trans)*h,x(14,1),x(14,2),x(14,3)
            write(50,"(4(F15.6))") (t-T_trans)*h,x(15,1),x(15,2),x(15,3)
            do i=1,M,1
                write(80,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                if((t-T_trans)*h==20) then
                    write(70,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                end if
                if(mod(t,50)==0) then
                    write(60,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                end if
            end do
        end if
    end do
    do j=1,M,1
        write(30,*) j,max(j),min(j)
    end do
end program main

figure 4_A

image-20230106094246264

figure 4_B

image-20230106100129151

figure 4_C

image-20230106101811322

figure 4_D

image-20230106102247937

figure 5

image-20230102224710457

module Lorenz
    implicit none
    real,parameter :: h=0.001
    integer,parameter :: MaxT=1003000,T_trans=1000000,N=3,M=100
    real(kind=8) :: x(M,N)
    integer :: p=36
    integer,allocatable :: neighbour_matrix(:,:)
contains

    subroutine x0()
        implicit none
        integer :: i
        real :: x1,x2,x3
        call random_seed()
        do i=1,M,1
            call random_number(x1)
            call random_number(x2)
            call random_number(x3)
            x(i,1)=31.0*x1-14.0
            x(i,2)=44.0*x2-20.0
            x(i,3)=23.0*x3-1.0
            write(20,*) x(i,1),x(i,2),x(i,3)
        end do
    end subroutine x0

    subroutine fnf(xx,fx,i)
        implicit none
        real(kind=8) :: xx(N),fx(N)
        integer :: t,j,i
        real(kind=8) :: a,b,c,coupling,epsilon
        coupling=0.0
        epsilon=-6.0
        do j=1,M,1
            coupling=coupling+neighbour_matrix(i,j)*(x(j,1)-x(i,1))
        end do
        a=10.0
        b=2.0
        c=28.0
        fx(1)=a*(xx(2)-xx(1))+(epsilon/real(2.0*p))*coupling
        fx(2)=c*xx(1)-xx(1)*xx(3)-xx(2)
        fx(3)=xx(1)*xx(2)-b*xx(3)
        return
    end subroutine fnf


    subroutine rk4(x,t)
        implicit none
        integer :: i,j,t
        real(kind=8) :: x(M,N),xx(N),fx(N)
        real(kind=8) :: kx1(N),kx2(N),kx3(N),kx4(N)
        do i=1,M,1
            xx=x(i,:)
            call fnf(xx,fx,i)
            kx1=h*fx
            xx=x(i,:)+0.5*kx1
            call fnf(xx,fx,i)
            kx2=h*fx
            xx=x(i,:)+0.5*kx2
            call fnf(xx,fx,i)
            kx3=h*fx
            xx=x(i,:)+kx3
            call fnf(xx,fx,i)
            kx4=h*fx
            x(i,:)=x(i,:)+(kx1+2.0*kx2+2.0*kx3+kx4)/6.0
        end do
        return
    end subroutine rk4

    !max与min
    subroutine Max_Min(xxx,max,min)
        implicit none
        real(kind=8) :: max(M),min(M),xxx(M)
        integer :: i
        do i=1,M,1
            if(max(i)<xxx(i)) then
                max(i)=xxx(i)
            end if
            if(min(i)>xxx(i)) then
                min(i)=xxx(i)
            end if
        end do
        return
    end subroutine Max_Min

    !建立网络矩阵
    subroutine neighbour(K)
        implicit none
        integer :: K !单节点K个邻居
        integer :: i,j,number
        allocate(neighbour_matrix(M,M))
        !初始化网络矩阵
        neighbour_matrix=0
        do i=1,M-1,1
            do j=i+1,M,1
                if(abs(i-j)<=K/2.or.abs(i-j)>=M-K/2) then
                    neighbour_matrix(i,j)=1
                    neighbour_matrix(j,i)=1
                end if
            end do
        end do
        !输出矩阵
        do i=1,M,1
            do j=1,M,1
                write(10,"(I2)",advance='no') neighbour_matrix(i,j)
            end do
            write(10,*)
        end do
        return
    end subroutine neighbour

end module Lorenz



program main
    use Lorenz
    implicit none
    integer :: i,j,t
    real(kind=8) :: max(M),min(M)
    open(10,file="neighbour_matrix.txt")
    open(20,file="x0.txt")
    open(30,file="c_M_max_min.txt")
    open(40,file="t_x_y_z_14.txt")
    open(50,file="t_x_y_z_15.txt")
    open(60,file="i_t_x_y_z.txt")
    open(70,file="i_t_x_y_z_kuaizhao.txt")
    open(80,file="i_t_x_y_z_all.txt")
    max=-10000.0
    min=10000.0
    call x0()
    call neighbour(2*p)
    do t=1,MaxT,1
        call rk4(x,t)
        if(t>T_trans) then
            call Max_Min(x(:,1),max,min)
            write(40,"(4(F15.6))") (t-T_trans)*h,x(14,1),x(14,2),x(14,3)
            write(50,"(4(F15.6))") (t-T_trans)*h,x(15,1),x(15,2),x(15,3)
            do i=1,M,1
                write(80,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                if(t-1==T_trans) then
                    write(70,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                end if
                if(mod(t,10)==0) then
                    write(60,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                end if
            end do
        end if
    end do
    do j=1,M,1
        write(30,*) j,max(j),min(j)
    end do
end program main

figure 5_A

image-20230106103948170

figure 5_B

image-20230106105044758

figure 5_C

image-20230106110051951

figure 5_D

image-20230106111143413

figure 5_E

image-20230106103332591

figure 5_F

image-20230106104414149

figure 5_G

image-20230106105510540

figure 5_H

image-20230106110739332

figure 6

image-20230102224917623

module Lorenz
    implicit none
    real,parameter :: h=0.001
    integer,parameter :: MaxT=1030000,T_trans=1000000,N=3,M=200
    real(kind=8) :: x(M,N)
    integer :: p
    integer,allocatable :: neighbour_matrix(:,:)
contains

    subroutine x0()
        implicit none
        integer :: i
        real :: x1,x2,x3
        call random_seed()
        do i=1,M,1
            call random_number(x1)
            call random_number(x2)
            call random_number(x3)
            x(i,1)=31.0*x1-14.0
            x(i,2)=44.0*x2-20.0
            x(i,3)=23.0*x3-1.0
            !write(20,*) x(i,1),x(i,2),x(i,3)
        end do
    end subroutine x0

    subroutine fnf(xx,fx,i)
        implicit none
        real(kind=8) :: xx(N),fx(N)
        integer :: t,j,i
        real(kind=8) :: a,b,c,coupling,epsilon
        coupling=0.0
        epsilon=-6.0
        do j=1,M,1
            coupling=coupling+neighbour_matrix(i,j)*(x(j,1)-x(i,1))
        end do
        a=10.0
        b=2.0
        c=28.0
        fx(1)=a*(xx(2)-xx(1))+(epsilon/real(2.0*p))*coupling
        fx(2)=c*xx(1)-xx(1)*xx(3)-xx(2)
        fx(3)=xx(1)*xx(2)-b*xx(3)
        return
    end subroutine fnf


    subroutine rk4(x,t)
        implicit none
        integer :: i,j,t
        real(kind=8) :: x(M,N),xx(N),fx(N)
        real(kind=8) :: kx1(N),kx2(N),kx3(N),kx4(N)
        do i=1,M,1
            xx=x(i,:)
            call fnf(xx,fx,i)
            kx1=h*fx
            xx=x(i,:)+0.5*kx1
            call fnf(xx,fx,i)
            kx2=h*fx
            xx=x(i,:)+0.5*kx2
            call fnf(xx,fx,i)
            kx3=h*fx
            xx=x(i,:)+kx3
            call fnf(xx,fx,i)
            kx4=h*fx
            x(i,:)=x(i,:)+(kx1+2.0*kx2+2.0*kx3+kx4)/6.0
        end do
        return
    end subroutine rk4

    !max与min
    subroutine Max_Min(xxx,max,min)
        implicit none
        real(kind=8) :: max(M),min(M),xxx(M)
        integer :: i
        do i=1,M,1
            if(max(i)<xxx(i)) then
                max(i)=xxx(i)
            end if
            if(min(i)>xxx(i)) then
                min(i)=xxx(i)
            end if
        end do
        return
    end subroutine Max_Min

    !建立网络矩阵
    subroutine neighbour(K)
        implicit none
        integer :: K !单节点K个邻居
        integer :: i,j,number
        allocate(neighbour_matrix(M,M))
        !初始化网络矩阵
        neighbour_matrix=0
        do i=1,M-1,1
            do j=i+1,M,1
                if(abs(i-j)<=K/2.or.abs(i-j)>=M-K/2) then
                    neighbour_matrix(i,j)=1
                    neighbour_matrix(j,i)=1
                end if
            end do
        end do
        !输出矩阵
!        do i=1,M,1
!            do j=1,M,1
!                write(10,"(I2)",advance='no') neighbour_matrix(i,j)
!            end do
!            write(10,*)
!        end do
        return
    end subroutine neighbour

end module Lorenz



program main
    use Lorenz
    implicit none
    integer :: i,j,t,Nc
    real(kind=8) :: max(M),min(M)
    open(10,file="neighbour_matrix.txt")
    open(20,file="x0.txt")
    open(30,file="c_M_max_min.txt")
    open(40,file="t_x_y_z_14.txt")
    open(50,file="t_x_y_z_15.txt")
    open(60,file="i_t_x_y_z.txt")
    open(70,file="i_t_x_y_z_kuaizhao.txt")
    open(80,file="i_t_x_y_z_all.txt")
    open(90,file="p_Nc.txt")
    do p=1,50,1
        max=-10000.0
        min=10000.0
        Nc=0
        call x0()
        call neighbour(2*p)
        do t=1,MaxT,1
            call rk4(x,t)
            if(t>T_trans) then
                call Max_Min(x(:,1),max,min)
!                write(40,"(4(F15.6))") (t-T_trans)*h,x(14,1),x(14,2),x(14,3)
!                write(50,"(4(F15.6))") (t-T_trans)*h,x(15,1),x(15,2),x(15,3)
                do i=1,M,1
                    !write(80,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                    !if((t-T_trans)*h==20) then
                    !    write(70,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                    !end if
                    !if(mod(t,50)==0) then
                    !    write(60,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                    !end if
                end do
            end if
        end do
        do j=1,M-1,1
            write(30,*) j,max(j),min(j)
            if(((max(j)>0.and.min(j)>0).and.max(j+1)<0).or.((max(j)<0.and.min(j)<0).and.max(j+1)>0)) then
                Nc=Nc+1
            end if
        end do
        write(90,*) p,Nc
        write(*,*) p,Nc
        deallocate(neighbour_matrix)
    end do
end program main

figure 6_A

image-20230109100812178

figure 7

image-20230102225647126

module Lorenz
    implicit none
    real,parameter :: h=0.001
    integer,parameter :: MaxT=2030000,T_trans=2000000,N=3,M=100
    real(kind=8) :: x(M,N)
    integer :: p
    integer,allocatable :: neighbour_matrix(:,:)
contains

    subroutine x0()
        implicit none
        integer :: i
        real :: x1,x2,x3
        call random_seed()
        do i=1,M,1
            call random_number(x1)
            call random_number(x2)
            call random_number(x3)
            x(i,1)=31.0*x1-14.0
            x(i,2)=44.0*x2-20.0
            x(i,3)=23.0*x3-1.0
            write(20,*) x(i,1),x(i,2),x(i,3)
        end do
    end subroutine x0

    subroutine fnf(xx,fx,i)
        implicit none
        real(kind=8) :: xx(N),fx(N)
        integer :: t,j,i
        real(kind=8) :: a,b,c,coupling,epsilon
        coupling=0.0
        epsilon=-7.5
        do j=1,M,1
            coupling=coupling+neighbour_matrix(i,j)*(x(j,1)-x(i,1))
        end do
        a=10.0
        b=2.0
        c=28.0
        fx(1)=a*(xx(2)-xx(1))+(epsilon/real(2.0*p))*coupling
        fx(2)=c*xx(1)-xx(1)*xx(3)-xx(2)
        fx(3)=xx(1)*xx(2)-b*xx(3)
        return
    end subroutine fnf


    subroutine rk4(x,t)
        implicit none
        integer :: i,j,t
        real(kind=8) :: x(M,N),xx(N),fx(N)
        real(kind=8) :: kx1(N),kx2(N),kx3(N),kx4(N)
        do i=1,M,1
            xx=x(i,:)
            call fnf(xx,fx,i)
            kx1=h*fx
            xx=x(i,:)+0.5*kx1
            call fnf(xx,fx,i)
            kx2=h*fx
            xx=x(i,:)+0.5*kx2
            call fnf(xx,fx,i)
            kx3=h*fx
            xx=x(i,:)+kx3
            call fnf(xx,fx,i)
            kx4=h*fx
            x(i,:)=x(i,:)+(kx1+2.0*kx2+2.0*kx3+kx4)/6.0
        end do
        return
    end subroutine rk4

    !max与min
    subroutine Max_Min(xxx,max,min)
        implicit none
        real(kind=8) :: max(M),min(M),xxx(M)
        integer :: i
        do i=1,M,1
            if(max(i)<xxx(i)) then
                max(i)=xxx(i)
            end if
            if(min(i)>xxx(i)) then
                min(i)=xxx(i)
            end if
        end do
        return
    end subroutine Max_Min

    !建立网络矩阵
    subroutine neighbour(K)
        implicit none
        integer :: K !单节点K个邻居
        integer :: i,j,number
        allocate(neighbour_matrix(M,M))
        !初始化网络矩阵
        neighbour_matrix=0
        do i=1,M-1,1
            do j=i+1,M,1
                if(abs(i-j)<=K/2.or.abs(i-j)>=M-K/2) then
                    neighbour_matrix(i,j)=1
                    neighbour_matrix(j,i)=1
                end if
            end do
        end do
        !输出矩阵
!        do i=1,M,1
!            do j=1,M,1
!                write(10,"(I2)",advance='no') neighbour_matrix(i,j)
!            end do
!            write(10,*)
!        end do
        return
    end subroutine neighbour

end module Lorenz



program main
    use Lorenz
    implicit none
    integer :: i,j,t,Nc
    real(kind=8) :: max(M),min(M)
    open(10,file="neighbour_matrix.txt")
    open(20,file="x0.txt")
    open(30,file="c_M_max_min.txt")
    open(40,file="t_x_y_z_14.txt")
    open(50,file="t_x_y_z_15.txt")
    open(60,file="i_t_x_y_z.txt")
    open(70,file="i_t_x_y_z_kuaizhao.txt")
    open(80,file="i_t_x_y_z_all.txt")
    open(90,file="p_Nc.txt")
    do p=10,10,1
        max=-10000.0
        min=10000.0
        Nc=0
        call x0()
        call neighbour(2*p)
        do t=1,MaxT,1
            call rk4(x,t)
            if(t>T_trans) then
                call Max_Min(x(:,1),max,min)
!                write(40,"(4(F15.6))") (t-T_trans)*h,x(14,1),x(14,2),x(14,3)
!                write(50,"(4(F15.6))") (t-T_trans)*h,x(15,1),x(15,2),x(15,3)
                do i=1,M,1
                    write(80,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                    if(t-1==T_trans) then
                        write(70,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                    end if
                    if(mod(t,50)==0) then
                        write(60,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                    end if
                end do
            end if
        end do
        do j=1,M,1
            write(30,*) j,max(j),min(j)
            if((max(j)>0.and.min(j)>0).or.(max(j)<0.and.min(j)<0)) then
                Nc=Nc+1
            end if
        end do
        write(90,*) p,Nc
        write(*,*) p,Nc
        deallocate(neighbour_matrix)
    end do
end program main

figure 7_A

module Lorenz
    implicit none
    real,parameter :: h=0.001
    integer,parameter :: MaxT=2030000,T_trans=2000000,N=3,M=100
    real(kind=8) :: x(M,N)
    integer :: p
    integer,allocatable :: neighbour_matrix(:,:)
contains

    subroutine x0()
        implicit none
        integer :: i
        real :: x1,x2,x3
        call random_seed()
        do i=1,M,1
            call random_number(x1)
            call random_number(x2)
            call random_number(x3)
            x(i,1)=31.0*x1-14.0
            x(i,2)=44.0*x2-20.0
            x(i,3)=23.0*x3-1.0
            write(20,*) x(i,1),x(i,2),x(i,3)
        end do
    end subroutine x0

    subroutine fnf(xx,fx,i)
        implicit none
        real(kind=8) :: xx(N),fx(N)
        integer :: t,j,i
        real(kind=8) :: a,b,c,coupling,epsilon
        coupling=0.0
        epsilon=-7.5
        do j=1,M,1
            coupling=coupling+neighbour_matrix(i,j)*(x(j,1)-x(i,1))
        end do
        a=10.0
        b=2.0
        c=28.0
        fx(1)=a*(xx(2)-xx(1))+(epsilon/real(2.0*p))*coupling
        fx(2)=c*xx(1)-xx(1)*xx(3)-xx(2)
        fx(3)=xx(1)*xx(2)-b*xx(3)
        return
    end subroutine fnf


    subroutine rk4(x,t)
        implicit none
        integer :: i,j,t
        real(kind=8) :: x(M,N),xx(N),fx(N)
        real(kind=8) :: kx1(N),kx2(N),kx3(N),kx4(N)
        do i=1,M,1
            xx=x(i,:)
            call fnf(xx,fx,i)
            kx1=h*fx
            xx=x(i,:)+0.5*kx1
            call fnf(xx,fx,i)
            kx2=h*fx
            xx=x(i,:)+0.5*kx2
            call fnf(xx,fx,i)
            kx3=h*fx
            xx=x(i,:)+kx3
            call fnf(xx,fx,i)
            kx4=h*fx
            x(i,:)=x(i,:)+(kx1+2.0*kx2+2.0*kx3+kx4)/6.0
        end do
        return
    end subroutine rk4

    !max与min
    subroutine Max_Min(xxx,max,min)
        implicit none
        real(kind=8) :: max(M),min(M),xxx(M)
        integer :: i
        do i=1,M,1
            if(max(i)<xxx(i)) then
                max(i)=xxx(i)
            end if
            if(min(i)>xxx(i)) then
                min(i)=xxx(i)
            end if
        end do
        return
    end subroutine Max_Min

    !建立网络矩阵
    subroutine neighbour(K)
        implicit none
        integer :: K !单节点K个邻居
        integer :: i,j,number
        allocate(neighbour_matrix(M,M))
        !初始化网络矩阵
        neighbour_matrix=0
        do i=1,M-1,1
            do j=i+1,M,1
                if(abs(i-j)<=K/2.or.abs(i-j)>=M-K/2) then
                    neighbour_matrix(i,j)=1
                    neighbour_matrix(j,i)=1
                end if
            end do
        end do
        !输出矩阵
        !        do i=1,M,1
        !            do j=1,M,1
        !                write(10,"(I2)",advance='no') neighbour_matrix(i,j)
        !            end do
        !            write(10,*)
        !        end do
        return
    end subroutine neighbour

end module Lorenz



program main
    use Lorenz
    implicit none
    integer :: i,j,t,Nc,count
    real(kind=8) :: max(M),min(M),data_x(M),delta_D(M)
    real,allocatable :: delta_DD(:),delta_DDD(:),delta_X(:)
    open(10,file="neighbour_matrix.txt")
    open(20,file="x0.txt")
    open(30,file="c_M_max_min.txt")
    open(40,file="t_x_y_z_14.txt")
    open(50,file="t_x_y_z_15.txt")
    open(60,file="i_t_x_y_z.txt")
    open(70,file="i_t_x_y_z_kuaizhao.txt")
    open(80,file="i_t_x_y_z_all.txt")
    open(90,file="p_Nc_deltaD_deltaX.txt")
    do p=7,50,1
        max=-10000.0
        min=10000.0
        data_x=0.0
        delta_D=0.0
        count=1
        Nc=0
        call x0()
        call neighbour(2*p)
        do t=1,MaxT,1
            call rk4(x,t)
            if(t>T_trans) then
                call Max_Min(x(:,1),max,min)
                do i=1,M,1
                    if((t-T_trans)*h==20) then
                        data_x(i)=x(i,1)
!                        write(70,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                    end if
                end do
            end if
        end do
        do j=1,M-1,1
            write(30,*) j,max(j),min(j)
            if(((max(j)>0.and.min(j)>0).and.max(j+1)<0).or.((max(j)<0.and.min(j)<0).and.max(j+1)>0)) then
                delta_D(j)=j
                Nc=Nc+1
            end if
        end do
        allocate(delta_DD(Nc))
        allocate(delta_DDD(Nc))
        allocate(delta_X(Nc))
        delta_DD=0.0
        delta_DDD=0.0
        delta_X=0.0
        do j=1,M,1
            if(delta_D(j)>0.0) then
                delta_DD(count)=delta_D(j)
                count=count+1
            end if
        end do
        do j=1,Nc-1,1
            delta_DDD(j)=abs(delta_DD(j+1)-delta_DD(j))
            delta_X(j)=abs(maxval(data_x(delta_DD(j)+1:delta_DD(j+1)))-minval(data_x(delta_DD(j)+1:delta_DD(j+1))))
        end do
        write(*,*) p,Nc,"delta_X",maxval(delta_X(:)),"delta_DDD",maxval(delta_DDD(:))
        write(90,*) p,Nc,maxval(delta_X(:)),maxval(delta_DDD(:))
        deallocate(neighbour_matrix)
        deallocate(delta_DD)
        deallocate(delta_DDD)
        deallocate(delta_X)
    end do
end program main

image-20230110114406430

figure 7_B

image-20230107235844376

figure 7_C

image-20230107133829968

figure 7_D

  • p=28

image-20230107193140363

figure 7_E

image-20230107145648170

figure 7_F

  • p=44

image-20230107164749067

figure 8

image-20230102225836651

figure 8_A

image-20230106115333718

figure 8_B

image-20230106114959610

figure 8_C

image-20230110131653328

figure 8_D

p=28

image-20230110140013099

figure 8_E

image-20230110140736857

figure 8_F

  • p=44

image-20230110141337548

figure 9

image-20230102230040616

  • 时空斑图
module Lorenz
    implicit none
    real,parameter :: h=0.01
    integer,parameter :: MaxT=200300,T_trans=200000,N=3,M=100
    real(kind=8) :: x(M,N)
    integer :: p=35
    integer,allocatable :: neighbour_matrix(:,:)
contains

    subroutine x0()
        implicit none
        integer :: i
        real :: x1,x2,x3
        call random_seed()
        do i=1,M,1
            call random_number(x1)
            call random_number(x2)
            call random_number(x3)
            x(i,1)=31.0*x1-14.0
            x(i,2)=44.0*x2-20.0
            x(i,3)=23.0*x3-1.0
            write(20,*) x(i,1),x(i,2),x(i,3)
        end do
    end subroutine x0

    subroutine fnf(xx,fx,i)
        implicit none
        real(kind=8) :: xx(N),fx(N)
        integer :: t,j,i
        real(kind=8) :: a,b,c,coupling,epsilon
        coupling=0.0
        epsilon=-5.5
        do j=1,M,1
            coupling=coupling+neighbour_matrix(i,j)*(x(j,1)-x(i,1))
        end do
        a=10.0
        b=2.0
        c=28.0
        fx(1)=a*(xx(2)-xx(1))+(epsilon/real(2.0*p))*coupling
        fx(2)=c*xx(1)-xx(1)*xx(3)-xx(2)
        fx(3)=xx(1)*xx(2)-b*xx(3)
        return
    end subroutine fnf


    subroutine rk4(x,t)
        implicit none
        integer :: i,j,t
        real(kind=8) :: x(M,N),xx(N),fx(N)
        real(kind=8) :: kx1(N),kx2(N),kx3(N),kx4(N)
        do i=1,M,1
            xx=x(i,:)
            call fnf(xx,fx,i)
            kx1=h*fx
            xx=x(i,:)+0.5*kx1
            call fnf(xx,fx,i)
            kx2=h*fx
            xx=x(i,:)+0.5*kx2
            call fnf(xx,fx,i)
            kx3=h*fx
            xx=x(i,:)+kx3
            call fnf(xx,fx,i)
            kx4=h*fx
            x(i,:)=x(i,:)+(kx1+2.0*kx2+2.0*kx3+kx4)/6.0
        end do
        return
    end subroutine rk4

    !max与min
    subroutine Max_Min(xxx,max,min)
        implicit none
        real(kind=8) :: max(M),min(M),xxx(M)
        integer :: i
        do i=1,M,1
            if(max(i)<xxx(i)) then
                max(i)=xxx(i)
            end if
            if(min(i)>xxx(i)) then
                min(i)=xxx(i)
            end if
        end do
        return
    end subroutine Max_Min

    !建立网络矩阵
    subroutine neighbour(K)
        implicit none
        integer :: K !单节点K个邻居
        integer :: i,j,number
        allocate(neighbour_matrix(M,M))
        !初始化网络矩阵
        neighbour_matrix=0
        do i=1,M-1,1
            do j=i+1,M,1
                if(abs(i-j)<=K/2.or.abs(i-j)>=M-K/2) then
                    neighbour_matrix(i,j)=1
                    neighbour_matrix(j,i)=1
                end if
            end do
        end do
        !输出矩阵
        do i=1,M,1
            do j=1,M,1
                write(10,"(I2)",advance='no') neighbour_matrix(i,j)
            end do
            write(10,*)
        end do
        return
    end subroutine neighbour

end module Lorenz



program main
    use Lorenz
    implicit none
    integer :: i,j,t
    real(kind=8) :: max(M),min(M)
    open(10,file="neighbour_matrix.txt")
    open(20,file="x0.txt")
    open(30,file="c_M_max_min.txt")
    open(40,file="t_x_y_z_14.txt")
    open(50,file="t_x_y_z_15.txt")
    open(60,file="i_t_x_y_z.txt")
    open(70,file="i_t_x_y_z_kuaizhao.txt")
    open(80,file="i_t_x_y_z_all.txt")
    max=-10000.0
    min=10000.0
    call x0()
    call neighbour(2*p)
    do t=1,MaxT,1
        call rk4(x,t)
        if(t>T_trans) then
            call Max_Min(x(:,1),max,min)
            write(40,"(4(F15.6))") (t-T_trans)*h,x(14,1),x(14,2),x(14,3)
            write(50,"(4(F15.6))") (t-T_trans)*h,x(15,1),x(15,2),x(15,3)
            do i=1,M,1
                write(80,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                if(t-1==T_trans) then
                    write(70,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                end if
                if(mod(t,50)==0) then
                    write(60,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                end if
            end do
        end if
    end do
    do j=1,M,1
        write(30,*) j,max(j),min(j)
    end do
end program main
  • SI
module Lorenz
    implicit none
    real,parameter :: h=0.001
    integer,parameter :: MaxT=230000,T_trans=200000,N=3,M=100,mm=50
    real(kind=8) :: x(M,N),epsilon
    integer :: p=35
    integer,allocatable :: neighbour_matrix(:,:)
contains

    subroutine x0()
        implicit none
        integer :: i
        real :: x1,x2,x3
        call random_seed()
        do i=1,M,1
!            call random_number(x1)
!            call random_number(x2)
!            call random_number(x3)
!            x(i,1)=31.0*x1-14.0
!            x(i,2)=44.0*x2-20.0
!            x(i,3)=23.0*x3-1.0
            read(20,*) x(i,1),x(i,2),x(i,3)
        end do
    end subroutine x0

    subroutine fnf(xx,fx,i)
        implicit none
        real(kind=8) :: xx(N),fx(N)
        integer :: t,j,i
        real(kind=8) :: a,b,c,coupling
        coupling=0.0
        do j=1,M,1
            coupling=coupling+neighbour_matrix(i,j)*(x(j,1)-x(i,1))
        end do
        a=10.0
        b=2.0
        c=28.0
        fx(1)=a*(xx(2)-xx(1))+(epsilon/real(2.0*p))*coupling
        fx(2)=c*xx(1)-xx(1)*xx(3)-xx(2)
        fx(3)=xx(1)*xx(2)-b*xx(3)
        return
    end subroutine fnf


    subroutine rk4(x,t)
        implicit none
        integer :: i,j,t
        real(kind=8) :: x(M,N),xx(N),fx(N)
        real(kind=8) :: kx1(N),kx2(N),kx3(N),kx4(N)
        do i=1,M,1
            xx=x(i,:)
            call fnf(xx,fx,i)
            kx1=h*fx
            xx=x(i,:)+0.5*kx1
            call fnf(xx,fx,i)
            kx2=h*fx
            xx=x(i,:)+0.5*kx2
            call fnf(xx,fx,i)
            kx3=h*fx
            xx=x(i,:)+kx3
            call fnf(xx,fx,i)
            kx4=h*fx
            x(i,:)=x(i,:)+(kx1+2.0*kx2+2.0*kx3+kx4)/6.0
        end do
        return
    end subroutine rk4

    !max与min
    subroutine Max_Min(xxx,max,min)
        implicit none
        real(kind=8) :: max(M),min(M),xxx(M)
        integer :: i
        do i=1,M,1
            if(max(i)<xxx(i)) then
                max(i)=xxx(i)
            end if
            if(min(i)>xxx(i)) then
                min(i)=xxx(i)
            end if
        end do
        return
    end subroutine Max_Min

    !SI不相干强度
    subroutine SIM(Z)
        implicit none
        integer :: i,j,t,nn
        real(kind=8) :: delta
        real(kind=8) :: Z(M,MaxT-T_trans),sigma(mm),S(mm),ZZm(M,MaxT-T_trans),ZZ(MaxT-T_trans)
        real(kind=8) :: Sm,SI
        delta=1.0
        SI=0.0
        ZZm=0.0
        ZZ=0.0
        nn=M/mm
        do i=1,M-1,1
            do t=1,MaxT-T_trans,1
                ZZm(i,t)=Z(i,t)-Z(i+1,t)
            end do
        end do
        do t=1,MaxT-T_trans,1
            ZZ(t)=sum(ZZm(:,t))/real(M-1)
        end do
        sigma=0.0
        do j=1,m,1
            do i=nn*(j-1)+1,nn*j,1
                do t=1,MaxT-T_trans,1
                    sigma(j)=sigma(j)+(ZZm(i,t)-ZZ(t))**2
                end do
            end do
            sigma(j)=sqrt(sigma(j)/real(nn))/((MaxT-T_trans)*h)
        end do

        do j=1,mm,1
            Sm=sigma(j)-delta
            if(Sm>0.0) then
                S(j)=1.0
            else
                S(j)=0.0
            end if
        end do
        SI=sum(S(:))/real(mm)
        write(100,*) epsilon,SI
        write(*,*) epsilon,SI
        return
    end subroutine SIM

    !建立网络矩阵
    subroutine neighbour(K)
        implicit none
        integer :: K !单节点K个邻居
        integer :: i,j,number
        allocate(neighbour_matrix(M,M))
        !初始化网络矩阵
        neighbour_matrix=0
        do i=1,M-1,1
            do j=i+1,M,1
                if(abs(i-j)<=K/2.or.abs(i-j)>=M-K/2) then
                    neighbour_matrix(i,j)=1
                    neighbour_matrix(j,i)=1
                end if
            end do
        end do
        !输出矩阵
        !        do i=1,M,1
        !            do j=1,M,1
        !                write(10,"(I2)",advance='no') neighbour_matrix(i,j)
        !            end do
        !            write(10,*)
        !        end do
        return
    end subroutine neighbour

end module Lorenz



program main
    use Lorenz
    implicit none
    integer :: i,j,t,Nc,count
    real(kind=8) :: max(M),min(M),data_x(M),delta_D(M),Z(M,MaxT-T_trans)
!    real,allocatable :: delta_DD(:),delta_DDD(:),delta_X(:)
    open(10,file="neighbour_matrix.txt")
    open(20,file="x0.txt")
    open(30,file="c_M_max_min.txt")
    open(40,file="t_x_y_z_14.txt")
    open(50,file="t_x_y_z_15.txt")
    open(60,file="i_t_x_y_z.txt")
    open(70,file="i_t_x_y_z_kuaizhao.txt")
    open(80,file="i_t_x_y_z_all.txt")
    open(90,file="p_Nc_deltaD_deltaX.txt")
    open(100,file="epsilon_SI.txt")
    call x0()
    call neighbour(2*p)
    do epsilon=-5.0,-7.5,-0.1
        max=-10000.0
        min=10000.0
        data_x=0.0
        delta_D=0.0
        count=1
        Nc=0
        Z=0.0
        do t=1,MaxT,1
            call rk4(x,t)
            if(t>T_trans) then
!                call Max_Min(x(:,1),max,min)
                Z(:,t-T_trans)=x(:,3)
!                do i=1,M,1
!                    write(80,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
!                    if(t-1==T_trans) then
!                        data_x(i)=x(i,1)
!                        write(70,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
!                    end if
!                    if(mod(t,50)==0) then
!                        write(60,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
!                    end if
!                end do
            end if
        end do
        call SIM(Z)
!        do j=1,M-1,1
!            write(30,*) j,max(j),min(j)
!            if(((max(j)>0.and.min(j)>0).and.max(j+1)<0).or.((max(j)<0.and.min(j)<0).and.max(j+1)>0)) then
!                delta_D(j)=j
!                Nc=Nc+1
!            end if
!        end do
!        allocate(delta_DD(Nc))
!        allocate(delta_DDD(Nc))
!        allocate(delta_X(Nc))
!        delta_DD=0.0
!        delta_DDD=0.0
!        delta_X=0.0
!        do j=1,M,1
!            if(delta_D(j)>0.0) then
!                delta_DD(count)=delta_D(j)
!                count=count+1
!            end if
!        end do
!        do j=1,Nc-1,1
!            delta_DDD(j)=abs(delta_DD(j+1)-delta_DD(j))
!            delta_X(j)=abs(maxval(data_x(delta_DD(j)+1:delta_DD(j+1)))-minval(data_x(delta_DD(j)+1:delta_DD(j+1))))
!        end do
!        write(*,*) p,Nc,"delta_X",maxval(delta_X(:)),"delta_DDD",maxval(delta_DDD(:))
!        write(90,*) p,Nc,maxval(delta_X(:)),maxval(delta_DDD(:))
!        deallocate(delta_DD)
!        deallocate(delta_DDD)
!        deallocate(delta_X)
    end do
    deallocate(neighbour_matrix)
end program main

figure 9_A

image-20230110182733893

figure 9_B

image-20230106121410316

figure 9_C

image-20230106131355656

figure 9_D

image-20230106124143369

figure 9_E

image-20230106132939028

figure 9_F

image-20230106125658517

figure 9_G

image-20230106133841033

module Lorenz
    implicit none
    real,parameter :: h=0.01
    integer,parameter :: MaxT=200300,T_trans=200000,N=3,M=100
    real(kind=8) :: x(M,N)
    integer :: p=35
    integer,allocatable :: neighbour_matrix(:,:)
contains

    subroutine x0()
        implicit none
        integer :: i
        real :: x1,x2,x3
        call random_seed()
        do i=1,M,1
            !call random_number(x1)
            !call random_number(x2)
            !call random_number(x3)
            !x(i,1)=31.0*x1-14.0
            !x(i,2)=44.0*x2-20.0
            !x(i,3)=23.0*x3-1.0
            read(20,*) x(i,1),x(i,2),x(i,3)
        end do
    end subroutine x0

    subroutine fnf(xx,fx,i)
        implicit none
        real(kind=8) :: xx(N),fx(N)
        integer :: t,j,i
        real(kind=8) :: a,b,c,coupling,epsilon
        coupling=0.0
        epsilon=-7.0
        do j=1,M,1
            coupling=coupling+neighbour_matrix(i,j)*(x(j,1)-x(i,1))
        end do
        a=10.0
        b=2.0
        c=28.0
        fx(1)=a*(xx(2)-xx(1))+(epsilon/real(2.0*p))*coupling
        fx(2)=c*xx(1)-xx(1)*xx(3)-xx(2)
        fx(3)=xx(1)*xx(2)-b*xx(3)
        return
    end subroutine fnf


    subroutine rk4(x,t)
        implicit none
        integer :: i,j,t
        real(kind=8) :: x(M,N),xx(N),fx(N)
        real(kind=8) :: kx1(N),kx2(N),kx3(N),kx4(N)
        do i=1,M,1
            xx=x(i,:)
            call fnf(xx,fx,i)
            kx1=h*fx
            xx=x(i,:)+0.5*kx1
            call fnf(xx,fx,i)
            kx2=h*fx
            xx=x(i,:)+0.5*kx2
            call fnf(xx,fx,i)
            kx3=h*fx
            xx=x(i,:)+kx3
            call fnf(xx,fx,i)
            kx4=h*fx
            x(i,:)=x(i,:)+(kx1+2.0*kx2+2.0*kx3+kx4)/6.0
        end do
        return
    end subroutine rk4

    !max与min
    subroutine Max_Min(xxx,max,min)
        implicit none
        real(kind=8) :: max(M),min(M),xxx(M)
        integer :: i
        do i=1,M,1
            if(max(i)<xxx(i)) then
                max(i)=xxx(i)
            end if
            if(min(i)>xxx(i)) then
                min(i)=xxx(i)
            end if
        end do
        return
    end subroutine Max_Min

    !建立网络矩阵
    subroutine neighbour(K)
        implicit none
        integer :: K !单节点K个邻居
        integer :: i,j,number
        allocate(neighbour_matrix(M,M))
        !初始化网络矩阵
        neighbour_matrix=0
        do i=1,M-1,1
            do j=i+1,M,1
                if(abs(i-j)<=K/2.or.abs(i-j)>=M-K/2) then
                    neighbour_matrix(i,j)=1
                    neighbour_matrix(j,i)=1
                end if
            end do
        end do
        !输出矩阵
        do i=1,M,1
            do j=1,M,1
                write(10,"(I2)",advance='no') neighbour_matrix(i,j)
            end do
            write(10,*)
        end do
        return
    end subroutine neighbour

end module Lorenz



program main
    use Lorenz
    implicit none
    integer :: i,j,t
    real(kind=8) :: max(M),min(M)
    open(10,file="neighbour_matrix.txt")
    open(20,file="x0.txt")
    open(30,file="c_M_max_min.txt")
    open(40,file="t_x_y_z_14.txt")
    open(50,file="t_x_y_z_15.txt")
    open(60,file="i_t_x_y_z.txt")
    open(70,file="i_t_x_y_z_kuaizhao.txt")
    open(80,file="i_t_x_y_z_all.txt")
    max=-10000.0
    min=10000.0
    call x0()
    call neighbour(2*p)
    do t=1,MaxT,1
        call rk4(x,t)
        if(t>T_trans) then
            call Max_Min(x(:,1),max,min)
            write(40,"(4(F15.6))") (t-T_trans)*h,x(14,1),x(14,2),x(14,3)
            write(50,"(4(F15.6))") (t-T_trans)*h,x(15,1),x(15,2),x(15,3)
            do i=1,M,1
                write(80,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                if(t-1==T_trans) then
                    write(70,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                end if
                if(mod(t,50)==0) then
                    write(60,"(5(F15.6))") real(i),(t-T_trans)*h,x(i,1),x(i,2),x(i,3)
                end if
            end do
        end if
    end do
    do j=1,M,1
        write(30,*) j,max(j),min(j)
    end do
end program main

文章作者: rep-rebirth
版权声明: 本博客所有文章除特別声明外,均采用 CC BY 4.0 许可协议。转载请注明来源 rep-rebirth !
评论
评论
  目录