SignalMath.GenerateImpulse Method

Definition

Namespace: Numerics.NET
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 10.1.0

Overload List

GenerateImpulse(Double, Int32, Span<Double>) Generates an impulse (Kronecker delta) signal.
GenerateImpulse(Int32, Double, Int32) Generates an impulse signal and returns it as a vector.
GenerateImpulse(Double, Int32, Double, Span<Double>) Generates an impulse signal with DC offset.
GenerateImpulse(Int32, Double, Int32, Double) Generates an impulse signal with DC offset and returns it as a vector.

GenerateImpulse(Double, Int32, Span<Double>)

Generates an impulse (Kronecker delta) signal.
C#
public static void GenerateImpulse(
	double amplitude,
	int index,
	Span<double> destination
)

Parameters

amplitude  Double
The amplitude of the signal.
index  Int32
The index at which the impulse/step occurs.
destination  Span<Double>
The destination span to write the generated signal.

Remarks

y[n] = A at index, 0 elsewhere.

GenerateImpulse(Int32, Double, Int32)

Generates an impulse signal and returns it as a vector.
C#
public static Vector<double> GenerateImpulse(
	int count,
	double amplitude,
	int index
)

Parameters

count  Int32
The number of samples to generate.
amplitude  Double
The amplitude of the signal.
index  Int32
The index at which the impulse/step occurs.

Return Value

Vector<Double>
A vector containing the generated signal.

GenerateImpulse(Double, Int32, Double, Span<Double>)

Generates an impulse signal with DC offset.
C#
public static void GenerateImpulse(
	double amplitude,
	int index,
	double offset,
	Span<double> destination
)

Parameters

amplitude  Double
The amplitude of the signal.
index  Int32
The index at which the impulse/step occurs.
offset  Double
The DC offset to add to the signal.
destination  Span<Double>
The destination span to write the generated signal.

GenerateImpulse(Int32, Double, Int32, Double)

Generates an impulse signal with DC offset and returns it as a vector.
C#
public static Vector<double> GenerateImpulse(
	int count,
	double amplitude,
	int index,
	double offset
)

Parameters

count  Int32
The number of samples to generate.
amplitude  Double
The amplitude of the signal.
index  Int32
The index at which the impulse/step occurs.
offset  Double
The DC offset to add to the signal.

Return Value

Vector<Double>
A vector containing the generated signal.

See Also