I hated when this happens. I used to randomly get boners all the time. I would be playing call of duty, and get a boner, be eating food, and get a boner, watching.g tv, and get a boner.
usually i'm out looking for one when that happens, so na, i'm usually happy with getting a random one.
(Yes, i know that was probably NOT how you meant the question)
That's when you just lean way back in your chair and casually stretch your arms out. Then give a sly wink to the prettiest girl in the class who is surely gawking at you by now.