RealtimeAnalysis.FormPRM.buttonABunderEDF_Click C# (CSharp) Method

buttonABunderEDF_Click() private method

private buttonABunderEDF_Click ( object sender, EventArgs e ) : void
sender object
e System.EventArgs
return void
        private void buttonABunderEDF_Click(object sender, EventArgs e)
        {
            this.Cursor = Cursors.WaitCursor;
            FormChart chart = new FormChart("Solution Space under EDF");
            try
            {
                DataTable dt = GetSelectedTaskSet();
                double period_min = Get_Pmin(dt);
                
                Series s2 = new Series("Solution space by AB under EDF");
                s2.ChartArea = "ChartArea1";
                s2.ChartType = SeriesChartType.Line;
                s2.Legend = "Legend1";
                s2.Color = Color.Tomato;
                
                for (double i = _incrementUnit; i <= period_min; i += _incrementUnit)
                {
                    double maxTheta = i - 1;
                    int max_k = GetK_underEDF(dt, i, maxTheta);
                    double AB = GetAB_EDF(dt, max_k);
                    if (double.IsInfinity(AB))
                        continue;
                    s2.Points.Add(new DataPoint(i, AB + 2 * _overhead / i));
                }

                chart.AxisX.Title = "Resource period (Π)";
                chart.AxisY.Title = "Resource capacity (Θ/Π)";// "Resource allocation (Θ)";
                chart.AxisX.Minimum = _incrementUnit;
                chart.AxisY.Maximum = 1;

                chart.EnableLegend = false;

                chart.AddSeries(s2);
            }
            finally
            {
                this.Cursor = Cursors.Default;
            }
            chart.Show();
        }
        private void buttonABunderRM_Click(object sender, EventArgs e)