@@ -152,7 +152,7 @@ int DiagoDavid<T, Device>::diag_once(const HPsiFunc& hpsi_func,
152152 const SPsiFunc& spsi_func,
153153 const int dim,
154154 const int nband,
155- const int ldPsi ,
155+ const int ld_psi ,
156156 T *psi_in,
157157 Real* eigenvalue_in,
158158 const Real david_diag_thr,
@@ -191,20 +191,20 @@ int DiagoDavid<T, Device>::diag_once(const HPsiFunc& hpsi_func,
191191 if (this ->use_paw )
192192 {
193193#ifdef USE_PAW
194- GlobalC::paw_cell.paw_nl_psi (1 , reinterpret_cast <const std::complex <double >*> (psi_in + m*ldPsi ),
194+ GlobalC::paw_cell.paw_nl_psi (1 , reinterpret_cast <const std::complex <double >*> (psi_in + m*ld_psi ),
195195 reinterpret_cast <std::complex <double >*>(&this ->spsi [m * dim]));
196196#endif
197197 }
198198 else
199199 {
200- // phm_in->sPsi(psi_in + m*ldPsi , &this->spsi[m * dim], dim, dim, 1);
201- spsi_func (psi_in + m*ldPsi ,&this ->spsi [m*dim],dim,dim,1 );
200+ // phm_in->sPsi(psi_in + m*ld_psi , &this->spsi[m * dim], dim, dim, 1);
201+ spsi_func (psi_in + m*ld_psi ,&this ->spsi [m*dim],dim,dim,1 );
202202 }
203203 }
204204 // begin SchmidtOrth
205205 for (int m = 0 ; m < nband; m++)
206206 {
207- syncmem_complex_op ()(this ->ctx , this ->ctx , basis + dim*m, psi_in + m*ldPsi , dim);
207+ syncmem_complex_op ()(this ->ctx , this ->ctx , basis + dim*m, psi_in + m*ld_psi , dim);
208208
209209 this ->SchmidtOrth (dim,
210210 nband,
@@ -289,7 +289,7 @@ int DiagoDavid<T, Device>::diag_once(const HPsiFunc& hpsi_func,
289289
290290 // update eigenvectors of Hamiltonian
291291
292- setmem_complex_op ()(this ->ctx , psi_in, 0 , nband * ldPsi );
292+ setmem_complex_op ()(this ->ctx , psi_in, 0 , nband * ld_psi );
293293 // <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
294294 gemm_op<T, Device>()(this ->ctx ,
295295 ' N' ,
@@ -304,7 +304,7 @@ int DiagoDavid<T, Device>::diag_once(const HPsiFunc& hpsi_func,
304304 nbase_x,
305305 this ->zero ,
306306 psi_in, // C dim * nband
307- ldPsi
307+ ld_psi
308308 );
309309
310310 if (!this ->notconv || (dav_iter == david_maxiter))
@@ -324,7 +324,7 @@ int DiagoDavid<T, Device>::diag_once(const HPsiFunc& hpsi_func,
324324 nbase_x,
325325 eigenvalue_in,
326326 psi_in,
327- ldPsi ,
327+ ld_psi ,
328328 this ->hpsi ,
329329 this ->spsi ,
330330 this ->hcc ,
@@ -788,7 +788,7 @@ void DiagoDavid<T, Device>::diag_zhegvx(const int& nbase,
788788 * @param nbase_x The maximum dimension of the reduced basis set.
789789 * @param eigenvalue_in Pointer to the array of eigenvalues.
790790 * @param psi_in Pointer to the array of wavefunctions.
791- * @param ldPsi The leading dimension of the wavefunction array.
791+ * @param ld_psi The leading dimension of the wavefunction array.
792792 * @param hpsi Pointer to the output array for the updated basis set.
793793 * @param spsi Pointer to the output array for the updated basis set (nband-th column).
794794 * @param hcc Pointer to the output array for the updated reduced Hamiltonian.
@@ -803,7 +803,7 @@ void DiagoDavid<T, Device>::refresh(const int& dim,
803803 const int nbase_x, // maximum dimension of the reduced basis set
804804 const Real* eigenvalue_in,
805805 const T *psi_in,
806- const int ldPsi ,
806+ const int ld_psi ,
807807 T* hpsi,
808808 T* spsi,
809809 T* hcc,
@@ -869,7 +869,7 @@ void DiagoDavid<T, Device>::refresh(const int& dim,
869869
870870 for (int m = 0 ; m < nband; m++)
871871 {
872- syncmem_complex_op ()(this ->ctx , this ->ctx , basis + dim*m,psi_in + m*ldPsi , dim);
872+ syncmem_complex_op ()(this ->ctx , this ->ctx , basis + dim*m,psi_in + m*ld_psi , dim);
873873 /* for (int ig = 0; ig < npw; ig++)
874874 basis(m, ig) = psi(m, ig);*/
875875 }
@@ -1158,7 +1158,7 @@ void DiagoDavid<T, Device>::planSchmidtOrth(const int nband, std::vector<int>& p
11581158 * @tparam Device The device type (CPU or GPU).
11591159 * @param hpsi_func The function object that computes the matrix-blockvector product H * psi.
11601160 * @param spsi_func The function object that computes the matrix-blockvector product overlap S * psi.
1161- * @param ldPsi The leading dimension of the psi_in array.
1161+ * @param ld_psi The leading dimension of the psi_in array.
11621162 * @param psi_in The input wavefunction.
11631163 * @param eigenvalue_in The array to store the eigenvalues.
11641164 * @param david_diag_thr The convergence threshold for the diagonalization.
@@ -1173,7 +1173,7 @@ void DiagoDavid<T, Device>::planSchmidtOrth(const int nband, std::vector<int>& p
11731173template <typename T, typename Device>
11741174int DiagoDavid<T, Device>::diag(const HPsiFunc& hpsi_func,
11751175 const SPsiFunc& spsi_func,
1176- const int ldPsi ,
1176+ const int ld_psi ,
11771177 T *psi_in,
11781178 Real* eigenvalue_in,
11791179 const Real david_diag_thr,
@@ -1188,7 +1188,7 @@ int DiagoDavid<T, Device>::diag(const HPsiFunc& hpsi_func,
11881188 int sum_dav_iter = 0 ;
11891189 do
11901190 {
1191- sum_dav_iter += this ->diag_once (hpsi_func, spsi_func, dim, nband, ldPsi , psi_in, eigenvalue_in, david_diag_thr, david_maxiter);
1191+ sum_dav_iter += this ->diag_once (hpsi_func, spsi_func, dim, nband, ld_psi , psi_in, eigenvalue_in, david_diag_thr, david_maxiter);
11921192 ++ntry;
11931193 } while (!check_block_conv (ntry, this ->notconv , ntry_max, notconv_max));
11941194
0 commit comments