Gromacs
2024.4
|
Inherits TestWithParam< std::tuple< ConstraintsTestSystem, t_pbc > >.
Test fixture for constraints.
The fixture uses following test systems:
For all systems, the final lengths of the constraints are tested against the reference values, the direction of each constraint is checked. Test also verifies that the center of mass has not been shifted by the constraints and that its velocity has not changed. For some systems, the value for scaled virial tensor is checked against pre-computed data.
Public Member Functions | |
void | checkFinalPositions (const ConstraintsTestData &testData) |
Test if the final position correspond to the reference data. More... | |
void | checkFinalVelocities (const ConstraintsTestData &testData) |
Test if the final velocities correspond to the reference data. More... | |
void | checkVirialTensor (const ConstraintsTestData &testData) |
The test of virial tensor. More... | |
Static Public Member Functions | |
static void | checkConstrainsLength (FloatingPointTolerance tolerance, const ConstraintsTestData &testData, t_pbc pbc) |
The test on the final length of constrained bonds. More... | |
static void | checkConstrainsDirection (const ConstraintsTestData &testData, t_pbc pbc) |
The test on the final length of constrained bonds. More... | |
static void | checkCOMCoordinates (FloatingPointTolerance tolerance, const ConstraintsTestData &testData) |
The test on the coordinates of the center of the mass (COM) of the system. More... | |
static void | checkCOMVelocity (FloatingPointTolerance tolerance, const ConstraintsTestData &testData) |
The test on the velocity of the center of the mass (COM) of the system. More... | |
static std::vector < std::unique_ptr < IConstraintsTestRunner > > | getRunners () |
Before any test is run, work out whether any compatible GPUs exist. | |
Public Attributes | |
TestReferenceData | refData_ |
Reference data. | |
TestReferenceChecker | checker_ |
Checker for reference data. | |
|
inlinestatic |
The test on the coordinates of the center of the mass (COM) of the system.
Checks if the center of mass has not been shifted by the constraints. Note, that this test does not take into account the periodic boundary conditions. Hence it will not work should the constraints decide to move atoms across PBC borders.
[in] | tolerance | Allowed tolerance in COM coordinates. |
[in] | testData | Test data structure. |
|
inlinestatic |
The test on the velocity of the center of the mass (COM) of the system.
Checks if the velocity of the center of mass has not changed.
[in] | tolerance | Allowed tolerance in COM velocity components. |
[in] | testData | Test data structure. |
|
inlinestatic |
The test on the final length of constrained bonds.
Goes through all the constraints and checks if the direction of constraint has not changed by the algorithm (i.e. the constraints algorithm arrived to the solution that is closest to the initial system conformation).
[in] | testData | Test data structure. |
[in] | pbc | Periodic boundary data. |
|
inlinestatic |
The test on the final length of constrained bonds.
Goes through all the constraints and checks if the final length of all the constraints is equal to the target length with provided tolerance.
[in] | tolerance | Allowed tolerance in final lengths. |
[in] | testData | Test data structure. |
[in] | pbc | Periodic boundary data. |
|
inline |
Test if the final position correspond to the reference data.
[in] | testData | Test data structure. |
|
inline |
Test if the final velocities correspond to the reference data.
[in] | testData | Test data structure. |
|
inline |
The test of virial tensor.
Checks if the values in the scaled virial tensor are equal to pre-computed values.
[in] | testData | Test data structure. |