PISM, A Parallel Ice Sheet Model  stable v2.1.1 committed by Constantine Khrulev on 2024-12-04 13:36:58 -0900
AgeColumnSystem.hh
Go to the documentation of this file.
1 /* Copyright (C) 2016, 2017 PISM Authors
2  *
3  * This file is part of PISM.
4  *
5  * PISM is free software; you can redistribute it and/or modify it under the
6  * terms of the GNU General Public License as published by the Free Software
7  * Foundation; either version 3 of the License, or (at your option) any later
8  * version.
9  *
10  * PISM is distributed in the hope that it will be useful, but WITHOUT ANY
11  * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
12  * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
13  * details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with PISM; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18  */
19 
20 #ifndef AGECOLUMNSYSTEM_H
21 #define AGECOLUMNSYSTEM_H
22 
23 #include "pism/util/ColumnSystem.hh"
24 
25 namespace pism {
26 
27 //! Tridiagonal linear system for vertical column of age (pure advection) problem.
29 public:
30  AgeColumnSystem(const std::vector<double>& storage_grid,
31  const std::string &my_prefix,
32  double dx, double dy, double dt,
33  const array::Array3D &age,
34  const array::Array3D &u3,
35  const array::Array3D &v3,
36  const array::Array3D &w3);
37 
38  void init(int i, int j, double thickness);
39 
40  void solve(std::vector<double> &x);
41 protected:
43  double m_nu;
44  std::vector<double> m_A, m_A_n, m_A_e, m_A_s, m_A_w;
45 };
46 
47 } // end of namespace pism
48 
49 
50 #endif /* AGECOLUMNSYSTEM_H */
std::vector< double > m_A_s
std::vector< double > m_A_n
std::vector< double > m_A_w
AgeColumnSystem(const std::vector< double > &storage_grid, const std::string &my_prefix, double dx, double dy, double dt, const array::Array3D &age, const array::Array3D &u3, const array::Array3D &v3, const array::Array3D &w3)
std::vector< double > m_A_e
std::vector< double > m_A
void init(int i, int j, double thickness)
const array::Array3D & m_age3
void solve(std::vector< double > &x)
First-order upwind scheme with implicit in the vertical: one column solve.
Tridiagonal linear system for vertical column of age (pure advection) problem.
A virtual class collecting methods common to ice and bedrock 3D fields.
Definition: Array3D.hh:33
Base class for tridiagonal systems in the ice.