public HillEvo(int tp, AlgSelection sel, CruceYMutacion crux, MahFunc func) { m_sel = sel; m_crux = crux; m_func = func; m_tp = tp; m_pop = new Poblacion(tp); }
public void init(int tam, int size, MahFunc func) { m_ind = new List<Individuo>(tam); for(int i = 0; i < m_ind.Capacity; i++) { m_ind.Add (new Individuo(size, func)); } }
public void setFits(MahFunc func) { for (int i = 0; i < m_ind.Count; i++) { m_ind [i].setFit (func); } }
public void setFit(MahFunc func) { m_fit = func.calcFitness (this); }
public Individuo(int size, MahFunc func) { init (size, func.getBound ()); }
public Individuo(int size, MahFunc func) { init (size, func.getBound ()); m_fit = func.calcFitness (this); }