void Population::buildRelation(std::list<Population>::iterator itSelf, std::list<Population>::reverse_iterator itOther){ // std::cout << "Building relation\nof " << (*this) << "to " << (*itOther) << std::endl; Relation newRel(m_specie, itOther->m_specie, itOther->m_n); if( newRel.isEmpty() ){ // std::cout << "Done building empty relation from " << m_specie.m_id << " to " << itOther->m_specie.m_id << std::endl; return; } // std::cout << "Nonempty relation found from " << m_specie.m_id << " to " << itOther->m_specie.m_id << ": " << newRel; m_lambda += newRel.m_psi; m_ksi = m_lambda*((PROPFLOAT) m_n); m_listOfRelations.push_back(newRel); auto itToNewRelation = m_listOfRelations.end(); itToNewRelation--; itOther->addDependentRelation(itSelf, itToNewRelation); // std::cout << "Done building relation\n\n"; }