Simple: you have two choices.
Before you order a thing, and without discussing it with anyone at the table, you say to the waitress: I would like a separate check, please. Then you will get your bill and pay it on your own and leave your own tip, if you so desire.
When there is just one bill, you hand your credit card to the waitress and state, please charge my card $31.90. The waitress will bring you your receipt where you can add a tip to the merchant copy of the receipt, if you desire. If the $31.50 included the tip, then write "included" in the tip section of the merchant copy of your receipt.