% Function toperator : performs an operation on x % % Input : x, a 2x1 vector % Output : Tx, a 2x1 vector % % Algorithm : basic operations function Tx = toperator(x) %Function declaration. %The file is nothing else than this function %The function performs this computation below... alpha = [1; 2]; beta = 0.9; P = [0.5, 0.5; 0.2, 0.8]; Tx = alpha + beta * P * x; %Here is what the output will be. %Since in the declaration above, %we said Tx would be the output. end