Loading...
Searching...
No Matches
GoalFunctional.h
// Copyright (C) 2010--2012 Marie E. Rognes
//
// This file is part of DOLFIN.
//
// DOLFIN is free software: you can redistribute it and/or modify
// it under the terms of the GNU Lesser General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// DOLFIN is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public License
// along with DOLFIN. If not, see <http://www.gnu.org/licenses/>.
//
// First added: 2010-09-16
// Last changed: 2012-11-14
#ifndef __GOAL_FUNCTIONAL_H
#define __GOAL_FUNCTIONAL_H
#include <memory>
#include <dolfin/fem/Form.h>
#include "ErrorControl.h"
namespace dolfin
{
class GoalFunctional : public Form
{
public:
// FIXME: The rank argument is unnecessary, a GoalFunction should
// always have rank 0. The argument should be removed for that
// reason.
GoalFunctional(std::size_t rank, std::size_t num_coefficients);
virtual void update_ec(const Form& a, const Form& L) = 0;
// Pointer to _ErrorControl_ instance
std::shared_ptr<ErrorControl> _ec;
};
}
#endif
dolfin::Form::rank
std::size_t rank() const
Definition Form.cpp:64
dolfin::Form::num_coefficients
std::size_t num_coefficients() const
Definition Form.cpp:75
dolfin::Form::Form
Form(std::size_t rank, std::size_t num_coefficients)
Definition Form.cpp:43
dolfin::GoalFunctional::update_ec
virtual void update_ec(const Form &a, const Form &L)=0
dolfin::GoalFunctional::GoalFunctional
GoalFunctional(std::size_t rank, std::size_t num_coefficients)
Definition GoalFunctional.cpp:28
dolfin
Definition adapt.h:30