smdogroup / tacs

Finite-element library for analysis and adjoint-based gradient evaluation
Apache License 2.0
108 stars 75 forks source link

Update test_trans_beam FD step size #317

Closed A-CGray closed 5 months ago

A-CGray commented 5 months ago

Similar to #316 , we are seeing some hard to reproduce test failures in the xpt sens test in test_trans_beam. I can't be 100% sure that this step size change fixes the error but it does reduce the largest relative error by roughly 2 orders of magnitude:

Before:

Testing sinusoid_compliance xpt sens:
analytic: 12.398071807030135
      FD: 12.397875767788946
    diff: 0.00019603924118882787
rel diff: 1.581207499360238e-05

After:

Testing sinusoid_compliance xpt sens:
analytic: 12.398070774567254
      FD: 12.398069415553437
    diff: 1.3590138170371802e-06
rel diff: 1.0961494265906186e-07