1
0
mirror of https://github.com/paboyle/Grid.git synced 2024-11-09 23:45:36 +00:00

Added automated HMC test for Nc=4

This commit is contained in:
Julian Lenz 2023-05-15 18:37:33 +01:00
parent 8522352aa3
commit eee27b8b30
2 changed files with 11 additions and 1 deletions

View File

@ -6,3 +6,4 @@ check: tests
./Test_project_on_Sp
./Test_sp2n_lie_gen
./Test_Sp_start
./Test_hmc_Sp_Wilson2ASFermionGauge --grid 4.4.4.4 --Trajectories 1 --Thermalizations 0 --StartingType ColdStart --assert=true

View File

@ -1,6 +1,6 @@
#include <Grid/Grid.h>
int main(int argc, char **argv) {
int main(int argc, char** argv) {
using namespace Grid;
typedef Representations<SpFundamentalRepresentation,
@ -77,6 +77,15 @@ int main(int argc, char **argv) {
TheHMC.ReadCommandLine(argc, argv);
TheHMC.Run();
if (std::string(argv[argc - 1]).compare("--assert=true") == 0) {
// this is the pseudofermion action's value for
// --grid 4.4.4.4 --Trajectories 1 --Thermalizations 0 --StartingType
// ColdStart and Nc == 4 if this assertion fails, check that you have run
// with these exact parameters
assert(Nc == 4);
assert(abs(Nf2.S(U) - 6586.6498) < 1.e-4);
}
Grid_finalize();
}