Beispiel #1
0
 void DrawChartProcedure(SpectrFile Source)
 {
     ClearAllSeriesProcedure();
     for (int counterI = 0; counterI < 1024; counterI++)
     {
         GammaSpectrChart.Series["Спектр"].Points.Add(new SeriesPoint(counterI + 1, Math.Round(Source.GammaSpectr[counterI], 2)));
         GammaSpectrChart.Series["Энергия"].Points.Add(new SeriesPoint(counterI + 1, Math.Round(Source.Energy[counterI], 2)));//Math.Round(Source.Energy[counterI])));
     }
 }
Beispiel #2
0
 void ChooseWithOrWithoutBackground()
 {
     WorkingSpectr = Spectr.Clone() as SpectrFile;
     if (BackgroundSubstraction.Checked == true)
     {
         for (int counterI = 0; counterI < 1024; counterI++)
         {
             WorkingSpectr.GammaSpectr[counterI] = Spectr.GammaSpectr[counterI] - Background.GammaSpectr[counterI] * Spectr.Time / Background.Time;
             WorkingSpectr.BetaSpectr[counterI]  = Spectr.BetaSpectr[counterI] - Background.BetaSpectr[counterI] * Spectr.Time / Background.Time;
         }
     }
     DrawChartProcedure(WorkingSpectr);
 }