/* * SamplingGrid_inline.hpp * * Created on: Jan 27, 2013 * Author: heber */ #ifndef SAMPLINGGRID_INLINE_HPP_ #define SAMPLINGGRID_INLINE_HPP_ // include config.h #ifdef HAVE_CONFIG_H #include #endif #include "SamplingGrid.hpp" #ifdef HAVE_INLINE inline #endif const double SamplingGrid::getWindowVolume() const { double volume = 1.; for (size_t i=0;i<3;++i) volume *= end_window[i]-begin_window[i]; return volume; } #ifdef HAVE_INLINE inline #endif const double SamplingGrid::getWindowLengthPerAxis(const size_t axis) const { return (end_window[axis] - begin_window[axis]); } #ifdef HAVE_INLINE inline #endif const size_t SamplingGrid::getWindowGridPoints() const { return getWindowGridPointsPerAxis(0) *getWindowGridPointsPerAxis(1) *getWindowGridPointsPerAxis(2); } #ifdef HAVE_INLINE inline #endif void SamplingGrid::setDomainSize( const double _begin[3], const double _end[3]) { for (size_t index=0;index<3;++index) { begin[index] = _begin[index]; end[index] = _end[index]; } } #endif /* SAMPLINGGRID_INLINE_HPP_ */