84 c_vector<double, 2*DIM> base_bounding_box = GetArchiveBoundingBox(archivePath);
87 for (
unsigned i=0; i<DIM; i++)
89 base_bounding_box[2*i] -= 1e-14;
90 base_bounding_box[2*i + 1] += 1e-14;
94 mesh.SetInitialBoxCollection(base_bounding_box,
mesh.GetMaximumInteractionDistance());
96 unsigned node_index = 0;
98 std::ifstream infile(archivePath.c_str(), std::ios::in);
101 std::getline(infile, line);
103 while (std::getline(infile, line))
106 std::istringstream iss(line);
109 c_vector<double, DIM> location;
110 for (
unsigned k=0; k<DIM; k++)
116 if (
mesh.IsOwned(location))
120 mesh.AddNode(p_node);
123 CELL_CYCLE_MODEL* p_cell_cycle_model =
new CELL_CYCLE_MODEL;
124 p_cell_cycle_model->SetDimension(DIM);
128 CellPtr p_cell(
new Cell(p_state, p_cell_cycle_model));
129 p_cell->SetCellProliferativeType(pCellProliferativeType);
130 cells.push_back(p_cell);
146 c_vector<double, 2*DIM> bounding_box;
147 for (
unsigned i=0; i<DIM; i++)
149 bounding_box[2*i] = DBL_MAX;
150 bounding_box[2*i + 1] = -DBL_MAX;
153 std::ifstream infile(archivePath.c_str());
156 std::getline(infile, line);
158 std::istringstream iss(line);
162 unsigned file_dimension;
164 iss >> num_lines >> file_dimension;
166 if (file_dimension != DIM)
168 EXCEPTION(
"Space dimension of ParallelCellsGenerator and archive file do not match");
171 while (std::getline(infile, line))
173 std::stringstream new_iss(line);
174 for (
unsigned i=0; i<DIM; i++)
178 bounding_box[2*i] = (point < bounding_box[2*i]) ? point : bounding_box[2*i];
179 bounding_box[2*i+1] = (point > bounding_box[2*i+1]) ? point : bounding_box[2*i+1];