44 procedure,
public :: init => meshfieldcommrectdom2d_init
45 procedure,
public :: put => meshfieldcommrectdom2d_put
46 procedure,
public :: get => meshfieldcommrectdom2d_get
47 procedure,
public :: exchange => meshfieldcommrectdom2d_exchange
48 procedure,
public :: final => meshfieldcommrectdom2d_final
60 private :: push_localsendbuf
67 integer,
parameter :: comm_face_num = 4
70 subroutine meshfieldcommrectdom2d_init( this, &
71 sfield_num, hvfield_num, htensorfield_num, mesh2d )
75 integer,
intent(in) :: sfield_num
76 integer,
intent(in) :: hvfield_num
77 integer,
intent(in) :: htensorfield_num
82 integer :: nnode_lcmeshface(comm_face_num,mesh2d%local_mesh_num)
86 lcmesh => mesh2d%lcmesh_list(1)
89 do n=1, this%mesh2d%LOCAL_MESH_NUM
90 lcmesh => this%mesh2d%lcmesh_list(n)
91 nnode_lcmeshface(:,n) = (/ lcmesh%NeX, lcmesh%NeY, lcmesh%NeX, lcmesh%NeY /) * lcmesh%refElem2D%Nfp
97 end subroutine meshfieldcommrectdom2d_init
99 subroutine meshfieldcommrectdom2d_final( this )
108 end subroutine meshfieldcommrectdom2d_final
110 subroutine meshfieldcommrectdom2d_put(this, field_list, varid_s)
114 integer,
intent(in) :: varid_s
121 do i=1,
size(field_list)
122 do n=1, this%mesh%LOCAL_MESH_NUM
123 lcmesh => this%mesh2d%lcmesh_list(n)
125 this%send_buf(:,varid_s+i-1,n) )
130 end subroutine meshfieldcommrectdom2d_put
132 subroutine meshfieldcommrectdom2d_get(this, field_list, varid_s)
139 integer,
intent(in) :: varid_s
147 if ( this%call_wait_flag_sub_get ) &
150 do i=1,
size(field_list)
151 do n=1, this%mesh2d%LOCAL_MESH_NUM
152 lcmesh => this%mesh2d%lcmesh_list(n)
154 field_list(i)%field2d%local(n)%val )
159 end subroutine meshfieldcommrectdom2d_get
162 subroutine meshfieldcommrectdom2d_exchange( this, do_wait )
170 logical,
intent(in),
optional :: do_wait
176 do n=1, this%mesh%LOCAL_MESH_NUM
177 do f=1, this%nfaces_comm
178 commdata => this%commdata_list(f,n)
179 call push_localsendbuf( commdata%send_buf(:,:), &
180 this%send_buf(:,:,n), commdata%s_faceID, this%is_f(f,n), &
181 commdata%Nnode_LCMeshFace, this%field_num_tot)
192 end subroutine meshfieldcommrectdom2d_exchange
197 subroutine push_localsendbuf( lc_send_buf, send_buf, s_faceID, is, Nnode_LCMeshFace, var_num )
200 integer,
intent(in) :: var_num
201 integer,
intent(in) :: nnode_lcmeshface
202 real(rp),
intent(inout) :: lc_send_buf(nnode_lcmeshface,var_num)
204 integer,
intent(in) :: s_faceid, is
209 ie = is + nnode_lcmeshface - 1
210 if ( s_faceid > 0 )
then
211 lc_send_buf(:,:) = send_buf(is:ie,:)
213 lc_send_buf(:,:) = send_buf(ie:is:-1,:)
217 end subroutine push_localsendbuf
module FElib / Element / Base
module FElib / Mesh / Local 2D
module FElib / Mesh / Rectangle 2D domain
module FElib / Data / base
module FElib / Data / Communication base
subroutine, public meshfieldcommbase_extract_bounddata(var, refelem, mesh, buf)
Extract halo data from data array with MeshField object and set it to the recieving buffer.
subroutine, public meshfieldcommbase_final(this)
Finalize a base object to manage data communication of fields.
subroutine, public meshfieldcommbase_wait_core(this, commdata_list, field_list, dim, varid_s, lcmesh_list)
Wait data communication and move tmp data of LocalMeshCommData object to a recv buffer.
subroutine, public meshfieldcommbase_set_bounddata(buf, refelem, mesh, var)
Extract halo data from the recieving buffer and set it to data array with MeshField object.
subroutine, public meshfieldcommbase_init(this, sfield_num, hvfield_num, htensorfield_num, bufsize_per_field, comm_face_num, nnode_lcmeshface, mesh)
Initialize a base object to manage data communication of fields.
subroutine, public meshfieldcommbase_exchange_core(this, commdata_list, do_wait)
Exchange halo data.
module FElib / Data / Communication 2D rectangle domain
integer bufsize_per_field
Derived type representing a 2D reference element.
Derived type representing an arbitrary finite element.
Derived type representing a field with 2D mesh.
Derived type to manage data communication at a face between adjacent local meshes.
Base derived type to manage data communication.
Container to save a pointer of MeshField(1D, 2D, 3D) object.
Base derived type to manage data communication with 2D rectangle domain.