function scaling2D_test(a,b)

% This function scales the plane with a in the x direction 
% and b in the y direction
% 
% Input: 
%      a (scaling factor in x)
%      b (scaling factor in y)

% Vertices of the triangle 
   Verts =  [0.5 1.2 0.3; 
             1 -0.2 0.4];

% NACA 0012 profile
%data=load('naca0012.dat');
%Verts=data';
         
% Scaling Matrix
S = @(a,b) [a 0;
            0 b];
        
% 
figure(1)
clf
patch(Verts(1,:), Verts(2,:),'r');
axis equal
axis([-1.5 1.5 -1.5 1.5]);
grid;
box;

% 
figure(2)
clf
NewVerts=S(a,b)*Verts;
patch(NewVerts(1,:),NewVerts(2,:),'r');
axis equal
axis([-1.5 1.5 -1.5 1.5]);
grid;
box;

