2 #include "sll_working_precision.h"
28 sll_int32,
intent( in ) :: n_cells(3)
29 sll_int32,
intent( in ) :: degree(3)
30 sll_int32,
optional,
intent( in ) :: degree2(3)
34 self%n_total = product(n_cells)
36 allocate( self%particle_mass( product(2*self%degree+1), self%n_total) )
37 self%particle_mass = 0._f64
38 self%n_rows = self%n_total
39 self%n_cols = self%n_total
41 self%n_global_rows = self%n_rows
42 self%n_global_cols = self%n_cols
49 deallocate( self%particle_mass )
56 sll_real64,
intent( in ) :: x(:)
57 sll_real64,
intent( out ) :: y(:)
59 sll_int32 :: ind_i, ind_j, ind
60 sll_int32 :: i1, i2, i3, j1, j2, j3
63 do i3 = 1, self%n_dofs(3)
64 do i2 = 1, self%n_dofs(2)
65 do i1 = 1, self%n_dofs(1)
68 do j3 = i3-self%degree(3), i3+self%degree(3)
69 do j2 = i2-self%degree(2), i2+self%degree(2)
70 do j1 = i1-self%degree(1), i1+self%degree(1)
72 y(ind_i) = y(ind_i) + &
73 self%sign * self%particle_mass( ind, ind_i) * x(ind_j)
88 sll_int32 :: num_pts(3)
94 ind1d = 1+ modulo(ind1-1,num_pts(1)) + &
95 modulo(ind2-1,num_pts(2)) * num_pts(1) + &
96 modulo(ind3-1,num_pts(3))* num_pts(1)*num_pts(2)
subroutine dot_particle_mass_3d_diag(self, x, y)
subroutine create_linear_operator_particle_mass_3d_diag(self, n_cells, degree, degree2)
subroutine print_info_particle_mass_3d_diag(self)
integer(kind=i32) function index_3dto1d(num_pts, ind1, ind2, ind3)
subroutine free_particle_mass_3d_diag(self)