mirror of
				https://github.com/paboyle/Grid.git
				synced 2025-11-03 13:34:33 +00:00 
			
		
		
		
	Unified integrator and integrator algorithm into virtual class used as a policy for the
HMC.
This commit is contained in:
		@@ -47,14 +47,13 @@ int main (int argc, char ** argv)
 | 
			
		||||
  FullSet.push_back(Level1);
 | 
			
		||||
 | 
			
		||||
  // Create integrator
 | 
			
		||||
  //  typedef LeapFrog  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  typedef MinimumNorm2<LatticeGaugeField>  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  IntegratorParameters MDpar(12,20,1.0);
 | 
			
		||||
  Integrator<LatticeGaugeField,IntegratorAlgorithm> MDynamics(UGrid,MDpar, FullSet);
 | 
			
		||||
  typedef MinimumNorm2<LatticeGaugeField>  IntegratorType;// change here to change the algorithm
 | 
			
		||||
  IntegratorParameters MDpar(20);
 | 
			
		||||
  IntegratorType MDynamics(UGrid,MDpar, FullSet);
 | 
			
		||||
 | 
			
		||||
  // Create HMC
 | 
			
		||||
  HMCparameters HMCpar;
 | 
			
		||||
  HybridMonteCarlo<LatticeGaugeField,IntegratorAlgorithm>  HMC(HMCpar, MDynamics,sRNG,pRNG);
 | 
			
		||||
  HybridMonteCarlo<LatticeGaugeField,IntegratorType>  HMC(HMCpar, MDynamics,sRNG,pRNG);
 | 
			
		||||
 | 
			
		||||
  // Run it
 | 
			
		||||
  HMC.evolve(U);
 | 
			
		||||
 
 | 
			
		||||
@@ -52,8 +52,8 @@ int main (int argc, char ** argv)
 | 
			
		||||
  //  typedef LeapFrog  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  //  IntegratorParameters MDpar(12,40,1.0);
 | 
			
		||||
  typedef MinimumNorm2<LatticeGaugeField>  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  IntegratorParameters MDpar(12,10,1.0);
 | 
			
		||||
  Integrator<LatticeGaugeField,IntegratorAlgorithm> MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
  IntegratorParameters MDpar(10);
 | 
			
		||||
  IntegratorAlgorithm MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
 | 
			
		||||
  // Create HMC
 | 
			
		||||
  HMCparameters HMCpar;
 | 
			
		||||
 
 | 
			
		||||
@@ -51,8 +51,8 @@ int main (int argc, char ** argv)
 | 
			
		||||
  // Create integrator
 | 
			
		||||
  typedef MinimumNorm2<LatticeGaugeField>  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  //  typedef LeapFrog  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  IntegratorParameters MDpar(12,20,1.0);
 | 
			
		||||
  Integrator<LatticeGaugeField,IntegratorAlgorithm> MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
  IntegratorParameters MDpar(20);
 | 
			
		||||
  IntegratorAlgorithm MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
 | 
			
		||||
  // Create HMC
 | 
			
		||||
  HMCparameters HMCpar;
 | 
			
		||||
 
 | 
			
		||||
@@ -52,8 +52,8 @@ int main (int argc, char ** argv)
 | 
			
		||||
  // Create integrator
 | 
			
		||||
  typedef MinimumNorm2<LatticeGaugeField>  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  //  typedef LeapFrog  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  IntegratorParameters MDpar(12,20,1.0);
 | 
			
		||||
  Integrator<LatticeGaugeField,IntegratorAlgorithm> MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
  IntegratorParameters MDpar(20);
 | 
			
		||||
  IntegratorAlgorithm MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
 | 
			
		||||
  // Create HMC
 | 
			
		||||
  HMCparameters HMCpar;
 | 
			
		||||
 
 | 
			
		||||
@@ -47,8 +47,8 @@ int main (int argc, char ** argv)
 | 
			
		||||
 | 
			
		||||
  // Create integrator
 | 
			
		||||
  typedef MinimumNorm2<LatticeGaugeField>  IntegratorAlgorithm;// change here to modify the algorithm
 | 
			
		||||
  IntegratorParameters MDpar(12,20,1.0);
 | 
			
		||||
  Integrator<LatticeGaugeField,IntegratorAlgorithm> MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
  IntegratorParameters MDpar(20);
 | 
			
		||||
  IntegratorAlgorithm  MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
 | 
			
		||||
  // Create HMC
 | 
			
		||||
  HMCparameters HMCpar;
 | 
			
		||||
 
 | 
			
		||||
@@ -51,8 +51,8 @@ int main (int argc, char ** argv)
 | 
			
		||||
  // Create integrator
 | 
			
		||||
  typedef MinimumNorm2<LatticeGaugeField>  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  //  typedef LeapFrog  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  IntegratorParameters MDpar(12,20,1.0);
 | 
			
		||||
  Integrator<LatticeGaugeField,IntegratorAlgorithm> MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
  IntegratorParameters MDpar(20);
 | 
			
		||||
  IntegratorAlgorithm MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
 | 
			
		||||
  // Create HMC
 | 
			
		||||
  HMCparameters HMCpar;
 | 
			
		||||
 
 | 
			
		||||
@@ -52,8 +52,8 @@ int main (int argc, char ** argv)
 | 
			
		||||
  // Create integrator
 | 
			
		||||
  typedef MinimumNorm2<LatticeGaugeField>  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
 | 
			
		||||
  IntegratorParameters MDpar(12,20,1.0);
 | 
			
		||||
  Integrator<LatticeGaugeField,IntegratorAlgorithm> MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
  IntegratorParameters MDpar(20);
 | 
			
		||||
  IntegratorAlgorithm MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
 | 
			
		||||
  // Create HMC
 | 
			
		||||
  HMCparameters HMCpar;
 | 
			
		||||
 
 | 
			
		||||
@@ -54,8 +54,8 @@ int main (int argc, char ** argv)
 | 
			
		||||
  // Create integrator
 | 
			
		||||
  typedef MinimumNorm2<LatticeGaugeField>  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  //  typedef LeapFrog  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  IntegratorParameters MDpar(12,20,1.0);
 | 
			
		||||
  Integrator<LatticeGaugeField,IntegratorAlgorithm> MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
  IntegratorParameters MDpar(20);
 | 
			
		||||
  IntegratorAlgorithm MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
 | 
			
		||||
  // Create HMC
 | 
			
		||||
  HMCparameters HMCpar;
 | 
			
		||||
 
 | 
			
		||||
@@ -52,8 +52,8 @@ int main (int argc, char ** argv)
 | 
			
		||||
  // Create integrator
 | 
			
		||||
  typedef MinimumNorm2<LatticeGaugeField>  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
 | 
			
		||||
  IntegratorParameters MDpar(12,20,1.0);
 | 
			
		||||
  Integrator<LatticeGaugeField,IntegratorAlgorithm> MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
  IntegratorParameters MDpar(20);
 | 
			
		||||
  IntegratorAlgorithm MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
 | 
			
		||||
  // Create HMC
 | 
			
		||||
  HMCparameters HMCpar;
 | 
			
		||||
 
 | 
			
		||||
@@ -54,8 +54,8 @@ int main (int argc, char ** argv)
 | 
			
		||||
  // Create integrator
 | 
			
		||||
  typedef MinimumNorm2<LatticeGaugeField>  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  //  typedef LeapFrog  IntegratorAlgorithm;// change here to change the algorithm
 | 
			
		||||
  IntegratorParameters MDpar(12,20,1.0);
 | 
			
		||||
  Integrator<LatticeGaugeField,IntegratorAlgorithm> MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
  IntegratorParameters MDpar(20);
 | 
			
		||||
  IntegratorAlgorithm MDynamics(&Fine,MDpar, FullSet);
 | 
			
		||||
 | 
			
		||||
  // Create HMC
 | 
			
		||||
  HMCparameters HMCpar;
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user