103 std::vector<double> biases;
105 cell_iter != rCellPopulation.
End();
108 double distance = inner_prod(rCellPopulation.
GetLocationOfCellCentre(*cell_iter) - centroid, mDivisionBiasVector);
109 biases.push_back(distance);
113 double min_distance = *std::min_element(biases.begin(), biases.end());
114 double max_distance = *std::max_element(biases.begin(), biases.end());
115 for (
unsigned i = 0; i < biases.size(); i++)
117 biases[i] = (biases[i] - min_distance) / (max_distance - min_distance);
123 cell_iter != rCellPopulation.
End();
127 cell_iter->GetCellData()->SetItem(
"bias", biases[i]);