-- Function File: tf (NUM, DEN, TSAM, INNAME, OUTNAME)
build system data structure from transfer function format data
*Inputs*
NUM
DEN
coefficients of numerator/denominator polynomials
TSAM
sampling interval. default: 0 (continuous time)
INNAME
OUTNAME
input/output signal names; may be a string or cell array with
a single string entry.
*Outputs* SYS = system data structure
*Example*
octave:1> sys=tf([2 1],[1 2 1],0.1);
octave:2> sysout(sys)
Input(s)
1: u_1
Output(s):
1: y_1 (discrete)
Sampling interval: 0.1
transfer function form:
2*z^1 + 1
-----------------
1*z^2 + 2*z^1 + 1
/usr/share/octave/3.0.0/m/control/system/tf.m
но незнаю это то что вам нужно?
Вот реализация матлабовксой tf() под scilab:
// the function takes in the numerator and denominator matrices in the decreasing order of s and gives
the linear system in the transfer function format as the output
// same as tf on MATLAB
// written by Srikanth S V , NITC,email : srikanthssv@gmail.com
function [sys]=tf(num,den)
s = poly(0, "s");
for i = 1:length(num)
revnum(length(num)-i+1)=num(i);
end
for i = 1:length(den)
revden(length(den)-i+1)=den(i);
end
numtf=poly([revnum],'s','c')
dentf=poly([revden],'s','c')
numtf;
dentf;
sys=syslin('c',numtf,dentf)
endfunction
> белка выше написала определение октавовского tf'а.
Я не понял, как туда передать массив данных.
В том весь и прикол, что коэффициенты передаточной функции нужно найти.