Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed tudat tests due to arm64 architecture #2

Open
FilippoOggionni opened this issue May 7, 2021 · 0 comments
Open

Failed tudat tests due to arm64 architecture #2

FilippoOggionni opened this issue May 7, 2021 · 0 comments

Comments

@FilippoOggionni
Copy link
Member

FilippoOggionni commented May 7, 2021

When running the tudat tests through ctest, 5 of them fail (apparently due to differences in floating-point precision for different architectures).
I am using a MacBook Pro with M1 Apple Silicon processor. Failing test are:

The following tests FAILED:
         12 - test_basic_astro_OrbitalElementConversions (Failed)
         22 - test_basic_astro_TimeConversions (Failed)
         32 - test_basic_astro_EmpiricalAcceleration (Failed)
        143 - test_propagators_VariationalEquations (Failed)
        161 - test_basics_TimeTypes (Failed)

Copying and pasting from internal discussion (@DominicDirkx):

Test back and forth TCG<->TT at t=0, and expected value of TCG at TT=0..
    long double testTime = 0.0L;
    testTcg = convertTtToTcg< long double >( testTime);
    testTt = convertTcgToTt< long double >( testTcg );
    long double expectedTcg = -secondsSinceJ2000Synchronization * LG_TIME_RATE_TERM_LONG /
            ( 1.0L - LG_TIME_RATE_TERM_LONG);
    BOOST_CHECK_CLOSE_FRACTION( testTcg, expectedTcg, 2.0 * std::numeric_limits< long double >::epsilon( ) );
    BOOST_CHECK_CLOSE_FRACTION( testTt, testTime, 2.0 * std::numeric_limits< long double >::epsilon( ) ); 

are using the wrong test, I think (should be CHECK_SMALL, not CHECK_CLOSE_FRACTION).
Looking at this, I think that the long double is implemented as 64 bit, not 80 bits. Not a big problem, but good to be aware of

Full test output is attached here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: tudat-bundle
Development

No branches or pull requests

1 participant