Пример #1
0
 static void correlationLengthAnalysis()
 {
     List<Series> series = new List<Series>();
     //Estimate correlation length
     var A = new ThreeDIsing(25);
     //for (double i = 4; i < 5; i += .1) {
     for (double i = 3; i < 8; i += 1) {
         Func<double, double> ising = b => {
             A.SetBeta(i);
             A.Randomize();
             A.Equilibrate(1000000);
             Debug.Print("Temp: " + i.ToString());
             return Math.Log(A.AutoCorrelation((int)b, 50000));
         };
         series.Add(	ising.GetSeriesForGraph(0, 10, 1));
     }
     PlotData data = new PlotData(series.ToArray());
     data.Graph();
 }
Пример #2
0
 static void TheCorrelationtoNearestNeighborvsTemperature()
 {
     //Estimate correlation length
     var A = new ThreeDIsing(25);
     //for (double i = 4; i < 5; i += .1) {
     Func<double, double> ising = b => {
         A.SetBeta(b);
         A.Randomize();
         A.Equilibrate(1000000);
         Debug.Print("Temp: " + b.ToString());
         return A.AutoCorrelation((int)1, 50000);
     };
     ising.GetSeriesForGraph(4, 5, .01);
     //}
 }