cfft_nd_backward Subroutine

public subroutine cfft_nd_backward(func, n, lot)

Arguments

Type IntentOptional Attributes Name
complex(kind=8), intent(inout), dimension(:) :: func
integer, intent(in) :: n
integer, intent(in) :: lot

Calls

proc~~cfft_nd_backward~~CallsGraph proc~cfft_nd_backward cfft_nd_backward cfftmb cfftmb proc~cfft_nd_backward->cfftmb cfftmi cfftmi proc~cfft_nd_backward->cfftmi

Called by

proc~~cfft_nd_backward~~CalledByGraph proc~cfft_nd_backward cfft_nd_backward interface~ifftn ifftn interface~ifftn->proc~cfft_nd_backward

Source Code

  subroutine cfft_nd_backward(func,n,lot)
    complex(8),dimension(:),intent(inout) :: func
    integer,intent(in)                    :: n,lot
    real(8),dimension(:),allocatable      :: wsave,work
    integer                               :: L,lenwrk,lensav,lenc,ier,inc,jump
    L=size(func)
    if(mod(N*lot,L)/=0)stop "cfft_Nd_backward: incommensurate values of parameters." 
    !
    lenc   = N*lot
    lenwrk = 2*N*lot
    lensav = 2*N + int(log(dble(N))/log(2.d0)) + 4
    allocate(wsave(lensav))
    allocate(work(lenwrk))
    call cfftmi(N,wsave,lensav,ier)
    if(ier==2)stop "cfft_Nd_backward: LENSAV not big enough"
    !
    jump   = N
    inc    = 1
    call cfftmb(lot,jump,N,inc,func,lenc,wsave,lensav,work,lenwrk,ier)
    deallocate(wsave,work)
    select case(ier)
    case (0)
       return
    case (1)
       stop "cfft_Nd_backward: LENR   not big enough"
    case (2)
       stop "cfft_Nd_backward: LENSAV not big enough"
    case (3)
       stop "cfft_Nd_backward: LENWRK not big enough"
    case (4)
       stop "cfft_Nd_backward: INC,JUMP,N,LOT are not consistent"
    end select
  end subroutine cfft_nd_backward