/* * 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::round_style == std::round_toward_zero) ? 0.5 : 0.; // need offset to get to round_toward_nearest behavior const double length = (double)getGridPointsPerAxis()*getWindowLengthPerAxis(axis)/getTotalLengthPerAxis(axis)+round_offset; return length; } #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[NDIM], const double _end[NDIM]) { for (size_t index=0;index