Evolving surface finite element method  v0.3.0-14-g3598512
Numerical experiments for my papers
Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
Esfem::Impl::Vec_rhs_fun Class Reference

Vector valued right-hand side for the mean curvature equation. More...

#include <secOrd_op_rhs_impl.h>

Inheritance diagram for Esfem::Impl::Vec_rhs_fun:
Inheritance graph
[legend]
Collaboration diagram for Esfem::Impl::Vec_rhs_fun:
Collaboration graph
[legend]

Public Types

using Base = Esfem::Grid::Grid_and_time::Vec_Function_space
 Template argument.
 
using Domain = Base::DomainType
 $ \R^3 $
 
using Range = Base::RangeType
 $ \R^3 $
 

Public Member Functions

 Vec_rhs_fun (const Dune::Fem::TimeProviderBase &)
 Get time and time step. More...
 
 Vec_rhs_fun (const Vec_rhs_fun &)=delete
 No copy construct.
 
Vec_rhs_funoperator= (const Vec_rhs_fun &)=delete
 No copy assignment.
 
void evaluate (const Domain &, Range &) const
 y = f(x)
 
Range operator() (const Domain &) const
 y = f(x)
 

Private Member Functions

void update_cache () const
 Conditional update member cache More...
 

Private Attributes

const Dune::Fem::TimeProviderBase & tp
 Time and time step.
 
double alpha
 $\alpha \Delta v$
 
double epsilon
 $ \varepsilon \Delta X$
 
double r_start
 Initial size of sphere.
 
double r_end
 Final size of sphere.
 
double k
 Steepness of logistic growh.
 
double delta
 $\delta u$
 
double cache [4]
 Helper variable, which save computations.
 

Detailed Description

Vector valued right-hand side for the mean curvature equation.

This is my right-hand function:

\[ \biggl[ k \Bigl( 1 - \frac{r(t)}{r_{end}}\Bigr) \lvert X \rvert + 2 \Bigl(\alpha k \Bigl( 1 - \frac{r(t)}{r_{end}}\Bigr) + \varepsilon \Bigr) \frac{1}{\lvert X \rvert} - \delta xy e^{-6t}\biggr] \]

Currently I am testing. So, I use an easier right-hand side. I am doing classic mean curvature flow on the sphere. Right-hand side must be zero for this example. Also I expect unit sphere as starting value, alpha = 0 and epsilon = 1.

Old test, which I want to check again later:

Definition at line 97 of file secOrd_op_rhs_impl.h.

Constructor & Destructor Documentation

Vec_rhs_fun::Vec_rhs_fun ( const Dune::Fem::TimeProviderBase &  tpb)
explicit

Get time and time step.

Warning
If time provider outlives this, then you are in problem.

Definition at line 103 of file secOrd_op_rhs_impl.cpp.

Member Function Documentation

void Vec_rhs_fun::update_cache ( ) const
private

Conditional update member cache

cache[0] holds the last time. If the current time does not equals cache[0], then update the cache. The content of cache is

  • cache[0] = tp.time(),
  • $ k( 1 - \frac{r(t)}{r_{end}})$,
  • $2 ( \alpha k( 1 - \frac{r(t)}{r_{end}}) + \varepsilon)$,
  • $\delta e^{-6t}$,

where $r(t) = \frac{r_{end}r_0}{r_{end} e^{-kt} + r_0 (1 - e^{-kt})}$

Definition at line 117 of file secOrd_op_rhs_impl.cpp.


The documentation for this class was generated from the following files: