ZeroSignal.Core 1.0.0

dotnet add package ZeroSignal.Core --version 1.0.0
                    
NuGet\Install-Package ZeroSignal.Core -Version 1.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="ZeroSignal.Core" Version="1.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="ZeroSignal.Core" Version="1.0.0" />
                    
Directory.Packages.props
<PackageReference Include="ZeroSignal.Core" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add ZeroSignal.Core --version 1.0.0
                    
#r "nuget: ZeroSignal.Core, 1.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package ZeroSignal.Core@1.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=ZeroSignal.Core&version=1.0.0
                    
Install as a Cake Addin
#tool nuget:?package=ZeroSignal.Core&version=1.0.0
                    
Install as a Cake Tool

ZeroSignal

License: MIT .NET Multi-Targeting DSP & Spectral Zero External Dependencies NuGet Version

ZeroSignal is an advanced Digital Signal Processing (DSP), spectral analysis, and state estimation library for .NET with zero external dependencies. Written in pure C#, it delivers industrial-grade Fast Fourier Transforms (FFT), Short-Time Fourier Transforms (STFT), spectrogram generation, zero-phase IIR/FIR digital filtering (FiltFilt), Kalman filtering (EKF), and wavelet transforms for predictive maintenance and edge telemetry.


๐ŸŒŸ Key Capabilities

  • Spectral Analysis (ZeroSignal.Core.Spectral):
    • Radix-2 Cooley-Tukey in-place FFT / IFFT with bit-reversal permutations.
    • STFT (Short-Time Fourier Transform): Windowed time-frequency analysis with configurable hop sizes.
    • 2D Spectrogram Calculation: Power spectral density (PSD) with Hann, Hamming, Blackman, and Bartlett window functions.
  • Zero-Phase Digital Filtering (ZeroSignal.Core.Filtering):
    • Butterworth IIR Filters: Lowpass, Highpass, Bandpass, Bandstop designs.
    • Zero-Phase FiltFilt: Forward-backward digital filtering eliminating phase delay distortion.
    • Savitzky-Golay & Median Smoothing: Polynomial moving filter preserving peak heights and edges.
  • Sensor Fusion & State Estimation (ZeroSignal.Core.Estimation):
    • Linear Kalman Filter for Gaussian noise suppression.
    • Extended Kalman Filter (EKF): Non-linear dynamic system tracking with numerical central-difference Jacobians and Gauss-Jordan matrix inversion.
  • Wavelets & Curve Fitting (ZeroSignal.Core.Wavelets & Optimization):
    • Continuous (CWT) & Discrete (DWT) Wavelet Transforms (Morlet, Ricker, Haar).
    • Levenberg-Marquardt non-linear least squares optimization.
  • Zero External Dependencies: Standard .NET runtime only.

๐Ÿ“ฆ Installation

Install via the .NET CLI:

dotnet add package ZeroSignal.Core

๐Ÿš€ Quick Start

1. In-Place FFT & Power Spectrum

using ZeroSignal.Core.Spectral;

// Sample 1024-point signal with 50Hz and 120Hz tones
int n = 1024;
var real = new double[n];
var imag = new double[n];

for (int i = 0; i < n; i++)
{
    double t = i / 1000.0; // 1kHz sample rate
    real[i] = Math.Sin(2 * Math.PI * 50 * t) + 0.5 * Math.Sin(2 * Math.PI * 120 * t);
}

// Compute FFT
FastFourierTransform.Fft(real, imag);

// Extract magnitude spectrum
var magnitudes = FastFourierTransform.Magnitude(real, imag);
Console.WriteLine($"Peak frequency bin identified: {magnitudes.Length} bins computed.");

2. Zero-Phase Butterworth Lowpass Filtering (FiltFilt)

using ZeroSignal.Core.Filtering;

var noisySignal = new double[] { /* Raw sensor samples */ };

// 4th-order Butterworth lowpass at 20Hz cutoff (sampling rate: 200Hz)
var filter = ButterworthFilter.CreateLowpass(order: 4, sampleRate: 200.0, cutoffFreq: 20.0);

// Filter forward and backward with zero phase distortion
var cleanSignal = filter.FiltFilt(noisySignal);

3. Non-Linear Extended Kalman Filter (EKF)

using ZeroSignal.Core.Estimation;

var ekf = new ExtendedKalmanFilter(
    stateDim: 2,
    measDim: 1,
    stateTransition: (x, dt) => new double[] { x[0] + x[1] * dt, x[1] },
    measurementModel: x => new double[] { Math.Sin(x[0]) }
);

ekf.Predict(dt: 0.01);
ekf.Update(new double[] { 0.52 });

๐Ÿ“Š Benchmark & Performance

Tested on Intel Core i7-13700K (Release x64):

Benchmark Task Points / Sample Execution Time Allocations
Cooley-Tukey 1024-FFT $1024$ points $0.024 \text{ ms}$ In-place ($0$ bytes)
Cooley-Tukey 65536-FFT $65536$ points $1.85 \text{ ms}$ In-place ($0$ bytes)
STFT Spectrogram $100\text{k points}$ $14.2 \text{ ms}$ Continuous 2D grid
Butterworth FiltFilt $50\text{k points}$ $2.10 \text{ ms}$ Single buffer pass

๐Ÿ“„ License

MIT License ยฉ 2026 Phong Vรต. Part of the ZeroPlatform project.

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net461 was computed.  net462 is compatible.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.0 70 9/9/2026