SPIKE – Spike filter

Block SymbolLicensing group: ADVANCED
PIC

Function Description
The SPIKE block implements a nonlinear filter for suppressing isolated peaks (pulses) in the input signal u. One cycle of the SPIKE filter performs the following transformation (u ,y) y:

delta := y - u;  
if abs(delta) < gap  
  then  
     begin  
        y := u;  
        gap := gap/q;  
        ifgap < mingap then gap:= mingap;  
     end  
  else  
     begin  
       if delta < 0  
          then y := y + gap  
          else y := y - gap;  
       gap := gap * q;  
     end

where mingap and q are the block parameters.

The signal passes through the filter unaffected for sufficiently large mingap parameter, which defines the minimal size of the tolerance window. By lowering this parameter it is possible to find an appropriate value, which leads to suppression of the undesirable peaks but leaves the input signal intact otherwise. The recommended value is 1 % of the overall input signal range. The q parameter determines the adaptation speed of the tolerance window.

Input

u

Input signal to be filtered

double

Output

y

Filtered output signal

double

Parameters

mingap

Minimum size of the tolerance window  0.01

double

q

Tolerance window adaptation speed   1.0 2.0

double

2019 © REX Controls s.r.o., www.rexygen.com