Understand? is short for Do you understand?
Understood? is short for Is that understood?
These are not imperatives. When spoken, the pitch will be raised at the end of the word as is normal with questions in English. This is how a listener can tell it is not a command.
It's unusual for plain "understand" to be expressed imperatively, especially by itself.
In conversation, words can be omitted at the beginning or ends of sentences, if the speaker believes the listener is following closely and paying attention. The mind usually works faster than the mouth so when two people are "in sync" they will tend to elide phrases as they can "fill in the blanks."
Whether or not you can do this is not really governed by formality but rather the chance that the listener may not be paying attention or need for clarity. In some formal situations such as some business dealings, court, legal matters etc. you certainly want to be 100% clear and not omit any words.