Upgraded CosmoToolbox

This commit is contained in:
Guilhem Lavaux 2013-03-07 09:47:13 -06:00
parent 5ad0bed91c
commit aa9fe698b2
4 changed files with 30 additions and 11 deletions

View file

@ -136,7 +136,13 @@ namespace CosmoTool {
void setPeriodic(bool on, CoordType replicate)
{
periodic = on;
this->replicate = replicate;
std::fill(this->replicate, this->replicate+N, replicate);
}
void setPeriodic(bool on, const coords& replicate)
{
periodic = on;
std::copy(replicate, replicate+N, this->replicate);
}
uint32_t getIntersection(const coords& x, CoordType r,
@ -193,7 +199,7 @@ namespace CosmoTool {
Cell *base_cell;
bool periodic;
CoordType replicate;
coords replicate;
Node *buildTree(Cell **cell0,
uint32_t NumCells,