BELFEM 0.9.0
Berkeley Lab Finite Element Framework
Loading...
Searching...
No Matches
st_SolverPetscData.hpp
Go to the documentation of this file.
1/*
2 * BELFEM -- The Berkeley Lab Finite Element Framework
3 * Copyright (c) 2026, The Regents of the University of California,
4 * through Lawrence Berkeley National Laboratory (subject to receipt of any required
5 * approvals from the U.S. Dept. of Energy). All rights reserved.
6 *
7 * Developers: Christian Messe, Gregory Giard
8 *
9 * See the top-level LICENSE file for the complete license and disclaimer.
10 */
11
12#ifndef BELFEM_ST_SOLVERPETSCDATA_HPP
13#define BELFEM_ST_SOLVERPETSCDATA_HPP
14#include "petsctools.hpp"
15
16namespace belfem
17{
18 namespace solver
19 {
20//------------------------------------------------------------------------------
21
27 struct PetscData
28 {
29 // communicator that is used
31
32 // index arrays for solver
33 Vector <PetscInt> mMyPointers ;
34 Vector <PetscInt> mMyColumns ;
35 Vector <PetscInt> mMyRows ;
36
37 // indices for vectors
38 Vector <PetscInt> mVectorIndices ;
39
40 // global number of colums for RHS and LHS
43
44 // proc local number of colums for RHS and LHS
47
48 // row offset for indices
50
51 // number of nonzeros on this proc
53
54 // vector for left hand side
56
57 // vector for right hand side
59
60 // matrix wrapper
62
63 // solver object
65
66 // preconditioner context
68 };
69
70//------------------------------------------------------------------------------
71 }
72}
73#endif //BELFEM_ST_SOLVERPETSCDATA_HPP
Definition petsctools.hpp:33
Definition petsctools.hpp:27
Definition petsctools.hpp:30
Definition petsctools.hpp:24
Definition cl_SolverMUMPS.cpp:26
USER GUIDES:
Definition cl_Capacitor.cpp:16
int PetscInt
Definition petsctools.hpp:20
int MPI_Comm
Definition petsctools.hpp:40
this struct contains the variables needed by PETSc
Definition st_SolverPetscData.hpp:28
MPI_Comm mComm
Definition st_SolverPetscData.hpp:30
Vector< PetscInt > mMyRows
Definition st_SolverPetscData.hpp:35
PetscInt mMyNumNnz
Definition st_SolverPetscData.hpp:52
PetscInt mNumCols
Definition st_SolverPetscData.hpp:42
Vec mLHS
Definition st_SolverPetscData.hpp:55
Mat mMat
Definition st_SolverPetscData.hpp:61
PetscInt mNumRows
Definition st_SolverPetscData.hpp:41
Vector< PetscInt > mVectorIndices
Definition st_SolverPetscData.hpp:38
PetscInt mMyRowOffset
Definition st_SolverPetscData.hpp:49
PetscInt mMyNumCols
Definition st_SolverPetscData.hpp:46
Vector< PetscInt > mMyColumns
Definition st_SolverPetscData.hpp:34
KSP mKSP
Definition st_SolverPetscData.hpp:64
Vec mRHS
Definition st_SolverPetscData.hpp:58
PetscInt mMyNumRows
Definition st_SolverPetscData.hpp:45
Vector< PetscInt > mMyPointers
Definition st_SolverPetscData.hpp:33
PC mPC
Definition st_SolverPetscData.hpp:67