procedure Demultiplex(const Src: TVec; const Dst: TVec; ChannelCount: Integer; ChannelNr: Integer);
Demultiplex a channel.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Src | TVec | |
| 2 | Dst | TVec | |
| 3 | ChannelCount | Integer | |
| 4 | ChannelNr | Integer |
Result: stored in self (calling object)
Remarks:
Dempultiplex ChannelNr from Src to Dst, if number of channels is ChannelCount. ChannelNr is zero based.
Examples
uses MtxExpr, Math387, MtxVec, SignalUtils, MtxVecTee, MtxVecEdit;
procedure TForm1.Button1Click(Sender: TObject);
var b,h,c: Vector;
begin
h := Ramp(6,mvDouble,0,1); // h = [0 1 2 3 4 5]
Multiplex(h,b,3,2); // b = [0 0 0 0 0 1 0 0 2 0 0 3 0 0 4 0 0 5]
Demultiplex(b,c,3,2); // c = [0 1 2 3 4 5]
DrawIt(c);
end;
See Also: SignalUtils.Multiplex