EMPIRE DA  v1.9.1
Data assimilation codes using EMPIRE communication
 All Classes Files Functions Variables Pages
call.f90
Go to the documentation of this file.
1 program call
2 implicit none
3 integer :: i
4 
5 integer :: n !size of optimization state vector
6 integer :: method ! the type of nonlinear cg
7 
8 real(kind=kind(1.0d0)), allocatable, dimension(:) :: x0
9 real(kind=kind(1.0d0)) :: epsin=0.1d0
10 n = 2 !rosenbrock test function
11 
12 
13 
14 
15 !method = 1 ! FLETCHER-REEVES
16 method = 2 ! POLAK-RIBIERE
17 !method = 3 ! POSITIVE POLAK-RIBIERE ( BETA=MAX{BETA,0} )
18 
19 allocate(x0(n))
20 do i=1,n
21  x0(i) = -2.d+00
22 end do
23 
24 
25 
26 
27 call subroutine_cg(method,n,epsin,x0)
28 
29 
30 deallocate(x0)
31 end program call
subroutine subroutine_cg(method, n, epsin, x)
Nonlinear Conjugate gradient method as callable subroutine.
Definition: cgsub.f90:27
program call
Definition: call.f90:1