Browse Source

Немного рефакторинга

master
Никита 6 years ago
parent
commit
ee779e56cb
  1. 10
      Signal Generator/Signal/FmSignal.cs
  2. 2
      Signal Generator/Signal/MultiSignal.cs
  3. 10
      Signal Generator/Signal/SinusoidalSignal.cs

10
Signal Generator/Signal/FmSignal.cs

@ -11,15 +11,9 @@ namespace Signal_Generator
{
public Collection<Parameter> paramsCollection { get; set; }
public string typeToString
{
get { return "FM сигнал"; }
}
public string typeToString => "FM сигнал";
public new string paramsToString
{
get { return paramsToString(paramsCollection); }
}
public new string paramsToString => paramsToString(paramsCollection);
public FmSignal(double ampl, double freq, double ampl2)
{

2
Signal Generator/Signal/MultiSignal.cs

@ -43,9 +43,7 @@ namespace Signal_Generator
{
double summaryAmplitude = 0;
foreach (IAnalogSignal item in signals)
{
summaryAmplitude += item.currentAmplitude(t);
}
return summaryAmplitude;
}

10
Signal Generator/Signal/SinusoidalSignal.cs

@ -9,15 +9,9 @@ namespace Signal_Generator
{
class SinusoidalSignal : AnalogSignalMethods, IAnalogSignal
{
public string typeToString
{
get { return "SIN сигнал"; }
}
public string typeToString => "SIN сигнал";
public new string paramsToString
{
get { return paramsToString(paramsCollection); }
}
public new string paramsToString => paramsToString(paramsCollection);
public Collection<Parameter> paramsCollection { get; set; }

Loading…
Cancel
Save