LR-splines  0.5
Namespaces | Classes | Typedefs | Enumerations | Functions | Variables
LR Namespace Reference

Namespaces

namespace  utl

Classes

class  Basisfunction
 Basisfunction class to store the individual B-splines which make up the LR B-spline space. More...
class  Element
 Element class to partition the parametric space into subrectangles where all Basisfunctions are infitely differentiable. More...
class  LRSpline
class  LRSplineSurface
class  LRSplineVolume
class  Meshline
class  MeshRectangle
class  Profiler
 Simple class for profiling of computational tasks. More...
class  Streamable

Typedefs

typedef enum parameterEdge parameterEdge

Enumerations

enum  parameterEdge {
  NONE = 0, WEST = 1, EAST = 2, SOUTH = 4,
  NORTH = 8, TOP = 16, BOTTOM = 32, SOUTH_WEST = 5,
  SOUTH_EAST = 7, NORTH_WEST = 9, NORTH_EAST = 10
}
enum  meshlineExtension { ELONGATION, MERGING, NEWLINE, INITIAL }

Functions

std::istream & operator>> (std::istream &is, LR::Streamable &obj)
std::ostream & operator<< (std::ostream &os, const LR::Streamable &obj)
void collectResults (std::vector< double >::iterator &result, double product, std::vector< std::vector< std::vector< double > > > &diff, int derivsLeft, uint dim)
static double WallTime ()
 Returns the current wall time in seconds and resolution in microsec.
std::ostream & operator<< (std::ostream &os, const Profiler::Profile &p)
 Global stream operator printing a Profile instance.

Variables

static bool use_ms = false
 Print mean times in microseconds?

Typedef Documentation

Definition at line 34 of file LRSpline.h.


Enumeration Type Documentation

Enumerator:
ELONGATION 
MERGING 
NEWLINE 
INITIAL 

Definition at line 9 of file Meshline.h.

Enumerator:
NONE 
WEST 
EAST 
SOUTH 
NORTH 
TOP 
BOTTOM 
SOUTH_WEST 
SOUTH_EAST 
NORTH_WEST 
NORTH_EAST 

Definition at line 20 of file LRSpline.h.

                   {
NONE       = 0,
WEST       = 1,    // 000001
EAST       = 2,    // 000010
SOUTH      = 4,    // 000100
NORTH      = 8,    // 001000
TOP        = 16,   // 010000
BOTTOM     = 32,   // 100000
// convienience variables for 2D case follows. In general use SOUTH|WEST, SOUTH|EAST, etc
SOUTH_WEST = 5,    // 000101
SOUTH_EAST = 7,    // 000110
NORTH_WEST = 9,    // 001001
NORTH_EAST = 10};  // 001010

Function Documentation

void LR::collectResults ( std::vector< double >::iterator &  result,
double  product,
std::vector< std::vector< std::vector< double > > > &  diff,
int  derivsLeft,
uint  dim 
)

Definition at line 326 of file Basisfunction.cpp.

Referenced by LR::Basisfunction::evaluate().

                              {
        if(dim == diff.size()-1) {
                *result *= product*diff.back()[derivsLeft][0];
                result++;
                return;
        }
        for(int d=derivsLeft; d>-1; d--) {
                double ans = diff[dim][d][0];
                collectResults(result, ans*product, diff, derivsLeft-d, dim+1);
        }
};
std::ostream& LR::operator<< ( std::ostream &  os,
const LR::Streamable obj 
) [inline]

Definition at line 23 of file Streamable.h.

References LR::Streamable::write().

                                                                       {
        obj.write(os);
        return os;
}
std::ostream& LR::operator<< ( std::ostream &  os,
const Profiler::Profile &  p 
)

Global stream operator printing a Profile instance.

Definition at line 96 of file Profiler.cpp.

References LR::Profiler::Profile::nCalls, LR::Profiler::Profile::totalCPU, LR::Profiler::Profile::totalWall, and use_ms.

{
  // First the CPU time
  os.width(10);
  os << p.totalCPU;
  if (p.nCalls > 1)
  {
    os.width(9);
    os << (use_ms ? 1000.0 : 1.0)*p.totalCPU/p.nCalls <<" |";
  }
  else
    os <<"          |";

  // Then the wall time and the number of invokations (if more than one)
  os.width(10);
  os << p.totalWall;
  if (p.nCalls > 1)
  {
    os.width(9);
    os << (use_ms ? 1000.0 : 1.0)*p.totalWall/p.nCalls <<" |";
    os.width(6);
    os << p.nCalls;
  }
  else
    os <<"          |";

  return os <<'\n';
}
std::istream& LR::operator>> ( std::istream &  is,
LR::Streamable obj 
) [inline]

Definition at line 18 of file Streamable.h.

References LR::Streamable::read().

                                                                 {
        obj.read(is);
        return is;
}
static double LR::WallTime ( ) [static]

Returns the current wall time in seconds and resolution in microsec.

Definition at line 43 of file Profiler.cpp.

Referenced by LR::Profiler::start(), and LR::Profiler::stop().

{
  timeval tmpTime;
  gettimeofday(&tmpTime,NULL);
  return tmpTime.tv_sec + tmpTime.tv_usec/1.0e6;
}

Variable Documentation

bool LR::use_ms = false [static]

Print mean times in microseconds?

Definition at line 91 of file Profiler.cpp.

Referenced by operator<<(), and LR::Profiler::report().