From: Guido Kanschat Date: Wed, 7 Jul 2010 14:56:48 +0000 (+0000) Subject: ThetaTimestepping is running X-Git-Tag: v8.0.0~5848 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bea82cd3cc87afc8d2ca7a881bfaca5793d3d755;p=dealii.git ThetaTimestepping is running git-svn-id: https://svn.dealii.org/trunk@21458 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/examples/doxygen/product_matrix.cc b/deal.II/examples/doxygen/product_matrix.cc index 931a1641ce..c71b81e6d5 100644 --- a/deal.II/examples/doxygen/product_matrix.cc +++ b/deal.II/examples/doxygen/product_matrix.cc @@ -1,7 +1,7 @@ //--------------------------------------------------------------------------- // $Id$ // -// Copyright (C) 2005, 2006 by the deal.II authors +// Copyright (C) 2005, 2006, 2010 by the deal.II authors // // This file is subject to QPL and may not be distributed // without copyright and license information. Please refer @@ -10,7 +10,7 @@ // //--------------------------------------------------------------------------- -// See documentation of Product for documentation of this example +// See documentation of ProductMatrix for documentation of this example #include #include diff --git a/deal.II/examples/doxygen/theta_timestepping.cc b/deal.II/examples/doxygen/theta_timestepping.cc index 6f42cbd37f..a3c9436ef0 100644 --- a/deal.II/examples/doxygen/theta_timestepping.cc +++ b/deal.II/examples/doxygen/theta_timestepping.cc @@ -82,7 +82,10 @@ int main() Explicit::Explicit(const FullMatrix& M) : matrix(&M) -{} +{ + m.reinit(M.m(), M.n()); + m = M; +} void @@ -97,6 +100,7 @@ Explicit::operator() (NamedData*>& out, const NamedDatanotifications.print(deallog); deallog << std::endl; + this->notifications.clear(); unsigned int i = in.find("Previous time"); m.vmult(*out(0), *in(i)); } @@ -105,7 +109,9 @@ Explicit::operator() (NamedData*>& out, const NamedData& M) : matrix(&M) -{} +{ + m.reinit(M.m(), M.n()); +} void @@ -120,6 +126,15 @@ Implicit::operator() (NamedData*>& out, const NamedDatanotifications.print(deallog); deallog << std::endl; + if (this->notifications.test(Events::initial) || this->notifications.test(Events::new_timestep_size)) + { + m.equ(timestep_data->step, *matrix); + for (unsigned int i=0;inotifications.clear(); + unsigned int i = in.find("Previous time"); m.vmult(*out(0), *in(i)); }