Boundary.cc 528 Bytes
Newer Older
1
2
3
4
5
6
7
8
9
#include "Boundary.h"
#include "FixVec.h"
#include "Parameters.h"

namespace AMDiS {

  BoundaryType newBound(BoundaryType oldBound, BoundaryType newBound)
  {
    if (newBound <= INTERIOR) {
Thomas Witkowski's avatar
Thomas Witkowski committed
10
11
12
      // Face on NEUMANN-boundary or interior face; weak type.

      return oldBound;
13
    } else {
Thomas Witkowski's avatar
Thomas Witkowski committed
14
15
      // Node is already node on the DIRICHLET boundary.

16
      if (oldBound > newBound)
Thomas Witkowski's avatar
Thomas Witkowski committed
17
	return oldBound;
18
      else
Thomas Witkowski's avatar
Thomas Witkowski committed
19
	return newBound;
20
21
    }

Thomas Witkowski's avatar
Thomas Witkowski committed
22
23
24
    // New face is interior face; node type is always stronger.

    return newBound;
25
26
27
  }

}