An instrument with a single string

This script creates an instrument with a single string and then applies a force to one end of it for a short time interval.

    // string.tao
    //
    // Create a single string and apply a very short impulse to one
    // end. 
    
    Audio rate: 44100;
    
    String string(200 Hz, 20 secs);
    
    Init:
        string.lockEnds();
        ...
    
    Score 5 secs:
        At 0 secs for 1 msecs:
            string(0.1).applyForce(linear(1,0));
            ...
        ...    


©1999,2000 Mark Pearson m.pearson@ukonline.co.uk April 30, 2000