Skip to content

Commit

Permalink
use abs instead of fabs
Browse files Browse the repository at this point in the history
  • Loading branch information
TimSiebert1 committed Nov 4, 2024
1 parent 191f9f6 commit 9d3bf73
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions ADOL-C/src/drivers/psdrivers.c
Original file line number Diff line number Diff line change
Expand Up @@ -143,12 +143,11 @@ int directional_active_gradient(short tag, /* trace identifier */
sum = 0;
for(i=0;i<s;i++)
{
sum += fabs((double)sigma_g[i]);
sum += abs(sigma_g[i]);
}

if (sum == s)
{

zos_pl_forward(tag,1,n,keep,x,&y,z);
fos_pl_sig_reverse(tag,1,n,s,sigma_g, &by ,g);
done = 1;
Expand Down

0 comments on commit 9d3bf73

Please sign in to comment.