Basically I have a matrix H[N][N] with variable N that obtains it's elements in the following way: On the diagonal it's elements are made of G+Z and off the diagonal it's elements are created from F. The code to create G is in the attached file (heisenberg.c - the other two files just exist to find eigenvalues etc)... Basically it involves counting the number of 1s and 0s in the binary representation of a particular location on the diagonal eg if H[A][A] then the binary representation of A. I'm very confused about how to create code in a logical manner for Z and F though... Z is determined by the number of positive pairs or negative pairs in its binary representation: Example on Z-component for N=6: H[25][25] = H[011001][011001] Positve pairs: 0(11)001 , 011(00)1 - two of them Negative pairs: (01)1001, 01(10)01, 0110(01) - three of then Therefore Z[25][25] = 2 - 3 = -1 F is determined by pairs of flipped neighbours: F is 0 if elements A and B H[A][B] differ by more than a pair of neigbour spins and half otherwise, eg: H[4][2] = H[ (10)0 ] [ (01)0 ] therefore H[4][2] = 1/2 H[21][25] = H[ 01(01)01 ] [ 01(10)01 ] therefore H[4][2] = 1/2 I now realise that the way I coded 'G' isn't really going to work for this... So anyone who can logically implement this please go ahead! Oh, and I know the hamiltonian for N=2 is supposed to look like: 0.25 0 0 0 0 -0.25 0.5 0 0 0.5 -0.25 0 0 0 0 0.25 And the hamiltonian for N=3 is supposed to look like: 0.25 0 0 0 0 0 0 0 0 0.25 0.5 0.5 0 0 0 0 0 0.5 0.25 0.5 0 0 0 0 0 0.5 0.5 0.25 0 0 0 0 0 0 0 0 0.25 0.5 0.5 0 0 0 0 0 0.5 0.25 0.5 0 0 0 0 0 0.5 0.5 0.25 0 0 0 0 0 0 0 0 0.25
## Deliverables
1) Complete and fully-functional working program(s) in executable form as well as complete source code of all work done.
2) Deliverables must be in ready-to-run condition, as follows (depending on the nature of the deliverables):
a) For web sites or other server-side deliverables intended to only ever exist in one place in the Buyer's environment--Deliverables must be installed by the Seller in ready-to-run condition in the Buyer's environment.
b) For all others including desktop software or software the buyer intends to distribute: A software installation package that will install the software in ready-to-run condition on the platform(s) specified in this bid request.
3) All deliverables will be considered "work made for hire" under U.S. Copyright law. Buyer will receive exclusive and complete copyrights to all work purchased. (No GPL, GNU, 3rd party components, etc. unless all copyright ramifications are explained AND AGREED TO by the buyer on the site per the coder's Seller Legal Agreement).
## Platform
C (unix based but it doesn't really matter as there are no system calls, just printfs)...