ps_SetEvaluatorOptions Subroutine

public subroutine ps_SetEvaluatorOptions(quality_level, debug, use_effective_range, custom_interpolator)

Sets various parameters for the operation of the evaluator

Arguments

Type IntentOptional Attributes Name
integer, intent(in), optional :: quality_level
logical, intent(in), optional :: debug
logical, intent(in), optional :: use_effective_range
procedure(interp), optional :: custom_interpolator

Contents


Source Code

subroutine ps_SetEvaluatorOptions(quality_level,debug,&
     use_effective_range,&
     custom_interpolator)

use m_psml_interp, only: nq, interpolator

! Parameter for interpolator's quality
! It might mean different things for different
! interpolators
integer, intent(in), optional :: quality_level

logical, intent(in), optional :: debug
logical, intent(in), optional :: use_effective_range

interface
   subroutine interp(nquality,x,y,npts,r,val,debug)

     integer, parameter :: dp = selected_real_kind(10,100)

     integer, intent(in)  :: nquality  ! Quality parameter
     real(dp), intent(in) :: x(*), y(*)
     integer, intent(in)  :: npts    ! Size of x, y arrays
     real(dp), intent(in) :: r
     real(dp), intent(out):: val
     logical, intent(in) :: debug
   end subroutine interp
end interface

procedure(interp), optional :: custom_interpolator

if (present(quality_level)) then
   nq = quality_level
endif
if (present(debug)) then
   global_debug = debug
endif
if (present(use_effective_range)) then
   global_use_effective_range = use_effective_range
endif
if (present(custom_interpolator)) then
   interpolator => custom_interpolator
endif

end subroutine ps_SetEvaluatorOptions