Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Mpp
MLUQ
Commits
fcc461d9
Commit
fcc461d9
authored
May 03, 2021
by
niklas.baumgarten
Browse files
formatting
parent
d3924894
Pipeline
#147914
failed with stages
in 9 minutes and 30 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
mlmc/src/pdesolver/PDESolver.cpp
View file @
fcc461d9
...
...
@@ -25,8 +25,7 @@ void EllipticPDESolver::computeQ(SampleSolution &solution) {
else
if
(
quantity
==
"H1"
)
solution
.
Q
=
assemble
->
H1
(
solution
.
U
);
else
if
(
quantity
==
"Energy"
)
solution
.
Q
=
assemble
->
Energy
(
solution
.
U
);
else
if
(
quantity
==
"Inflow"
)
solution
.
Q
=
assemble
->
InflowOutflow
(
solution
.
U
).
first
;
else
if
(
quantity
==
"Outflow"
)
solution
.
Q
=
assemble
->
InflowOutflow
(
solution
.
U
).
second
;
else
if
(
quantity
==
"Outflow"
)
solution
.
Q
=
assemble
->
InflowOutflow
(
solution
.
U
).
second
;
else
if
(
quantity
==
"L2Error"
)
solution
.
Q
=
assemble
->
L2Error
(
solution
.
U
);
else
if
(
quantity
==
"EnergyError"
)
solution
.
Q
=
assemble
->
EnergyError
(
solution
.
U
);
else
if
(
quantity
==
"L2CellAverageError"
)
...
...
@@ -70,18 +69,15 @@ void EllipticPDESolver::plotSolution(SampleSolution &solution) {
}
void
TransportPDESolver
::
run
(
SampleSolution
&
solution
)
{
auto
timeSeries
=
assemble
->
GetTimeSeries
(
solution
.
U
);
timeInt
->
Method
(
assemble
,
solution
.
U
);
}
void
TransportPDESolver
::
computeQ
(
SampleSolution
&
solution
)
{
if
(
quantity
==
"Energy"
)
solution
.
Q
=
assemble
->
Energy
(
solution
.
U
);
else
if
(
quantity
==
"Mass"
)
solution
.
Q
=
assemble
->
Mass
(
solution
.
U
);
else
if
(
quantity
==
"Error"
)
solution
.
Q
=
assemble
->
Error
(
0
,
solution
.
U
);
// Todo
else
if
(
quantity
==
"Inflow"
)
solution
.
Q
=
assemble
->
InFlowOutFlowRate
(
solution
.
U
).
first
;
else
if
(
quantity
==
"Outflow"
)
solution
.
Q
=
assemble
->
InFlowOutFlowRate
(
solution
.
U
).
second
;
else
if
(
quantity
==
"Error"
)
solution
.
Q
=
assemble
->
Error
(
0
,
solution
.
U
);
else
if
(
quantity
==
"Inflow"
)
solution
.
Q
=
assemble
->
InflowOutflow
(
solution
.
U
).
first
;
else
if
(
quantity
==
"Outflow"
)
solution
.
Q
=
assemble
->
InflowOutflow
(
solution
.
U
).
second
;
// else if (quantity == "L2Error") solution.Q = assemble->L2Error(solution.U);
// else if (quantity == "EnergyError") solution.Q = assemble->EnergyError(solution.U);
else
Exit
(
"Quantity of interest not implemented"
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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