Sets various parameters for the operation of the evaluator
Type | Intent | Optional | 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 |
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