Glad to hear you spoke to your Physician. Ive had more erections "pop up" in my decades of giving Physicals than i could ever count. However, your Dr is correct that it is perfectly normal, and quite preferrable to the opposite problem.
One hint that may help you in those embarassing public locations _ try holding your breath. Remember that erections are caused by blood flow into the penis. By holding your breath, your body instinctfully conserves blood flow to protect the brain. The blood in your erection will begin to dissipate. When you need a breath, take it, and hold it again.
One other peculiar fact. I recently read a study that showed erections could be mollified by a number of aromas. One was lavender. Believe or not, another was the smell of donuts.