public void CheckBestCandidate(SpeciesInfo specInfo) { OnBestEquationChanged?.Invoke(new BestEquationEventArgs { BestEquationInfo = specInfo }); }
/// <summary> /// is called before solution is evolved to setup the specie /// </summary> protected virtual void StartFinding() { lock (SpecInfo) { SpecInfo = new SpeciesInfo(); } GInfo.IncrementTotalSpecies(); InitializeUpdateInfo(); NewSpecieEvent(); }
public void InsertInfo(SpeciesInfo SpecInfo) { try { BestFunction = SpecInfo; Dispatcher.Invoke(() => this.DataContext = SpecInfo); } catch (Exception e) { MessageBox.Show(e.Message + Environment.NewLine + e.StackTrace); } }
public SpeciesInfo GetCopy() { SpeciesInfo copy = new SpeciesInfo(); copy.Generation = Generation; copy.FunctionText = FunctionText; copy.Offset = Offset; copy.SequenceText = SequenceText; copy.ResultText = ResultText; copy.Attempts = Attempts; copy.OperatorCount = OperatorCount; return(copy); }