DFT-FE 1.1.0-pre
Density Functional Theory With Finite-Elements
Loading...
Searching...
No Matches
AtomicCenteredNonLocalOperatorKernelsDevice.h
Go to the documentation of this file.
1// ---------------------------------------------------------------------
2//
3// Copyright (c) 2017-2025 The Regents of the University of Michigan and DFT-FE
4// authors.
5//
6// This file is part of the DFT-FE code.
7//
8// The DFT-FE code is free software; you can use it, redistribute
9// it, and/or modify it under the terms of the GNU Lesser General
10// Public License as published by the Free Software Foundation; either
11// version 2.1 of the License, or (at your option) any later version.
12// The full text of the license can be found in the file LICENSE at
13// the top level of the DFT-FE distribution.
14//
15// ---------------------------------------------------------------------
16//
17// @author Kartick Ramakrishnan
18//
19#ifndef DFTFE_ATOMICCENTEREDNONLOCALOPERATORDEVICEKERNELS_H
20#define DFTFE_ATOMICCENTEREDNONLOCALOPERATORDEVICEKERNELS_H
21
23#include <DeviceAPICalls.h>
25#include <DeviceTypeConfig.h>
27#include <MemoryStorage.h>
28namespace dftfe
29{
31 {
32 template <typename ValueType>
33 void
35 const dftfe::uInt numWfcs,
36 const dftfe::uInt numNonLocalCells,
37 const dftfe::uInt maxSingleAtomPseudoWfc,
38 const ValueType *sphericalFnTimesWfcParallelVec,
39 ValueType *sphericalFnTimesWfcAllCellsVec,
40 const dftfe::Int *indexMapPaddedToParallelVec);
41
42
43 template <typename ValueType>
44 void
46 const dftfe::uInt numWfcs,
47 const dftfe::uInt totalEntries,
48 const ValueType *sphericalFnTimesWfcParallelVec,
49 ValueType *sphericalFnTimesWfcDealiiParallelVec,
50 const dftfe::uInt *indexMapDealiiParallelNumbering);
51
52 template <typename ValueType>
53 void
55 const dftfe::uInt numWfcs,
56 const dftfe::uInt totalEntriesPadded,
57 const ValueType *sphericalFnTimesWfcDealiiParallelVec,
58 ValueType *sphericalFnTimesWfcPaddedVec,
59 const dftfe::Int *indexMapDealiiParallelNumbering);
60
61 template <typename ValueType>
62 void
64 const dftfe::uInt numWfcs,
65 const dftfe::uInt totalEntriesPadded,
66 const ValueType *sphericalFnTimesWfcPaddedVec,
67 ValueType *sphericalFnTimesWfcDealiiParallelVec,
68 const dftfe::Int *indexMapDealiiParallelNumbering);
69
70 template <typename ValueType>
71 void
73 const dftfe::uInt numberCellsForAtom,
74 const dftfe::uInt numberNodesPerElement,
75 const dftfe::uInt numberWfc,
76 const dftfe::uInt numberCellsTraversed,
77 const dftfe::utils::MemoryStorage<ValueType,
79 &nonLocalContribution,
80 ValueType *TotalContribution,
83 &cellNodeIdMapNonLocalToLocal);
84 template <typename ValueType>
85 void
87 const dftfe::uInt totalNonLocalElements,
88 const dftfe::uInt numberWfc,
89 const dftfe::uInt numberNodesPerElement,
92 &iElemNonLocalToElemIndexMap,
93 const dftfe::utils::MemoryStorage<ValueType,
95 &nonLocalContribution,
96 ValueType *TotalContribution);
97
98 template <typename ValueType>
99 void
101 const dftfe::uInt maxSingleAtomContribution,
102 const dftfe::uInt numWfcs,
103 const dftfe::uInt totalAtomsInCurrentProcessor,
104 const double *scalingVector,
105 ValueType *sphericalFnTimesWfcPadded);
106
107 template <typename ValueType>
108 void
110 const dftfe::uInt numberWaveFunctions,
111 const dftfe::uInt totalNonlocalElems,
112 const dftfe::uInt maxSingleAtomContribution,
113 const dftfe::uInt totalNonlocalEntries,
114 const dftfe::utils::MemoryStorage<ValueType,
116 &sphericalFnTimesVectorAllCellsDevice,
119 &mapSphericalFnTimesVectorAllCellsReductionDevice,
121 &sphericalFnTimesWavefunctionMatrix);
122
123
124 } // namespace AtomicCenteredNonLocalOperatorKernelsDevice
125
126
127
128} // namespace dftfe
129
130#endif // DFTFE_ATOMICCENTEREDNONLOCALOPERATORDEVICEKERNELS_H
Definition MemoryStorage.h:33
Definition AtomicCenteredNonLocalOperatorKernelsDevice.h:31
void addNonLocalContribution(const dftfe::uInt numberCellsForAtom, const dftfe::uInt numberNodesPerElement, const dftfe::uInt numberWfc, const dftfe::uInt numberCellsTraversed, const dftfe::utils::MemoryStorage< ValueType, dftfe::utils::MemorySpace::DEVICE > &nonLocalContribution, ValueType *TotalContribution, const dftfe::utils::MemoryStorage< dftfe::uInt, dftfe::utils::MemorySpace::DEVICE > &cellNodeIdMapNonLocalToLocal)
void sqrtAlphaScalingWaveFunctionEntries(const dftfe::uInt maxSingleAtomContribution, const dftfe::uInt numWfcs, const dftfe::uInt totalAtomsInCurrentProcessor, const double *scalingVector, ValueType *sphericalFnTimesWfcPadded)
void copyFromParallelNonLocalVecToAllCellsVec(const dftfe::uInt numWfcs, const dftfe::uInt numNonLocalCells, const dftfe::uInt maxSingleAtomPseudoWfc, const ValueType *sphericalFnTimesWfcParallelVec, ValueType *sphericalFnTimesWfcAllCellsVec, const dftfe::Int *indexMapPaddedToParallelVec)
void assembleAtomLevelContributionsFromCellLevel(const dftfe::uInt numberWaveFunctions, const dftfe::uInt totalNonlocalElems, const dftfe::uInt maxSingleAtomContribution, const dftfe::uInt totalNonlocalEntries, const dftfe::utils::MemoryStorage< ValueType, dftfe::utils::MemorySpace::DEVICE > &sphericalFnTimesVectorAllCellsDevice, const dftfe::utils::MemoryStorage< dftfe::uInt, dftfe::utils::MemorySpace::DEVICE > &mapSphericalFnTimesVectorAllCellsReductionDevice, dftfe::utils::MemoryStorage< ValueType, dftfe::utils::MemorySpace::DEVICE > &sphericalFnTimesWavefunctionMatrix)
void copyToDealiiParallelNonLocalVec(const dftfe::uInt numWfcs, const dftfe::uInt totalEntries, const ValueType *sphericalFnTimesWfcParallelVec, ValueType *sphericalFnTimesWfcDealiiParallelVec, const dftfe::uInt *indexMapDealiiParallelNumbering)
void copyFromDealiiParallelNonLocalVecToPaddedVector(const dftfe::uInt numWfcs, const dftfe::uInt totalEntriesPadded, const ValueType *sphericalFnTimesWfcDealiiParallelVec, ValueType *sphericalFnTimesWfcPaddedVec, const dftfe::Int *indexMapDealiiParallelNumbering)
void copyToDealiiParallelNonLocalVecFromPaddedVector(const dftfe::uInt numWfcs, const dftfe::uInt totalEntriesPadded, const ValueType *sphericalFnTimesWfcPaddedVec, ValueType *sphericalFnTimesWfcDealiiParallelVec, const dftfe::Int *indexMapDealiiParallelNumbering)
@ DEVICE
Definition MemorySpaceType.h:36
Definition pseudoPotentialToDftfeConverter.cc:34
std::uint32_t uInt
Definition TypeConfig.h:10
std::int32_t Int
Definition TypeConfig.h:11