-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmcmc1.m
34 lines (20 loc) · 777 Bytes
/
mcmc1.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
%%%%%%%%%%%%%%% MCMC WITH SELF-INTERACTION %%%%%%%%%%%%%%%%%%
tic
%rng('shuffle');
%[ magn, st_magn, spins ] = beta_specific(L,h,kappa,n=1,T,beta)
[a1,b1,c1]=beta_specific(250,0.4,1,1,8000,0.5); % temperature #1
[a2,b2,c2]=beta_specific(250,0.4,1,1,8000,0.55); % temperature #2
[a3,b3,c3]=beta_specific(250,0.4,1,1,8000,0.57); % temperature #3
%%%%%%%%%%%%%%%%%%%%% MAGNETIZATION %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
figure(1)
plot(1:length(a1),a1,'g',1:length(a2),a2,'r',1:length(a3),a3,'b');
%%%%%%%%%%%%%%%%%%%%% STAGGERED - MAGNETIZATION %%%%%%%%%%%%%%%%%%%
%plot(1:length(b1),b1,'g',1:length(b2),b2,'r',1:length(b3),b3,'b');
%%%%%%%%%%%%%%%%%%%%% SPINS CONFIGURATION %%%%%%%%%%%%%%%%%%%%%%%%%
figure(2)
imagesc(c1)
figure(3)
imagesc(c2)
figure(4)
imagesc(c3)
toc