Generation of a square, periodic signal.

Namespace: dsp

Prototype

static Vecf sigsquare(int p, int n)

Parameters

pPeriod, in number of samples.
nNumber of points to generate.

Description

Example


  // Période = 10 échantillons,
  // 200 échantillons au total.
  soit x = sigcar(10, 200);

  Figure f;
  f.plot(x);

See also

sigtri(), sigsin(), sigcos(), sigexp()