public void PlotFunction() { CurrentFunction.CalcFunctionPoints(); if (functionDrawer != null) { if (CurrentFunction is HenonFunction curr) { try { if (curr.MaxIterations > 1000000 && functionDrawer.MainImage.Height == Constants.UsedBSize) { BSize = 2 * Constants.UsedBSize; } else { if (curr.MaxIterations <= 1000000 && functionDrawer.MainImage.Height == 2 * Constants.UsedBSize) { BSize = Constants.UsedBSize; } } } catch { } } else { try { if (functionDrawer.MainImage.Height > Constants.UsedBSize) { BSize = Constants.UsedBSize; } } catch { } } functionDrawer.DrawPicture(); } }
public void SetFInclude(int f, bool v) { FIncludes[f] = v; CurrentFunction.FunctionGenerations[f] = v; if (v) { CurrentFunction.CalcFunctionPoints(); PlotFunction(); } }
private void ParamChoice2Form(decimal Par) { decimal currentPar = CurrentFunction.Parameter; CurrentFunction.Parameter = Par; CurrentFunction.CalcFunctionPoints(); diagramFunctionPlotter.Function = CurrentFunction; diagramFunctionPlotter.Form2Plot = null;//just to be sure diagramFunctionPlotter.DrawPicture(); PlotForm.SetFunctionImage = diagramFunctionPlotter.MainImage; CurrentFunction.Parameter = currentPar; }