mirror of
https://igit.ific.uv.es/alramos/latticegpu.jl.git
synced 2025-05-14 19:23:42 +02:00
Generic interface to create fields
This commit is contained in:
parent
3f71a5222f
commit
0fe33c5b38
6 changed files with 30 additions and 24 deletions
15
src/Fields/Fields.jl
Normal file
15
src/Fields/Fields.jl
Normal file
|
@ -0,0 +1,15 @@
|
|||
###
|
||||
### "THE BEER-WARE LICENSE":
|
||||
### Alberto Ramos wrote this file. As long as you retain this
|
||||
### notice you can do whatever you want with this stuff. If we meet some
|
||||
### day, and you think this stuff is worth it, you can buy me a beer in
|
||||
### return. <alberto.ramos@cern.ch>
|
||||
###
|
||||
### file: Fields.jl
|
||||
### created: Wed Oct 6 17:37:03 2021
|
||||
###
|
||||
|
||||
|
||||
vector_field(::Type{T}, lp::SpaceParm) where {T} = CuArray{T, 3}(undef, lp.bsz, lp.ndim, lp.rsz)
|
||||
scalar_field(::Type{T}, lp::SpaceParm) where {T} = CuArray{T, 3}(undef, lp.bsz, lp.rsz)
|
||||
nscalar_field(::Type{T}, n, lp::SpaceParm) where {T} = CuArray{T, 3}(undef, lp.bsz, n, lp.rsz)
|
Loading…
Add table
Add a link
Reference in a new issue