Teacher +Room not available - is this working?

Started by samantha.goddard, June 23, 2021, 11:58:54 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.


Hi all,

I have scheduled our G11 and G12 classes using the Block Planning FET mode (A BIG THANK YOU to Liviu for all his help on this!). I'm now building our G6-G10 timetable in standard FET.

I would like to block off the G11 / G12 teachers and their rooms at the time they are teaching using 'Teacher +Room are not available' (as it will be quicker than creating dummy activities) but when I use this constraint, it doesn't show up at all in the room or teachers' timetables so I don't believe it's working for me.

Am I doing something wrong or have I misunderstood the function of this command? Or is it not working?

Many thanks! Samantha

Liviu Lalescu

Hello, Samantha,

It should work: for a pair teacher x room, you can say that no activities of this teacher can be placed in that room at the selected time slots.

Indeed, it does not appear marked with X in the rooms' or in the teachers' timetables, because it depends on both.

I am not sure I understand the problem correctly.

Please see attached an example. The activities are all scheduled at the beginning of the day.


Okay - thanks, Liviu. That's really helpful. I guess I was expecting it to show as X where they weren't available (since it does that for the constraint teacher not available).

That's great - now I know that works, I can definitely use it. Thank you! Samantha

Liviu Lalescu

I'm glad it (will) work(s), Samantha!  :)

But I don't see how I could show an X in not available slots for teacher x room, because for the same teacher there are multiple rooms possible.


Hi Liviu,

Thanks for your reply. I think I have misunderstood what this constraint is for. I assumed that it is used for blocking out both a room and a teacher as unavailable. But now that I'm checking my timetable again, I don't think it has worked like that.

So to block off both a room and a teacher at certain times, I need to either:
A) Block room unavailable.
B) Block teacher unavailable.

Make dummy activities for that teacher and assign a room to those activities.

Is that correct? Many thanks for clarifying, Samantha

Liviu Lalescu

Hello, Samantha,

I am sorry, but I do not understand. The constraint does not allow a pair (T, R) at that time. If you want no teacher and no room at that time, I think you should do (A) and (B).

I do not understand the dummy activities approach.

Maybe you could send me your locked file and show me where this constraint is not working as expected.


Okay, thanks for the clarification, Liviu. It seems like a strange constraint to me as I don't see why you would want to put a constraint that a room is unavailable only to that teacher. Surely, you just wouldn't put the teacher in that room if you don't want them there.

I would have thought that if you want a room to be unavailable, then you just use the room unavailable function (and so it's unavailable for everyone at those times).

But I can see the use in having a joint constraint to say that BOTH a teacher and a room are unavailable at certain times so that the teacher cannot be scheduled for anything else and the room can also not be scheduled for anything else at that time. This would save time.

For example, in my situation, as you know I've already created my schedule for G11 and G12 in FET Block planning mode. So I know that certain teachers and their rooms are unavailable at certain times. It helps a lot to therefore be able to block off both the room and the teacher for all other activities for their joint unavailable times.

Does that make sense?
I'm just wondering if this is a new or modified constraint that could be made? I had assumed that's what the room+teacher unavailable meant!

Thanks for your thoughts! All the best, Samantha

PS - I'll send you my file so you can what I mean.

Liviu Lalescu

Dear Samantha,

This constraint (teacher+room not available times) was suggested by the Moroccan and Algerian users. For a teacher and room pair, the user can specify the not available times. Even myself considered this constraint type a bit weird, but it does not hurt.

For your data, I think it is very easy to just add two constraints, one teacher not available and another one room not available.