init
This commit is contained in:
17
DataPRO/FftSharp/Windows/Cosine.cs
Normal file
17
DataPRO/FftSharp/Windows/Cosine.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
|
||||
namespace FftSharp.Windows
|
||||
{
|
||||
public class Cosine : Window, IWindow
|
||||
{
|
||||
public override string Name => "Cosine";
|
||||
public override string Description =>
|
||||
"This window is simply a cosine function. It reaches zero on both sides and is similar to " +
|
||||
"Blackman, Hamming, Hanning, and flat top windows, but probably should not be used in practice.";
|
||||
|
||||
protected override double windowValue(int index, int size)
|
||||
{
|
||||
return Math.Sin(index * Math.PI / (size - 1));
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user