For constant input, scale() should return the upper bound b everywhere.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(inout) | :: | id | |||
| integer, | intent(inout) | :: | nfail |
subroutine test_016(id, nfail) use forcolormap_parameters, only: wp use forcolormap_utils, only: scale integer, intent(inout) :: id, nfail character(len=*), parameter :: name = "scale(real,real): constant array -> b" logical :: ok real(wp), parameter :: tol = 1.0e-12_wp real(wp) :: x(5), y(5) x = 7.0_wp y = scale(x, -1.0_wp, 2.0_wp) ok = all(abs(y - 2.0_wp) <= tol) call report_test(name, ok, id, nfail) end subroutine test_016