dolfin team mailing list archive
-
dolfin team
-
Mailing list archive
-
Message #19710
Fwd: [Branch ~dolfin-core/dolfin/error-control] Rev 5181: Actually assemble error indicators. Now, only need to compute residual
-
To:
DOLFIN Mailing List <dolfin@xxxxxxxxxxxxxxxxxxx>
-
From:
"Garth N. Wells" <gnw20@xxxxxxxxx>
-
Date:
Tue, 14 Sep 2010 15:34:11 +0100
-
User-agent:
Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.9) Gecko/20100903 Thunderbird/3.1.3
It would be good to used boost::scope_ptr rather than plain pointers in
the code. It makes ownership clear and avoids potential memory leaks.
Garth
-------- Original Message --------
Subject: [Branch ~dolfin-core/dolfin/error-control] Rev 5181: Actually
assemble error indicators. Now, only need to compute residual
Date: Tue, 14 Sep 2010 14:20:52 -0000
From: noreply@xxxxxxxxxxxxx
Reply-To: noreply@xxxxxxxxxxxxx
To: Garth Wells <gnw20@xxxxxxxxx>
------------------------------------------------------------
revno: 5181
committer: Marie E. Rognes <meg@xxxxxxxxx>
branch nick: dolfin-error-control
timestamp: Tue 2010-09-14 16:08:48 +0200
message:
Actually assemble error indicators. Now, only need to compute residual
representation.
modified:
dolfin/adaptivity/ErrorControl.cpp
dolfin/adaptivity/ErrorControl.h
--
lp:~dolfin-core/dolfin/error-control
https://code.launchpad.net/~dolfin-core/dolfin/error-control
Your team DOLFIN Core Team is subscribed to branch
lp:~dolfin-core/dolfin/error-control.
To unsubscribe from this branch go to
https://code.launchpad.net/~dolfin-core/dolfin/error-control/+edit-subscription
=== modified file 'dolfin/adaptivity/ErrorControl.cpp'
--- dolfin/adaptivity/ErrorControl.cpp 2010-09-14 13:28:05 +0000
+++ dolfin/adaptivity/ErrorControl.cpp 2010-09-14 14:08:48 +0000
@@ -62,7 +62,7 @@
// Assemble error estimate
const double error_estimate = assemble(*_residual);
- std::cout << "error_estimate = " << error_estimate << std::endl;
+ std::cout << "DEBUG: error_estimate = " << error_estimate << std::endl;
end();
@@ -92,9 +92,14 @@
plot(Pi_E_z_h);
// Attach coefficients to error indicator form
+ _eta_T->set_coefficient("Ez_h", *_Ez_h);
+ _eta_T->set_coefficient("R_T", R_T);
+ _eta_T->set_coefficient("R_dT", R_dT);
+ _eta_T->set_coefficient("z_h", Pi_E_z_h);
/// Assemble error indicator form
- //assemble(eta_T, tensor=indicators);
+ std::cout << "DEBUG: Assembling indicators" << std::endl;
+ assemble(indicators, *_eta_T);
end();
=== modified file 'dolfin/adaptivity/ErrorControl.h'
--- dolfin/adaptivity/ErrorControl.h 2010-09-14 13:28:05 +0000
+++ dolfin/adaptivity/ErrorControl.h 2010-09-14 14:08:48 +0000
@@ -46,10 +46,14 @@
Form* _residual;
// Bilinear and linear form for computing cell residual R_T
- FunctionSpace* _DG;
+ FunctionSpace* _DG_k;
Form* _a_R_T;
Form* _L_R_T;
+ // Linear form for computing error indicators
+ FunctionSpace* _DG_0;
+ Form* _eta_T;
+
// Stored extrapolation
Function* _Ez_h;
Follow ups