A = 440 ;
B = 440 * 2^(2/12) ; 
C = 440 * 2^(3/12) ;
G = 440 / 2^(2/12) ; 
Fsharp = 440 / 2^(3/12) ;

w1 = note( G , 1, 1);
w2 = note( A , 1, 1);
w3 = note( Fsharp , 1, 1.5);
w4 = note( G , 1, 0.5);
w5 = note( B , 1, 1);
w6 = note( C , 1, 1);
w7 = note( B , 1, 1.5);
w8 = note( A , 1, 0.5);
w9 = note( Fsharp , 1, 1);

audiowrite( 'f2.wav', [w1 w1 w2 w3 w4 w2 w5 w5 w6 w7 w8 w1 w2 w1 w9 w1], 10000);
