min activities in a building

Started by Benahmed Abdelkrim, February 28, 2026, 11:14:18 AM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

Benahmed Abdelkrim

Hello Dear Liviu!
I've been working on an exam timetable using FET-NSRT. The requirement is to ensure that each building has at least one activity during each time slot. The current space constraints do not allow it; therefore, if you wish, I suggest adding this space constraint::
min activities in a building.
B.A/krim

Liviu Lalescu

Hello, dear Benahmed!  :)

I will think of this. Could you please send me your fet file?

Benahmed Abdelkrim

B.A/krim

Liviu Lalescu

I made something: https://lalescu.ro/liviu/fet/download/custom/nsrt/

But I don't like it. It is always forcing an activity in each nonbreak slot for each building (the constraint is hardcoded). It is not nice, it is not efficient.

I would highly recommend you to give up this NSRT and we should think of other procedures to schedule the exams with the new FET and new methods/tricks. I am ready to try this, if you want.

The current custom version works, anyway, so you can use it. I tried it practically on your unlocked file.

Liviu Lalescu

#4
Forgot:

1) In your file, the home rooms constraints are all ignored, because preferred rooms override home rooms on each activity.

2) My solution assumes that each activity can be in any room.

3) My solution assumes that each activity has duration 1.

Benahmed Abdelkrim

Thank you very much, the new version works perfectly.
I made some improvements to the file. I removed the home constraints and replaced them with preferred rooms constraint activity tags.
The file is attached bellow.
B.A/krim

Liviu Lalescu


Liviu Lalescu

I have thought about it. If this NSRT is really useful, I could update to FET-7.7.7 and add proper constraints instead of constraints through comments. Just let me know if you need this.

For the moment, I am not feeling too well, but I hope I can help you maybe later with the above, if you consider we need to do it.

Benahmed Abdelkrim

Quote from: Liviu Lalescu on February 28, 2026, 07:50:29 PMI have thought about it. If this NSRT is really useful, I could update to FET-7.7.7 and add proper constraints instead of constraints through comments. Just let me know if you need this.

For the moment, I am not feeling too well, but I hope I can help you maybe later with the above, if you consider we need to do it.


Thank you, dear Liviu, for your help. It would be very beneficial and useful if we did things correctly, better than they are now.
Take your time, Liviu... I wish you health and happiness.
B.A/krim

Liviu Lalescu

Thank you for your kind words, Benahmed! I will think of the possibility of improving this custom version, NSRT, to FET-7.7.7, and adding constraints instead of comments. I will write here, asking you for ideas, when and if I will be able to do this.

Benahmed Abdelkrim

B.A/krim

Liviu Lalescu

Dear Benahmed,

I did some things:

1) Updated to FET-7.7.7-NSRT.

2) Added a new constraint building(s) min one activity in each non-break time slot percentages.

The other constraints remained in the comments section, and for the new constraint (2) the data set must have all activities with duration 1 and only real (not virtual) rooms.

This is all I did for the moment. Please let me know what you think!

Benahmed Abdelkrim

Thank you, dear Liviu, for this update. I'll give my opinion in a moment...
B.A/krim

Liviu Lalescu

You are welcome! No big hurry, I'll wait.

Benahmed Abdelkrim

#14
Thank you very much for adding this new constraint; it works perfectly. I will translate it soon...

By the way this new NSRT version reflects a new way of inputting data, which consists of entering rooms and teachers as they are, without swapping them as we did in the earlier versions of NSRT.

This way allows us to disregard three constraints: MHPD, MHPW, and MSPD, since all these constraints are already implemented in FET. We only have one remaining constraint for FET-NSRT to become a complete and ideal version; as a reminder: MTR (max teachers repetitions).

Also, this version, which reflects a new method of data entry, does not require virtual rooms and only uses activities lasting one hour, as you can see in the last example downloaded above.
In summary, this latest version only requires implementing the MTR constraint. The others can be left as they are in the comments while users familiarize themselves with this simple and easy method...

Alsov if you have some time, allow me to suggest adding the buildings to the FET interface...
B.A/krim