It's actually fairly easy to do. Check out Amy's instructions for knitting in the front and back of a stitch. It's an increase.
For the technique you want to do, you will be working very similarly, but instead of switching between the front and back loop, you'll simply switch the working yarn from the knit to purl position. The key is that you don't take the stitch off your left needle until you've worked all three stitches (K, P, K)