Most agree that 10% to 20% is appropriate according to quality of service, with 10% being a minimum for less than average service.
An easy way to figure 10% of your ticket is to move the decimal point (that little dot between the numbers that seperates dollars and cents) one digit to the left. For example, if your bill is $37.00, move the decimal point to the left to get $3.70, or 10% of your total. When it is not an even dollar amount, $29.53 for example, do the same process and round up to the next whole dollar - $2.95 or $3.00. To figure 20%, just double the amount you get when you move the decimal point. If 10% equals $3.00, then 20% equals $6.00.
No, I am not an elementary school math teacher.
As others have said, most waiters/waitresses work for about half the minimum wage and rely on the tips to make working a profitable proposition. That SHOULD motivate them to provide service above what most consider average. I see this first hand working at Pizza Hut several nights a week (gotta love Dave Ramsey).
Delivery tips seem to be more questionable as far as appropriate amounts. You could do an interesting "socio-economic" study in regards to tip amounts as compared to residences. Just last night I went to a gated estate that would be worth a minimum of half a million dollars (no joke) and got a $3 tip on a $20 order. I also went to a trailer house that was likely built in the 1970's with steps that tilt away from the porch (feel like you are leaning backwards as you climb up) and got a $6 tip on a $20 order. It's generally not a profitable situation when mom and dad send the teenager or kids to the door with the money.