Must

Must has 2 main uses in English:

1. Talking about obligation

When we use must to talk about obligation, it usually means that we have decided that the thing is necessary ourselves:

I must visit my parents this week I have not seen them in a long time (you decide it is necessary)

I must go running tomorrow I need to train for the marathon (you decide it is necessary)

When somebody else tells us that something is necessary, for example somebody in authority e.g. teacher / policeman / boss, then we prefer to use have to

You have to finish your homework before you meet your friends

However, on signs and written instructions we prefer to use must:

All visitors must report to reception before entering 

Everything above talks about the present and future times, for all other times we we cannot use must, we must use a form of the verb have to:

Past:  We didn’t know which direction we were supposed to be going so we had to check on the map

Present Perfect: I’ve just had to show my passport at the border

Here there is no way to tell whether you decide something is necessary or an authority decides that something is necessary.

Mustn’t

Mustn’t means that something is not allowed:

You mustn’t tell anyone my secret / You mustn’t drive a car if you have been drinking alcohol

This is completely different to don’t have to  which means that something is not necessary:

You don’t have to book in advance to stay in this hostel, we have many free rooms

2. Saying that we are almost certain that something is true

We also use must to talk about things which we are certain are true:

It must be raining outside I can see people with umbrellas / It must be difficult to be the prime minister

If we are certain that something was true in the past we use must have

I don’t have my umbrella with me, I must have left it at home