Hi. You can use the analogWrite() function to produce a PWM wave on pins 9 and 10 of the Arduino board. The function takes two parameters: the pin number and the duty cycle (out of 255). So:
analogWrite(9, 128); //outputs a 50% duty cycle wave on pin 9.
To use pin 11, see this forum thread: