Ising Model Postmortem

Now that you have a better understanding of the Ising model, how would your present-self tell your past-self how to complete the exercise? What pitfalls, misunderstandings, etc. would you emphasize? I have created a general outline of various categories below, but you should feel free to modify, add, or remove these as you see fit.

This is meant to be a collaborative exercise, so I would encourage you to: (1) Modify and build on each other's answers; (2) Post unresolved questions (that others can answer); (3) Include links to external web resources, as you see fit. Note that you will need to become a member of this site to edit this page, and you can do this from the front page, using the same password as we used for the H205 site.

Physical Picture

*To define U, can you just sum all the neighbors in the equation rather than trying to use a Boltzmann equation?
*In order to sum up a series, you need to first define the zero for your summations before the introduction of the MC do loop(i.e. U=0). The summation follows the form: Uavg = Uavg + U. This adds up all of the subsequent "U" values and results in an average.
*I would have liked to understand how the summation actually worked
*In retrospect, the first thing to check would be the variables defined at the beginning of the program to ensure that they are logical and defined correctly for the way in which they are to be used.
*Make a flow chart to avoid confusion
*add more notes to myself throughout the program, so I know the job of everything i'm writing, and can see the big picture
*Make the different steps more clear by defining each step. When do you take the sum of the entire function, when do you take the energy of the system, and when you take the energy at non-correlated points

The Monte Carlo Algorithm

  • 20000 MC trials are done for each temperature step. 10,000 to get the system more or less is equilibrium, and 10,000 to collect data (done once every 50 trials).
  • Monte Carlo Algorithm encompasses different operations such as Monte Carlo integration and what not. For the purpose of the ising model problem, Monte Carlo does not refer to Monte Carlo integration.

Equilibration procedure

  • Understand that when initializing the spin array we start at do column, so col=1 and then continue to do row so row=1 and then the steps after the do's are taken. then when we get to end do which pertains to "do row" we continue to row=2 and so on. so first the entire first column is set up then the second and so on.

Sampling procedure

  • When you sample the energies of each individual lattice site. First define the procedure in the first 10,0000 MC trials and then define the specific flip requirements in the second Mc trials
  • When you sum the mod(50) energy and mag, you must redefine the i,j coordinates to describe the new sample will read the system.

Computational difficulties

  • I would explain to myself how do loops work, and emphasize the order in which Fortran executes commands. Also how the data is stored every 50 steps was hard to grasp. To be able to understand this you really have to go through and see what is being done in the do loops.
  • There were a couple of Fortran 90 books in the library so I checked one out and is in the process of looking it over- it's helping me to get a better grasp of the language and the technicalities.
  • I think that I could have done a better job if I understood the programming language. This is the kind of problem I had with using mathmatica as well- I wish that I had the programming syntax guide or something when I was writing this program. I would focus on how to distinguish doing calculations vs. collecting data, and loops with Monte Carlo approximation, and also taking data every 50 data points. Is recording data every 50 points just for practical reasons?
  • A step-by-step process seems very important in writing a program. Nothing can be implied, because the computer can only do what one writes in the program. Finish one calculation, make sure all the variables are defined, the equations are all accurate, and then move on to the next set of calculations.
  • I would explain to myself that certain things like the averages can be put into the program once and if they are place correctly then I would not have to include them over and over again. I would also remind myself to proofread so as to prevent silly do loop mistakes that prevent a program from running correctly.
  • If the data points for each temperature step are not averaged, the graph will appear as a bar for each temperature step. The data needs to be averaged so that each temperature step will eventually only end up with one value.
  • I'm still not exactly sure what a subroutine is, anyone?
  • That makes two of us
  • What is a logical parameter and what do the periods around the F's mean?
  • I believe this is just setting up the movie output that we watched in class.//
  • Knowing that Q was unnecessary for all calculations in this program would have been helpful from the beginning because we wasted a lot of time trying to get it to work.
  • But, why was Q unnecessary?

Q was unnecessary because we were "letting nature do that work." I think what that means is that the program was taking completely random samples, so there was no need to account for the proper distribution of states since the most probable states will naturally be selected most often by the program and the least probable states will naturally be selected least often—by nature, I think it just means statistics.

  • What does kind=8 mean?
  • //I would like to know this as well.
  • I think I tried to condense the information too much…I would break everything into smaller parts to define.
  • I don't see where the plots were defined in this program, anyone?
  • When taking the sum for magnetism, you don't have to write out all of the (col, row) combinations. But you do for energy (U). Why?

*Also still not sure how you decide when to use loops, how much can you put in one and how do you decide what order they go in?
I agree, knowing the order in which the do loops must be performed would have been useful, but I'm still not sure how that order is determined.
You can put as much as you want into a loop. For example, you can put something as simple as the summation of 1/1-x or something more complex like partition functions. When you define these equations as a variable at the end of the loop you can use them outside the loop.
*I would learn how to use Fortran syntax to write programs. ie I didn't know that <__> described some function in Fortran.

Conceptual difficulties.

The idea is to take the average energies and average magnetizations per element of the array, not the average energy or magnetization of the array itself. This is because the purpose of the Ising Model is to observe how the spins themselves change given certain conditions. The purpose of performing these observations over multiple arrays is make sure the results we get are normal and not the result of one anomalous array (less deviation for greater number of arrays sampled).
I am still not quite sure I understand the whole average thing and when to do it/when not to, and what it actually means…

Strategies/ Questions

*In the "correct" ising model you develop a matrix output, is that for the movie? —- JS: Yes, there is some extra code in my solution to create different starting conditions, as well as to print output for making movies and charts. None of this is necessary for your conclusion.

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License