Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
S
swe_solvers
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Gaurav Kukreja
swe_solvers
Commits
a79ebaa7
Commit
a79ebaa7
authored
Mar 08, 2013
by
Alexander Breuer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added output of eigencoefficients.
parent
9f7fe2f2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
29 additions
and
4 deletions
+29
-4
AugRie.hpp
src/solver/AugRie.hpp
+24
-3
WavePropagation.hpp
src/solver/WavePropagation.hpp
+5
-1
No files found.
src/solver/AugRie.hpp
View file @
a79ebaa7
...
...
@@ -229,7 +229,11 @@ template <typename T> class solver::AugRie: public WavePropagation<T> {
T
&
o_hUpdateRight
,
T
&
o_huUpdateLeft
,
T
&
o_huUpdateRight
,
T
&
o_maxWaveSpeed
)
{
T
&
o_maxWaveSpeed
#if CONFIG_TSUNAMI_AUGMENTED_RIEMANN_EIGEN_COEFFICIENTS
,
T
o_eigenCoefficients
[
3
]
#endif
)
{
// store parameters to member variables
storeParameters
(
i_hLeft
,
i_hRight
,
i_huLeft
,
i_huRight
,
...
...
@@ -242,6 +246,11 @@ template <typename T> class solver::AugRie: public WavePropagation<T> {
o_hUpdateLeft
=
o_hUpdateRight
=
o_huUpdateLeft
=
o_huUpdateRight
=
(
T
)
0.
;
o_maxWaveSpeed
=
(
T
)
0.
;
#if CONFIG_TSUNAMI_AUGMENTED_RIEMANN_EIGEN_COEFFICIENTS
// reset eigen coefficients
o_eigenCoefficients
[
0
]
=
o_eigenCoefficients
[
1
]
=
o_eigenCoefficients
[
2
]
=
0
;
#endif
//determine the wet/dry state and compute local variables correspondingly
determineWetDryState
();
...
...
@@ -266,7 +275,11 @@ template <typename T> class solver::AugRie: public WavePropagation<T> {
//compute the augmented decomposition
// (thats the place where the computational work is done..)
computeWaveDecomposition
(
fWaves
,
waveSpeeds
);
waveSpeeds
#if CONFIG_TSUNAMI_AUGMENTED_RIEMANN_EIGEN_COEFFICIENTS
,
o_eigenCoefficients
#endif
);
//compute the updates from the three propagating waves
...
...
@@ -424,7 +437,11 @@ template <typename T> class solver::AugRie: public WavePropagation<T> {
* @param o_waveSpeeds will be set to: speeds of the linearized waves (eigenvalues).
*/
inline
void
computeWaveDecomposition
(
T
o_fWaves
[
3
][
2
],
T
o_waveSpeeds
[
3
]
)
{
T
o_waveSpeeds
[
3
]
#if CONFIG_TSUNAMI_AUGMENTED_RIEMANN_EIGEN_COEFFICIENTS
,
T
o_eigenCoefficients
[
3
]
#endif
)
{
//compute eigenvalues of the jacobian matrices in states Q_{i-1} and Q_{i} (char. speeds)
T
characteristicSpeeds
[
2
];
characteristicSpeeds
[
0
]
=
uLeft
-
sqrt_g_hLeft
;
...
...
@@ -674,6 +691,10 @@ template <typename T> class solver::AugRie: public WavePropagation<T> {
for
(
int
waveNumber
=
0
;
waveNumber
<
3
;
waveNumber
++
)
{
o_fWaves
[
waveNumber
][
0
]
=
beta
[
waveNumber
]
*
eigenVectors
[
1
][
waveNumber
];
//select 2nd and
o_fWaves
[
waveNumber
][
1
]
=
beta
[
waveNumber
]
*
eigenVectors
[
2
][
waveNumber
];
//3rd component of the augmented decomposition
#if CONFIG_TSUNAMI_AUGMENTED_RIEMANN_EIGEN_COEFFICIENTS
// store eigen-coefficients
o_eigenCoefficients
[
waveNumber
]
=
beta
[
waveNumber
];
#endif
}
o_waveSpeeds
[
0
]
=
eigenValues
[
0
];
...
...
src/solver/WavePropagation.hpp
View file @
a79ebaa7
...
...
@@ -191,7 +191,11 @@ template <typename T> class solver::WavePropagation {
T
&
o_hUpdateRight
,
T
&
o_huUpdateLeft
,
T
&
o_huUpdateRight
,
T
&
o_maxWaveSpeed
)
=
0
;
T
&
o_maxWaveSpeed
#if CONFIG_TSUNAMI_AUGMENTED_RIEMANN_EIGEN_COEFFICIENTS
,
T
o_eigenCoefficients
[
3
]
#endif
)
=
0
;
/**
* Sets the dry tolerance of the solver.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment