mirror of
https://igit.ific.uv.es/alramos/latticegpu.jl.git
synced 2025-05-14 19:23:42 +02:00
All cross terms implemented
This commit is contained in:
parent
2e8e76e11c
commit
29209375e6
4 changed files with 25 additions and 15 deletions
|
@ -25,16 +25,17 @@ struct ScalarParm{N,T}
|
||||||
kap::NTuple{N,T}
|
kap::NTuple{N,T}
|
||||||
eta::NTuple{N,T}
|
eta::NTuple{N,T}
|
||||||
muh::T
|
muh::T
|
||||||
|
xi::NTuple{4,T}
|
||||||
|
|
||||||
function ScalarParm(kv::NTuple{2,T}, ev::NTuple{2,T}, mu::T) where T
|
function ScalarParm(kv::NTuple{2,T}, ev::NTuple{2,T}, mu::T, xi::NTuple{4,T}) where T
|
||||||
|
|
||||||
|
|
||||||
return new{2,T}(kv,ev,mu)
|
return new{2,T}(kv,ev,mu, xi)
|
||||||
end
|
end
|
||||||
function ScalarParm(kv::NTuple{N,T}, ev::NTuple{N,T}) where {N,T}
|
function ScalarParm(kv::NTuple{N,T}, ev::NTuple{N,T}) where {N,T}
|
||||||
|
|
||||||
|
|
||||||
return new{N,T}(kv,ev,0.0)
|
return new{N,T}(kv,ev,0.0,ntuple(i->0.0,4))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -51,8 +52,9 @@ function Base.show(io::IO, sp::ScalarParm{N,T}) where {N,T}
|
||||||
end
|
end
|
||||||
if N == 2
|
if N == 2
|
||||||
print("\n - mu12: ")
|
print("\n - mu12: ")
|
||||||
println(io, " ", sp.muh)
|
print(io, " ", sp.muh)
|
||||||
|
print("\n - xi: ")
|
||||||
|
print(io, " ", sp.xi)
|
||||||
end
|
end
|
||||||
println("\n")
|
println("\n")
|
||||||
|
|
||||||
|
|
|
@ -94,11 +94,13 @@ function krnl_act!(act, U::AbstractArray{TG}, Phi::AbstractArray{TS}, sp::Scalar
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
for i in 1:2
|
sdot1 = dot(Psh[b,1],Psh[b,1])
|
||||||
sdot = dot(Psh[b,i],Psh[b,i])
|
sdot2 = dot(Psh[b,2],Psh[b,2])
|
||||||
S += sdot + sp.eta[i]*(sdot - 1)^2
|
sdot12 = dot(Psh[b,1],Psh[b,2])
|
||||||
end
|
|
||||||
S += 2*sp.muh*dot(Psh[b,1], Psh[b,2])
|
S += sdot1 + sdot2 + sp.eta[1]*(sdot1 - 1)^2 + sp.eta[2]*(sdot2 - 1)^2
|
||||||
|
S += 2*sp.muh*sdot12 + sp.xi[1]*sdot1*sdot2 + sp.xi[2]*sdot12^2
|
||||||
|
S += 2 * (sp.xi[3]*sdot12*sdot1 + sp.xi[4]*sdot12*sdot2)
|
||||||
|
|
||||||
I = point_coord((b,r), lp)
|
I = point_coord((b,r), lp)
|
||||||
act[I] = S
|
act[I] = S
|
||||||
|
|
|
@ -101,10 +101,16 @@ function krnl_force_scalar!(fgauge, fscalar, U::AbstractArray{TG}, Phi::Abstract
|
||||||
|
|
||||||
fgauge[b,id,r] -= (2*sp.kap[i])*projalg(p1*dag(Psh[b,i]))
|
fgauge[b,id,r] -= (2*sp.kap[i])*projalg(p1*dag(Psh[b,i]))
|
||||||
end
|
end
|
||||||
fscalar[b,i,r] -= ( 2 + 4*sp.eta[i]*(dot(Psh[b,i],Psh[b,i])-1) ) * Psh[b,i]
|
|
||||||
end
|
end
|
||||||
fscalar[b,1,r] -= 2*sp.muh*Psh[b,2]
|
sdot1 = dot(Psh[b,1],Psh[b,1])
|
||||||
fscalar[b,2,r] -= 2*sp.muh*Psh[b,1]
|
sdot2 = dot(Psh[b,2],Psh[b,2])
|
||||||
|
sdot12 = dot(Psh[b,1],Psh[b,2])
|
||||||
|
|
||||||
|
fscalar[b,1,r] -= 2 * (1 + 2*sp.eta[1]*(sdot1-1) + sp.xi[1]*sdot2 + 2*sp.xi[3]*sdot12) * Psh[b,1]
|
||||||
|
fscalar[b,2,r] -= 2 * (1 + 2*sp.eta[2]*(sdot2-1) + sp.xi[1]*sdot1 + 2*sp.xi[4]*sdot12) * Psh[b,2]
|
||||||
|
|
||||||
|
fscalar[b,1,r] -= 2 * (sp.muh + sp.xi[2]*sdot12 + sp.xi[3]*sdot1 + sp.xi[4]*sdot2) * Psh[b,2]
|
||||||
|
fscalar[b,2,r] -= 2 * (sp.muh + sp.xi[2]*sdot12 + sp.xi[3]*sdot1 + sp.xi[4]*sdot2) * Psh[b,1]
|
||||||
|
|
||||||
return nothing
|
return nothing
|
||||||
end
|
end
|
||||||
|
|
|
@ -8,7 +8,7 @@ using LatticeGPU
|
||||||
|
|
||||||
lp = SpaceParm{4}((16,16,16,16), (4,4,4,4))
|
lp = SpaceParm{4}((16,16,16,16), (4,4,4,4))
|
||||||
gp = GaugeParm(6.0, 1.0, (0.0,0.0), 2)
|
gp = GaugeParm(6.0, 1.0, (0.0,0.0), 2)
|
||||||
sp = ScalarParm((0.2,0.3), (1.0,0.4), 0.5)
|
sp = ScalarParm((0.2,0.3), (1.0,0.4), 0.5, (0.234,0.13,0.145,0.1))
|
||||||
|
|
||||||
NSC = length(sp.kap) #number of scalars = # of k coupling
|
NSC = length(sp.kap) #number of scalars = # of k coupling
|
||||||
println("Space Parameters: ", lp)
|
println("Space Parameters: ", lp)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue