Skip to content

Commit fd9b3d2

Browse files
committed
fixed typos
1 parent e7a0181 commit fd9b3d2

File tree

6 files changed

+8
-6
lines changed

6 files changed

+8
-6
lines changed

test/test_chkder.f90

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ program test_chkder
3232
[.false., .false., .false., .true., .false., .false., .false., &
3333
.true., .false., .false., .false., .false., .true., .false.]
3434
real(wp), parameter :: one = 1.0_wp
35+
real(wp), parameter :: tol = sqrt(dpmpar(1)) !! abstol for matching previously generated solutions
3536
real(wp), parameter :: solution_reltol = 1.0e-4_wp !! reltol for matching previously generated solutions
3637

3738
cp = 1.23e-1_wp
@@ -93,7 +94,8 @@ program test_chkder
9394
write (nwrite, '(//5x, a//(5x, 5d15.7))') ' ERROR VECTOR', (err(i), i=1, n)
9495

9596
! compare with previously generated solutions:
96-
if (any(abs((solution(nprob) - diff)/(solution(nprob))) > solution_reltol)) then
97+
if (any(abs(solution(nprob) - diff)>tol) .and. &
98+
any(abs((solution(nprob) - diff)/(solution(nprob))) > solution_reltol)) then
9799
write(nwrite,'(A)') 'Failed case'
98100
write(nwrite, '(//5x, a//(5x, 5d15.7))') 'Expected diff: ', solution(nprob)
99101
write(nwrite, '(/5x, a//(5x, 5d15.7))') 'Computed diff: ', diff

test/test_hybrd.f90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ program test
8383
factor = ten*factor
8484

8585
! compare with previously generated solutions:
86-
if (any(abs(solution(ic) - x))>tol .and. &
86+
if (any(abs(solution(ic) - x)>tol) .and. &
8787
any(abs((solution(ic) - x)/(solution(ic))) > solution_reltol)) then
8888
write(nwrite,'(A)') 'Failed case'
8989
write(nwrite, '(//5x, a//(5x, 5d15.7))') 'Expected x: ', solution(ic)

test/test_hybrj.f90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ program test_hybrj
8787
factor = ten*factor
8888

8989
! compare with previously generated solutions:
90-
if (any(abs(solution(ic) - x))>tol .and. &
90+
if (any(abs(solution(ic) - x)>tol) .and. &
9191
any(abs((solution(ic) - x)/(solution(ic))) > solution_reltol)) then
9292
write(nwrite,'(A)') 'Failed case'
9393
write(nwrite, '(//5x, a//(5x, 5d15.7))') 'Expected x: ', solution(ic)

test/test_lmder.f90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ program test
9393
factor = ten*factor
9494

9595
! compare with previously generated solutions:
96-
if (any(abs(solution(ic) - x))>tol .and. &
96+
if (any(abs(solution(ic) - x)>tol) .and. &
9797
any(abs((solution(ic) - x)/(solution(ic))) > solution_reltol)) then
9898
write(nwrite,'(A)') 'Failed case'
9999
write(nwrite, '(//5x, a//(5x, 5d15.7))') 'Expected x: ', solution(ic)

test/test_lmdif.f90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ program test
8686
factor = ten*factor
8787

8888
! compare with previously generated solutions:
89-
if (any(abs(solution(ic) - x))>tol .and. &
89+
if (any(abs(solution(ic) - x)>tol) .and. &
9090
any(abs((solution(ic) - x)/(solution(ic))) > solution_reltol)) then
9191
write(nwrite,'(A)') 'Failed case'
9292
write(nwrite, '(//5x, a//(5x, 5d15.7))') 'Expected x: ', solution(ic)

test/test_lmstr.f90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ program test
9191
factor = ten*factor
9292

9393
! compare with previously generated solutions:
94-
if (any(abs(solution(ic) - x))>tol .and. &
94+
if (any(abs(solution(ic) - x)>tol) .and. &
9595
any(abs((solution(ic) - x)/(solution(ic))) > solution_reltol)) then
9696
write(nwrite,'(A)') 'Failed case'
9797
write(nwrite, '(//5x, a//(5x, 5d15.7))') 'Expected x: ', solution(ic)

0 commit comments

Comments
 (0)