Skip to content

Commit 8dec603

Browse files
jalveszCopilot
andauthored
Update test/intrinsics/test_intrinsics.fypp
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent d46b7a9 commit 8dec603

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/intrinsics/test_intrinsics.fypp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ subroutine test_dot_product(error)
262262
p(1) = dot_product(x,y) ! compiler intrinsic
263263
p(2) = stdlib_dot_product_kahan(x,y) ! chunked Kahan dot_product
264264
p(3) = stdlib_dot_product(x,y) ! chunked dot_product
265-
err(1:2) = ( abs( p(2:3)%re - p(1)%re ) + abs( p(2:3)%im - p(1)%im ) ) / 2
265+
err(1:2) = sqrt((p(2:3)%re - p(1)%re)**2 + (p(2:3)%im - p(1)%im)**2)
266266

267267
call check(error, all(err(:)<tolerance) , "complex dot_product does not conform to the standard" )
268268
if (allocated(error)) return

0 commit comments

Comments
 (0)