|
@@ -356,4 +356,28 @@ impl PulseWidth {
|
|
|
PulseWidth::Ns500 => 500_000,
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
+ /// Ratio of total output power per pulse from the area under the curve of the pulse
|
|
|
+ /// waveform over time. Pulses below 20ns are assumed to be linear discrete pulses
|
|
|
+ /// with no decay over time, while longer pulse widths will follow natural log profile
|
|
|
+ pub fn power_ratio(&self) -> f64 {
|
|
|
+ match self {
|
|
|
+ PulseWidth::Ns2 => 1.0,
|
|
|
+ PulseWidth::Ns4 => 3.17,
|
|
|
+ PulseWidth::Ns6 => 5.34,
|
|
|
+ PulseWidth::Ns8 => 7.51,
|
|
|
+ PulseWidth::Ns12 => 11.85,
|
|
|
+ PulseWidth::Ns20 => 17.29,
|
|
|
+ PulseWidth::Ns30 => 22.04,
|
|
|
+ PulseWidth::Ns45 => 26.78,
|
|
|
+ PulseWidth::Ns60 => 30.17,
|
|
|
+ PulseWidth::Ns80 => 33.54,
|
|
|
+ PulseWidth::Ns100 => 36.16,
|
|
|
+ PulseWidth::Ns150 => 40.91,
|
|
|
+ PulseWidth::Ns200 => 44.28,
|
|
|
+ PulseWidth::Ns250 => 46.90,
|
|
|
+ PulseWidth::Ns350 => 50.84,
|
|
|
+ PulseWidth::Ns500 => 55.03,
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|