From: wolf Date: Tue, 2 May 2006 02:01:15 +0000 (+0000) Subject: Split out common functions that are needed for all space dimensions X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8a2f7bcc031e950398cf516b82f4bbde8076bf32;p=dealii-svn.git Split out common functions that are needed for all space dimensions git-svn-id: https://svn.dealii.org/trunk@12951 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/deal.II/source/dofs/dof_levels.all_dimensions.cc b/deal.II/deal.II/source/dofs/dof_levels.all_dimensions.cc new file mode 100644 index 0000000000..5f8db8fa7e --- /dev/null +++ b/deal.II/deal.II/source/dofs/dof_levels.all_dimensions.cc @@ -0,0 +1,57 @@ +//--------------------------------------------------------------------------- +// $Id$ +// Version: $Name$ +// +// Copyright (C) 2000, 2001, 2002, 2003, 2005, 2006 by the deal.II authors +// +// This file is subject to QPL and may not be distributed +// without copyright and license information. Please refer +// to the file deal.II/doc/license.html for the text and +// further information on this license. +// +//--------------------------------------------------------------------------- + + +#include +#include + + +namespace internal +{ + namespace DoFHandler + { + + unsigned int + DoFLevel<0>::memory_consumption () const + { + return MemoryConsumption::memory_consumption (cell_dof_indices_cache); + } + + + unsigned int + DoFLevel<1>::memory_consumption () const + { + return (DoFLevel<0>::memory_consumption () + + MemoryConsumption::memory_consumption (line_dofs)); + } + + + + unsigned int + DoFLevel<2>::memory_consumption () const + { + return (DoFLevel<1>::memory_consumption () + + MemoryConsumption::memory_consumption (quad_dofs)); + } + + + + unsigned int + DoFLevel<3>::memory_consumption () const + { + return (DoFLevel<2>::memory_consumption () + + MemoryConsumption::memory_consumption (hex_dofs)); + } + } + +} diff --git a/deal.II/deal.II/source/dofs/dof_levels.cc b/deal.II/deal.II/source/dofs/dof_levels.cc index 3d2cef2538..1ed76d3259 100644 --- a/deal.II/deal.II/source/dofs/dof_levels.cc +++ b/deal.II/deal.II/source/dofs/dof_levels.cc @@ -23,41 +23,6 @@ namespace internal { namespace DoFHandler { - - unsigned int - DoFLevel<0>::memory_consumption () const - { - return MemoryConsumption::memory_consumption (cell_dof_indices_cache); - } - - - unsigned int - DoFLevel<1>::memory_consumption () const - { - return (DoFLevel<0>::memory_consumption () + - MemoryConsumption::memory_consumption (line_dofs)); - } - - - - unsigned int - DoFLevel<2>::memory_consumption () const - { - return (DoFLevel<1>::memory_consumption () + - MemoryConsumption::memory_consumption (quad_dofs)); - } - - - - unsigned int - DoFLevel<3>::memory_consumption () const - { - return (DoFLevel<2>::memory_consumption () + - MemoryConsumption::memory_consumption (hex_dofs)); - } - - - template unsigned int DoFLevel<1>::