fbuessen / spinmc.jl Goto Github PK
View Code? Open in Web Editor NEWClassical Monte Carlo simulations for lattice spin systems
License: MIT License
Classical Monte Carlo simulations for lattice spin systems
License: MIT License
Hello, I was trying to run the two-dimensional honeycomb lattice example as found in the readme and got the following error:
MethodError: no method matching var"#MonteCarlo#16"(::Int64, ::Int64, ::Int64, ::Int64, ::Random.Xoshiro, ::UInt64, ::Type{MonteCarlo}, ::Lattice{2, 3}, ::Float64, ::Int64, ::Int64)
Closest candidates are:
var"#MonteCarlo#16"(::Int64, ::Int64, ::Int64, ::Int64, ::Random.MersenneTwister, ::UInt64, ::Type{MonteCarlo}, ::T, ::Float64, ::Int64, ::Int64) where T<:Lattice at ~/.julia/packages/SpinMC/iKQOo/src/MonteCarlo.jl:35
It worked giving the MonteCarlo function a specific seed.
Hi, @fbuessen thank you for your code written in Julia. I didn't notice this code until yesterday. It's strange to me, because in all the samples, the exchange interaction matrix is always like this: M = [1.0 0.0 0.0; 0.0 1.0 0.0; 0.0 0.0 1.0], I'm wondering what's the unit of the element 1? Or in SpinMC.jl, it has to be normalized?
In addition, in the example https://github.com/fbuessen/SpinMC.jl#specific-heat-and-magnetization-of-a-cubic-lattice-heisenberg-ferromagnet how to consider the influence of magnetic moment on the simulation of Curie temperature? Thanks very much!
Is it possible to recover the values of the observables at the end of each sweep? I see they're saved as LogBinners and I wonder if I can recover the original values. Thanks in advance.
While using SpinMC.jl to study a ferromagnetic system, I found a bug in the trivial case of a one-site cluster, that is, one basis site in one primitive unit cell. Let there be zero onsite or field interactions, but allow for a finite two-spin interaction. The function getEnergy()
in Spin.jl initializes an energy of value 0.0
on Line 16 but never updates this value on Line 26; this is because site > interactionSites[i]
can never evaluate to true
for a one-site cluster, as both sides have the value 1
.
I believe this restriction is to avoid double-counting each bond's energy contribution. One fix could be to remove this restriction, sum over all sites, and divide by two.
I want to plot the last state of a simulation and while the spin values can be accessed using m.lattice.spins
I can't find a way to get their position in x,y coordinates. Is it possible to get these coordinates?
For lattices with lower symmetry, in which not all lattice sites are equivalent, it is not sufficient to compute spin correlations with respect to only one fixed lattice site.
Especially when computing the structure factor, a summation of two-spin correlations over all basis sites is required (in addition to the second sum running over all lattice sites). Even for symmetries in which all lattice sites are symmetry-equivalent, better convergence can be obtained by summing over all basis sites.
We should therefore measure and store spin correlations with respect to every basis site by default.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.