- #1
xperrylinn
- 3
- 0
I'm creating a Monte Carlo simulation of the 2D Ising Model for a graduate course in computational materials science. Part of the assignment is to calculate the uncertainty in the calculation of the average magnetization per spin. To do so, we are told to find the correlation time for our data set of average magnetization vs. number of spin flip attempts. We are instructed to do this by using built in methods provided by either Matlab, Mathematica, or in my case numpy since I'm coding in python to provide us with a correlation function which can be used in further steps to calculate the correlation time.
I've take a look at the numpy library and there is a feature called correlate. numpy.correlate that takes in two arrays, and calculates the cross correlation between the two data sets are returns a constant value. I don't see anything in the numpy library that returns a correlation function. Any suggestions on how to proceed? Thanks..
I've take a look at the numpy library and there is a feature called correlate. numpy.correlate that takes in two arrays, and calculates the cross correlation between the two data sets are returns a constant value. I don't see anything in the numpy library that returns a correlation function. Any suggestions on how to proceed? Thanks..