Default ODR job, with parameter bounds. This sample problem comes from Zwolak et al. 2001 (High Performance Computing Symposium, "Estimating rate constants in cell cycle models"). The call to ODRPACK95 is modified from the call the authors make to ODRPACK. This is done to illustrate the need for bounds. The authors could just have easily used the call statement here to solve their problem. Curious users are encouraged to remove the bounds in the call statement, run the code, and compare the results to the current call statement.
Type | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|
real(kind=wp) | :: | beta(3) | = | [1.1E-0_wp, 3.3E+0_wp, 8.7_wp] | ||
integer | :: | lunrpt |
program example4 !! Default ODR job, with parameter bounds. !! This sample problem comes from Zwolak et al. 2001 (High Performance Computing !! Symposium, "Estimating rate constants in cell cycle models"). The call to !! ODRPACK95 is modified from the call the authors make to ODRPACK. This is !! done to illustrate the need for bounds. The authors could just have easily !! used the call statement here to solve their problem. !! Curious users are encouraged to remove the bounds in the call statement, !! run the code, and compare the results to the current call statement. use odrpack_kinds, only: wp use odrpack, only: odr use example4_model, only: fcn implicit none real(kind=wp) :: beta(3) = [1.1E-0_wp, 3.3E+0_wp, 8.7_wp] integer :: lunrpt ! INTEGER :: I ! REAL (KIND=wp) :: C, M, TOUT open (newunit=lunrpt, file="./example/report4.dat") call odr(fcn, & n=5, m=1, np=3, nq=1, & beta=beta, & y=reshape([55.0_wp, 45.0_wp, 40.0_wp, 30.0_wp, 20.0_wp], [5, 1]), & x=reshape([0.15_wp, 0.20_wp, 0.25_wp, 0.30_wp, 0.50_wp], [5, 1]), & lower=[0.0_wp, 0.0_wp, 0.0_wp], & upper=[1000.0_wp, 1000.0_wp, 1000.0_wp], & iprint=2122, & lunrpt=lunrpt, & maxit=20) close (9) ! The following code will reproduce the plot in Figure 2 of Zwolak et al. 2001. ! DO I = 0, 100 ! C = 0.05 + (0.7 - 0.05)*I/100 ! TOUT = 1440.0D0 ! !CALL MPF(M,C,1.1D-10,3.3D-3,8.7D0,0.0D0,TOUT,C/2) ! CALL MPF(M, C, 1.15395968E-02_wp, 2.61676386E-03_wp, & ! 9.23138811E+00_wp, 0.0D0, TOUT, C/2) ! WRITE (*, *) C, TOUT ! END DO end program example4