Mercurial > hg > ltpda
view testing/utp_1.1/utp_fcns/get_test_objects_matrix.m @ 51:9d5c88356247 database-connection-manager
Make unit tests database connection parameters configurable
author | Daniele Nicolodi <nicolodi@science.unitn.it> |
---|---|
date | Wed, 07 Dec 2011 17:24:37 +0100 |
parents | 409a22968d5e |
children |
line wrap: on
line source
% GET_TEST_OBJECTS_MATRIX returns a set of MATRIX objects suitable for many of the UTPs % % CALL: [ma1,ma2,ma3,mav,mam] = get_test_objects_matrix % % OUTPUTS: % ma1 - matrix object with 2x3 AOs % ma2 - matrix object with 3x2 AOs % ma3 - matrix object with Filters (iir) % ma4 - matrix object with Pole/Zero models % mav - [ma1, ma2, ma3]; % mam - [ma1, ma2, ma3; ma1 ma2 ma3]; % % % M Hewitson 06-08-08 % % $Id: get_test_objects_matrix.m,v 1.1 2009/08/04 18:38:11 ingo Exp $ % function [ma1,ma2,ma3,ma4,mav,mam] = get_test_objects_matrix %% empty matrix object a1 = ao(1:10, randn(10,1), plist('type', 'tsdata')); a2 = ao(1:10, randn(10,1), plist('type', 'tsdata')); a3 = ao(1:10, randn(10,1), plist('type', 'tsdata')); a4 = ao(1:10, randn(10,1), plist('type', 'tsdata')); a5 = ao(1:10, randn(10,1), plist('type', 'tsdata')); a6 = ao(1:10, randn(10,1), plist('type', 'tsdata')); ma1 = matrix([a1, a2, a3; a4 a5 a6]); ma1.setName(); %% matrix object only with poles ma2 = matrix(a1, a2, a3, a4, a5, a6, plist('shape', [3 2])); ma2.setName(); %% matrix object with I-/O- units iir1 = miir(plist('type', 'lowpass', 'order', 3)); iir2 = miir(plist('type', 'lowpass', 'order', 3)); iir3 = miir(plist('type', 'lowpass', 'order', 3)); ma3 = matrix(iir1, [iir2 iir3], [iir1 iir2 iir3], plist('shape', [2 3])); ma3.setName(); %% matrix object with I-/O- units pzm1 = pzmodel(1, 1, 1); pzm2 = pzmodel(1, {1 3}, 1); pzm3 = pzmodel(1, [1 3], 1); pzm4 = pzmodel(1, 1, {1 4}); ma4 = matrix([pzm1, pzm2; pzm3, pzm4]); ma4.setName(); %% matrix vector mav = [ma1, ma2, ma3]; %% matrix matrix mam = [ma1, ma2, ma3; ma4 ma1 ma2]; end