BE + TO-infinitive
Be + to-infinitive is used to express:
official arrangements: The Prime Minister is to visit India next month.
official orders: At the end of the course, all students are to take a written exam.
things that should be done: What am I to do?
a possible aim when saying what should be done to reach it: If you are to work here for more than three months, you must have a residence permit.
prohibition (only in the negative): You are not to do that again.
Be + to-infinitive can also be used in the past:
Mr Jones
was to speak
at the meeting.
(it was arranged and he did)
But was/were + to + perfect infinitive means that the arranged event did not actually happen:
Mr Jones
was to have spoken
at the meeting, but he had to cancel because of his illness.
Quotes:
Nothing in life is to be feared. It is only to be understood. - Marie Curie