Loading [MathJax]/extensions/tex2jax.js
PISM, A Parallel Ice Sheet Model
2.2.2-d6b3a29ca committed by Constantine Khrulev on 2025-03-28
Toggle main menu visibility
Main Page
Related Pages
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
z
Variables
a
b
c
d
f
g
h
i
k
l
m
n
r
s
t
u
v
w
Typedefs
Enumerations
a
b
c
d
e
f
i
k
l
m
n
p
r
t
u
v
Enumerator
_
a
b
c
d
e
f
g
h
i
l
m
n
p
q
s
t
u
w
x
y
z
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
:
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
a
c
d
f
g
h
l
m
p
s
v
w
Enumerations
Enumerator
c
d
e
f
h
i
j
m
n
o
p
r
s
t
w
y
Related Symbols
Files
File List
File Members
All
_
a
b
c
d
e
f
g
h
i
k
l
m
n
p
r
s
t
u
w
z
Functions
a
b
c
d
e
f
g
h
i
l
m
p
r
s
u
Variables
b
c
d
e
g
h
k
l
m
n
p
r
s
t
u
w
z
Typedefs
Macros
_
a
b
c
g
h
i
k
m
n
r
s
t
u
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
Loading...
Searching...
No Matches
src
geometry
MPDATA2.hh
Go to the documentation of this file.
1
/* Copyright (C) 2020, 2021, 2022 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 PISM_MPDATA_2D_H
21
#define PISM_MPDATA_2D_H
22
23
#include "pism/util/array/Scalar.hh"
24
#include "pism/util/array/Vector.hh"
25
#include "pism/util/array/Staggered.hh"
26
27
namespace
pism
{
28
29
class
Grid;
30
31
namespace
array {
32
class
CellType;
33
}
// end of namespace array
34
35
class
MPDATA2
{
36
public
:
37
MPDATA2
(std::shared_ptr<const Grid> grid,
int
N);
38
39
void
update
(
double
dt,
40
const
array::CellType
&cell_type,
41
const
array::Scalar
&
x
,
42
const
array::Vector
&velocity,
43
bool
nonoscillatory =
false
);
44
45
const
array::Scalar
&
x
()
const
;
46
47
private
:
48
// interface velocity (on the staggered grid; ghosted)
49
array::Staggered1
m_v
,
m_v_old
;
50
51
array::Vector1
m_v_ghosted
;
52
53
// temporary storage for the result of the previous iteration
54
array::Scalar2
m_x_previous
;
55
array::Scalar2
m_x_input
;
56
57
// advected quantity
58
array::Scalar
m_x
;
59
60
// number of iterations
61
int
m_N
;
62
};
35
class
MPDATA2
{
…
};
63
64
}
// end of namespace pism
65
66
#endif
/* PISM_MPDATA_2D_H */
pism::MPDATA2::m_x_input
array::Scalar2 m_x_input
Definition
MPDATA2.hh:55
pism::MPDATA2::m_v_ghosted
array::Vector1 m_v_ghosted
Definition
MPDATA2.hh:51
pism::MPDATA2::m_v_old
array::Staggered1 m_v_old
Definition
MPDATA2.hh:49
pism::MPDATA2::m_v
array::Staggered1 m_v
Definition
MPDATA2.hh:49
pism::MPDATA2::m_N
int m_N
Definition
MPDATA2.hh:61
pism::MPDATA2::x
const array::Scalar & x() const
Definition
MPDATA2.cc:163
pism::MPDATA2::m_x
array::Scalar m_x
Definition
MPDATA2.hh:58
pism::MPDATA2::m_x_previous
array::Scalar2 m_x_previous
Definition
MPDATA2.hh:54
pism::MPDATA2::update
void update(double dt, const array::CellType &cell_type, const array::Scalar &x, const array::Vector &velocity, bool nonoscillatory=false)
Definition
MPDATA2.cc:309
pism::MPDATA2
Definition
MPDATA2.hh:35
pism::array::CellType
"Cell type" mask. Adds convenience methods to array::Scalar.
Definition
CellType.hh:30
pism::array::Scalar2
Definition
Scalar.hh:67
pism::array::Scalar
Definition
Scalar.hh:31
pism::array::Staggered1
Definition
Staggered.hh:64
pism::array::Vector1
Definition
Vector.hh:44
pism::array::Vector
Definition
Vector.hh:32
pism
Definition
AgeColumnSystem.cc:23
Generated by
1.9.8