At the very most basic level, the income tax you owe is equal to your income times your tax bracket, right? So, quarterly estimates are easy - just multiply the total earned moonlighting in that quarter by your tax bracket, and pay it. It doesn't have to be exact, you don't get penalized until your tax paid during the year is some percentage (10%? 20%? check with IRS) below your actual tax owed for the year. And the foregoing is already a highball estimate, because nobody actually pays income tax on their full gross income (standard deduction at the very least, loan interest, dependents, etc.) The only hairy thing is, generally you won't know if you paid enough in estimated tax *this* year until you do this year's taxes, by which time it's too late to pay estimated payments.
If you don't make much moonlighting, or you have a lot of deductions, the tax withheld from your residency paycheck may actually already be 80% or 90% (or whatever) of the tax you'll eventually owe, and then you wouldn't have to pay estimated tax at all (you will owe that 10% or 20% in one lump when you file - but at least you get to earn the interest in the mean time, not the IRS). Again, the hairy thing is you have to try to figure out in advance (i.e. now) what your total situation *will* be at the end of the year.
I had to do this a bunch because my university didn't withhold taxes from my grad student stipend; it gets easier after you file taxes once. Incidentally, if you use TurboTax or TaxCut or one of those programs, you can feed in projections for the coming year and it will calculate estimated taxes and print out little forms for you to send in each quarter.
I don't *think* whether you get a W-2 (showing nothing withheld) or a 1099 (showing nothing withheld) makes a difference at least in terms of estimated payments and eventual tax owed, but I'm not positive. Oh, and, of course: Don't take tax advice from a public forum, go consult your friendly local tax professional.