Manifold id step0

This is the first backward compatible version of the manifold id branch. Four methods were added to a class named Manifold<dim,spacedim>, which contains a subset of the  Boundary<dim,spacedim> methods. Boundary<dim,spacedim> is now derived from FlatManifold<dim,spacedim>. This fixes issue #27.

The new methods are:

get_new_point_on_cell
get_new_point_on_hex
get_new_point
project_to_manifold

all functions get_new_point_on_* are now made such that by default they call get_new_point, which in turns query project_to_manifold with the averaged point.

This sounds a little intricate, but it is a way to keep backward compatibility while starting with the new idea about manifolds (seen as collection of points with a metric), where by default the new point is created by averaging the surrounding points, and projecting back the result to the manifold.

Simple implementations can implement the

Manifold::project_to_manifold

function, and everything should work out of the box. More complex implementations should implement

Manifold::get_new_point

New implementations should not need to go behyond this. 

ManifoldChart<dim,spacedim,chartdim> is a special implementation in which push_forward and pull_back mechanisms are used to determine the location of new points. All surrounding points are pulled_back, then averaged, and the result is pushed_forward. This is a standard concept in continuum mechanics, and it is the standard way in which geometry points are computed in isogeometric analysis. 

The old Boundary class is still kept around. It is still used for normals to surfaces. This concept it typical of codimension one manifolds, and it is therefore not embedded in the Manifold class itself, but left to the derived class Boundary<dim,spacedim>.


The limitation on chartdim that you pointed out is not necessary. Think of a parametric curve c(s) where c' is always positive. s=[0,1],  and the curve can be in dim=1,2 or 3. You could use such an object on any type of Triangulation we have, to describe an "edge conforming" manifold. 

Same for a parametric surface. And you could also have a Triangulation<1, 2> where every cell (line) lives on a given surface. In this case dim=1, spacedim=2, chartdim=2. 

On the other hand, you could have a Triangulation<2, 2>, and a curve description, giving you the boundary of the triangulation... i.e., chartdim=1, dim=2, spacedim=2.

Or... you have a 4 dimensional space (a projective space), and a parametric curve describes points in three dimensions... So there really are no restrictions, as long as the mapping is invertible, and you can construct it...