view m-toolbox/test/test_ao_compute.m @ 0:f0afece42f48

Import.
author Daniele Nicolodi <nicolodi@science.unitn.it>
date Wed, 23 Nov 2011 19:22:13 +0100
parents
children
line wrap: on
line source

% function test_ao_compute

clear all;

%% Test 1

pl = plist('tsfcn', 'randn(size(t))', 'nsecs', 100, 'fs', 10);

x = ao(pl);
x.setName();
y = ao(pl);
y.setName();
z = ao(pl);
z.setName();

b = compute(x,y,z, 'a(1) + sqrt(a(2)./a(3))')

%% Test 2

b = compute([x y], z, plist('Operations', '(sqrt(a(1)) + log10(a(2)))./a(3)'))

plot(b.hist)

%% Test 3

b = compute([x y], z, plist('Operations', {'2.*a(3)./a(1)', 'a(2)-a(1)'}))

size(b)

%% Test 4

b = compute(x,y,z)