mirror of
https://igit.ific.uv.es/alramos/latticegpu.jl.git
synced 2025-05-15 03:33:42 +02:00
Documentation update and sfbndfix included in Dw.
This commit is contained in:
parent
4c560ab0fe
commit
ac796d95eb
13 changed files with 66 additions and 65 deletions
|
@ -453,6 +453,7 @@ function Dw!(so, U, si, dpar::DiracParam, dws::DiracWorkspace, lp::Union{SpacePa
|
|||
end
|
||||
end
|
||||
end
|
||||
SF_bndfix!(so,lp)
|
||||
|
||||
return nothing
|
||||
end
|
||||
|
@ -545,6 +546,7 @@ function g5Dw!(so, U, si, dpar::DiracParam, dws::DiracWorkspace, lp::Union{Space
|
|||
end
|
||||
end
|
||||
end
|
||||
SF_bndfix!(so,lp)
|
||||
|
||||
return nothing
|
||||
end
|
||||
|
@ -626,6 +628,7 @@ end
|
|||
|
||||
function DwdagDw!(so, U, si, dpar::DiracParam, dws::DiracWorkspace, lp::Union{SpaceParm{4,6,BC_SF_ORBI,D},SpaceParm{4,6,BC_SF_AFWB,D}}) where {D}
|
||||
|
||||
SF_bndfix!(si,lp)
|
||||
if abs(dpar.csw) > 1.0E-10
|
||||
@timeit "DwdagDw" begin
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@ scalar_field(::Type{T}, lp::SpaceParm) where {T} = CuArray{T, 2}(undef, lp.b
|
|||
"""
|
||||
nscalar_field(::Type{T}, n::Integer, lp::SpaceParm)
|
||||
|
||||
Returns `n` scalar fields of elemental type `T`
|
||||
Returns `n` scalar fields of elemental type `T`.
|
||||
"""
|
||||
nscalar_field(::Type{T}, n, lp::SpaceParm) where {T} = CuArray{T, 3}(undef, lp.bsz, n, lp.rsz)
|
||||
|
||||
|
@ -46,7 +46,7 @@ scalar_field_point(::Type{T}, lp::SpaceParm{N,M,D}) where {T,N,M,D} = CuArray{T,
|
|||
"""
|
||||
tensor_field(::Type{T}, lp::SpaceParm)
|
||||
|
||||
Returns a tensor field of elemental type `T`.
|
||||
Returns a (symmetric) tensor field of elemental type `T`.
|
||||
"""
|
||||
tensor_field(::Type{T}, lp::SpaceParm) where {T} = CuArray{T, 3}(undef, lp.bsz, lp.npls, lp.rsz)
|
||||
|
||||
|
|
|
@ -36,7 +36,7 @@ norm2(a::SU2{T}) where T <: AbstractFloat = abs2(a.t1) + abs2(a.t2)
|
|||
"""
|
||||
tr(g::T) where T <: Group
|
||||
|
||||
Returns the trace of the groups element `g`.
|
||||
Returns the trace of the group element `g`.
|
||||
"""
|
||||
tr(g::SU2{T}) where T <: AbstractFloat = complex(2*real(g.t1), 0.0)
|
||||
|
||||
|
|
|
@ -26,19 +26,19 @@ This structure contains information about the lattice being simulated. The param
|
|||
- `N`: The number of dimensions
|
||||
- `M`: The number of planes (i.e. \`\` N(N-1)/2 \`\`)
|
||||
- `B`: The boundary conditions in Euclidean time. Acceptable values are
|
||||
- `BC_PERIODIC`: Periodic boundary conditions
|
||||
- `BC_SF_AFWB`: Schrödinger Funtional Aoki-Frezzoptti-Weisz Choice B.
|
||||
- `BC_SF_ORBI`: Schrödinger Funtional orbifold constructions.
|
||||
- `BC_PERIODIC`: Periodic boundary conditions.
|
||||
- `BC_SF_AFWB`: Schrödinger Functional Aoki-Frezzotti-Weisz Choice B.
|
||||
- `BC_SF_ORBI`: Schrödinger Functional orbifold constructions.
|
||||
- `BC_OPEN`: Open boundary conditions.
|
||||
|
||||
The structure conatins the following components:
|
||||
The structure contains the following components:
|
||||
- `iL`: Tuple containing the lattice length in each dimension.
|
||||
- `plidx`: The directions of each plane
|
||||
- `blk`: The block size in each each dimension
|
||||
- `rbk`: The number of blocks in each dimension
|
||||
- `bsz`: The number of points in each block
|
||||
- `rsz`: The number of blocks in the lattice
|
||||
- `ntw`: The twist tensor in each plane
|
||||
- `plidx`: The directions of each plane.
|
||||
- `blk`: The block size in each each dimension.
|
||||
- `rbk`: The number of blocks in each dimension.
|
||||
- `bsz`: The number of points in each block.
|
||||
- `rsz`: The number of blocks in the lattice.
|
||||
- `ntw`: The twist tensor in each plane.
|
||||
"""
|
||||
struct SpaceParm{N,M,B,D}
|
||||
ndim::Int64
|
||||
|
|
|
@ -14,6 +14,7 @@ module Spinors
|
|||
using ..Groups
|
||||
import ..Groups.imm, ..Groups.mimm, ..Groups.norm, ..Groups.norm2, ..Groups.dot
|
||||
|
||||
|
||||
struct Spinor{NS,G}
|
||||
s::NTuple{NS,G}
|
||||
end
|
||||
|
@ -291,25 +292,23 @@ end
|
|||
"""
|
||||
dmul(Gamma{n}, a::Spinor)
|
||||
|
||||
Returns ``\\gamma_n a``
|
||||
Returns ``\\gamma_n a``. Indexing for Dirac basis ``\\gamma_n``:
|
||||
|
||||
indexing for Dirac basis ``\\gamma_n``:
|
||||
|
||||
1 gamma1;
|
||||
2 gamma2;
|
||||
3 gamma3;
|
||||
4 gamma0;
|
||||
5 gamma5;
|
||||
6 gamma1 gamma5;
|
||||
7 gamma2 gamma5;
|
||||
8 gamma3 gamma5;
|
||||
9 gamma0 gamma5;
|
||||
10 sigma01;
|
||||
11 sigma02;
|
||||
12 sigma03;
|
||||
13 sigma21;
|
||||
14 sigma32;
|
||||
15 sigma31;
|
||||
1 ``\\gamma_1``;
|
||||
2 ``\\gamma_2``;
|
||||
3 ``\\gamma_3``;
|
||||
4 ``\\gamma_0``;
|
||||
5 ``\\gamma_5``;
|
||||
6 ``\\gamma_1 \\gamma_5``;
|
||||
7 ``\\gamma_2 \\gamma_5``;
|
||||
8 ``\\gamma_3 \\gamma_5``;
|
||||
9 ``\\gamma_0 \\gamma_5``;
|
||||
10 ``\sigma_{01}``;
|
||||
11 ``\sigma_{02}``;
|
||||
12 ``\sigma_{03}``;
|
||||
13 ``\sigma_{21}``;
|
||||
14 ``\sigma_{32}``;
|
||||
15 ``\sigma_{31}``;
|
||||
16 identity;
|
||||
|
||||
"""
|
||||
|
|
20
src/YM/YM.jl
20
src/YM/YM.jl
|
@ -23,15 +23,15 @@ import Base.show
|
|||
"""
|
||||
struct GaugeParm{T,G,N}
|
||||
|
||||
Structure containning the parameters of a pure gauge simulation. These are:
|
||||
- beta: Type `T`. The bare coupling of the simulation
|
||||
Structure containing the parameters of a pure gauge simulation. These are:
|
||||
- beta: Type `T`. The bare coupling of the simulation.
|
||||
- c0: Type `T`. LatticeGPU supports the simulation of gauge actions made of 1x1 Wilson Loops and 2x1 Wilson loops. The parameter c0 defines the coefficient on the simulation of the 1x1 loops. Some common choices are:
|
||||
- c0=1: Wilson plaquette action
|
||||
- c0=1: Wilson plaquette action.
|
||||
- c0=5/3: Tree-level improved Lüscher-Weisz action.
|
||||
- c0=3.648: Iwasaki gauge action
|
||||
- c0=3.648: Iwasaki gauge action.
|
||||
- cG: Tuple (`T`, `T`). Boundary improvement parameters.
|
||||
- ng: `Int64`. Rank of the gauge group.
|
||||
- Ubnd: Boundary field for SF boundary conditions
|
||||
- Ubnd: Boundary field for SF boundary conditions.
|
||||
"""
|
||||
struct GaugeParm{T,G,N}
|
||||
beta::T
|
||||
|
@ -79,11 +79,11 @@ end
|
|||
"""
|
||||
struct YMworkspace{T}
|
||||
|
||||
Structure containing memory workspace that is resused by different routines in order to avoid allocating/deallocating time.
|
||||
Structure containing memory workspace that is reused by different routines in order to avoid allocating/deallocating time.
|
||||
The parameter `T` represents the precision of the simulation (i.e. single/double). The structure contains the following components
|
||||
- GRP: Group being simulated
|
||||
- ALG: Corresponding Algebra
|
||||
- PRC: Precision (i.e. `T`)
|
||||
- GRP: Group being simulated.
|
||||
- ALG: Corresponding Algebra.
|
||||
- PRC: Precision (i.e. `T`).
|
||||
- frc1: Algebra field with natural indexing.
|
||||
- frc2: Algebra field with natural indexing.
|
||||
- mom: Algebra field with natural indexing.
|
||||
|
@ -141,7 +141,7 @@ end
|
|||
"""
|
||||
function ztwist(gp::GaugeParm{T,G}, lp::SpaceParm{N,M,B,D}[, ipl])
|
||||
|
||||
Returns the twist factor. If a plane index is passed, returns the twist factor as a complex{T}. If this is not provided, returns a tuple, containing the factor of each plane.
|
||||
Returns the twist factor. If a plane index is passed, returns the twist factor as a Complex{T}. If this is not provided, returns a tuple, containing the factor of each plane.
|
||||
"""
|
||||
function ztwist(gp::GaugeParm{T,G}, lp::SpaceParm{N,M,B,D}) where {T,G,N,M,B,D}
|
||||
|
||||
|
|
|
@ -347,7 +347,7 @@ end
|
|||
"""
|
||||
Qtop([Qslc,] U, gp::GaugeParm, lp::SpaceParm, ymws::YMworkspace)
|
||||
|
||||
Measure the topological charge `Q` of the configuration `U` using the clover definition of the field strength tensor. If the argument `Qslc` is present the contribution for each Euclidean time slice are returned. Only wors in 4D.
|
||||
Measure the topological charge `Q` of the configuration `U` using the clover definition of the field strength tensor. If the argument `Qslc` is present the contributions for each Euclidean time slice are returned. Only works in 4D.
|
||||
"""
|
||||
function Qtop(Qslc, U, gp::GaugeParm, lp::SpaceParm{4,M,B,D}, ymws::YMworkspace) where {M,B,D}
|
||||
|
||||
|
@ -386,7 +386,7 @@ Qtop(U, gp::GaugeParm, lp::SpaceParm{4,M,D}, ymws::YMworkspace{T}) where {T,M,D}
|
|||
"""
|
||||
function Eoft_clover([Eslc,] U, gp::GaugeParm, lp::SpaceParm, ymws::YMworkspace)
|
||||
|
||||
Measure the action density `E(t)` using the clover discretization. If the argument `Eslc`
|
||||
Measure the action density `E(t)` using the clover discretization. If the argument `Eslc` is given
|
||||
the contribution for each Euclidean time slice and plane are returned.
|
||||
"""
|
||||
function Eoft_clover(Eslc, U, gp::GaugeParm, lp::SpaceParm{4,M,B,D}, ymws::YMworkspace{T}) where {T,M,B,D}
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
|
||||
function gauge_action(U, lp::SpaceParm, gp::GaugeParm, ymws::YMworkspace)
|
||||
|
||||
Returns the value of the gauge action for the configuration U. The parameters `\beta` and `c0` are taken from the `gp` structure.
|
||||
Returns the value of the gauge action for the configuration U. The parameters ``\\beta`` and `c0` are taken from the `gp` structure.
|
||||
"""
|
||||
function gauge_action(U, lp::SpaceParm, gp::GaugeParm, ymws::YMworkspace{T}) where T <: AbstractFloat
|
||||
|
||||
|
@ -71,7 +71,7 @@ end
|
|||
"""
|
||||
HMC!(U, int::IntrScheme, lp::SpaceParm, gp::GaugeParm, ymws::YMworkspace; noacc=false)
|
||||
|
||||
Performs a HMC step (molecular dynamics integration and accept/reject step). The configuration `U` is updated ans function returns the energy violation and if the configuration was accepted in a tuple.
|
||||
Performs a HMC step (molecular dynamics integration and accept/reject step). The configuration `U` is updated and function returns the energy violation and if the configuration was accepted in a tuple.
|
||||
"""
|
||||
function HMC!(U, int::IntrScheme, lp::SpaceParm, gp::GaugeParm, ymws::YMworkspace{T}; noacc=false) where T
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue