3 consecutive afternoons

Started by Omar Ben Ali, September 29, 2015, 08:02:07 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Omar Ben Ali

Quote from: Liviu Lalescu on October 01, 2015, 08:19:59 PM
Maybe you could use constraint activities occupy max time slots from selection. For instance, to avoid 8 hours on Monday morning and Tuesday morning, select these slots, select all activities of the teacher T, and max occupied = 4.

Yes of course,  we can use the constraint activities max time slots from selection. to avoid 8 hours on Monday  morning (or afternoon.) and Tuesday morning (or afternoon). But we must do it also for Friday morninig (or afternoon) and Saurday morrning (or afternoon.)

Liviu Lalescu

Quote from: Omar Ben Ali on October 07, 2015, 12:16:30 PM
Quote from: Liviu Lalescu on October 01, 2015, 08:19:59 PM
Maybe you could use constraint activities occupy max time slots from selection. For instance, to avoid 8 hours on Monday morning and Tuesday morning, select these slots, select all activities of the teacher T, and max occupied = 4.

Yes of course,  we can use the constraint activities max time slots from selection. to avoid 8 hours on Monday  morning (or afternoon.) and Tuesday morning (or afternoon). But we must do it also for Friday morninig (or afternoon) and Saurday morrning (or afternoon.)

Easy, add another two constraints, for Friday and Saturday (morning - one constraint, evening - the second constraint).

Please tell me if this solution also solves Reply #14, or you still need those constraints. And please send me an input file to test Reply #14.

Omar Ben Ali

Quote from: Liviu Lalescu on October 02, 2015, 09:18:50 AM
@ Omar Ben Ali: your requests are possible. But aren't you over-constraining the timetable? These are very particular cases of constraints and if I implement them you might see that a timetable is not possible. Also a name for such constraints is difficult to find.
If you reply, please give me a .fet data file to see.

Yes, Unfortunately this is very restrictive and these are very particular cases of possible timetables . But we have the same problem if we use only the constraint "A teacher's not available times", sometimes it is impossible for fet to generate timetables by dividing teachers into 2 groups. So we try to modify the distribution of available slots for some teachers, sometimes we arrive sometimes not.

For the .fet data file , please tel me  if you want to see the distibution of 2 groups of teachers ?

Liviu Lalescu

I am a bit puzzled.

Do you still need Reply #8? What about Reply #14?

I need a .fet file without not available constraints, so that I can apply your new requests (Replies #8 and #14).

Omar Ben Ali

#19
Quote from: Liviu Lalescu on October 07, 2015, 12:38:19 PM
I am a bit puzzled.

Do you still need Reply #8? What about Reply #14?

I need a .fet file without not available constraints, so that I can apply your new requests (Replies #8 and #14).

ok, here . fet file without not available for teachers, but i used not available for students, you can delete them .
I try yours solution in (reply  #14) and tell you if it work.
for my request in Replies #8,  naturally we begin with the important needs. the important is to avoid 3 consecutives morning and afternoon, then if we can get one of timetables 1,2,3,4 this will be better.
thank you

Liviu Lalescu

#20
This file should solve with not available for students (and with the new constraints for teachers max two mornings/afternoons per week)? I want a real file.

Oh, I see, the not available for students are deactivated. That is equivalent to not having them at all.

Later edit: FET solved you file in about 15 minutes. It is a difficult file. Could you send me the same file with teacher not available which solves and in which the max two consecutive mornings/afternoons for teachers is respected? So that I know it is possible.

Omar Ben Ali

Quote from: Liviu Lalescu on October 07, 2015, 05:57:42 PM
This file should solve with not available for students (and with the new constraints for teachers max two mornings/afternoons per week)? I want a real file.

Oh, I see, the not available for students are deactivated. That is equivalent to not having them at all.

Later edit: FET solved you file in about 15 minutes. It is a difficult file. Could you send me the same file with teacher not available which solves and in which the max two consecutive mornings/afternoons for teachers is respected? So that I know it is possible.

yes it is a difficult file and with the constraint not available for student, it is more difficult.
With the constraint teachers not available, fet finds difficulties so i try an other solution : the constraint activities preferred time slots for subjects. (see college test2), fet solved the file in about  more than  1 hour and half, i do not remember exactly...

Omar Ben Ali

#22
Please find in attachments the file (college test1), it is an easy file where i used the constraint teachers not available and fet solved the file in 29 s with an old computer.
I do not know when you experiment a new constraints, you prefer an easy or difficult file.
Thank you for your help.

Liviu Lalescu

I prefer the easy/fast one.

To test the max two consecutive mornings/afternoons for teachers, should I remove all the teacher not available constraints?

Omar Ben Ali

#24
Quote from: Liviu Lalescu on October 08, 2015, 04:38:44 PM
I prefer the easy/fast one.

To test the max two consecutive mornings/afternoons for teachers, should I remove all the teacher not available constraints?

I think no , especially for the sport teachers (EPS1, EPS2), in afternoon they work only 2 hours from 15 to 17h and they do not work Friday and maybe Wednesday afternoon to do free activities.

Liviu Lalescu

I need a file to test the new constraints teacher(s) max two consecutive mornings/afternoons and Monday/Tuesday not same morning and so on. So I need a file without teacher not available which were added only to respect these constraints.

Omar Ben Ali

Quote from: Liviu Lalescu on October 08, 2015, 05:50:03 PM
I need a file to test the new constraints teacher(s) max two consecutive mornings/afternoons and Monday/Tuesday not same morning and so on. So I need a file without teacher not available which were added only to respect these constraints.
If with the new constraints, fet produce timetables where teachers EPS1 and EPS2 (College test1.fet) do  not work in both Wednesday afternoon and friday afternoon (only one afternoon),  then it's ok, you can remove the constraints teachers not available for those teachers.

Omar Ben Ali

Quote from: Liviu Lalescu on October 08, 2015, 05:50:03 PM
I need a file to test the new constraints teacher(s) max two consecutive mornings/afternoons and Monday/Tuesday not same morning and so on. So I need a file without teacher not available which were added only to respect these constraints.

One question please
Is that the new constraints teacher(s) max two consecutive mornings/afternoons does not work with the constraints teachers not available ?
thanks

Liviu Lalescu

Quote from: Omar Ben Ali on October 08, 2015, 06:08:14 PM
One question please
Is that the new constraints teacher(s) max two consecutive mornings/afternoons does not work with the constraints teachers not available ?
thanks

They can work together, if they do not contradict.

It is not yet implemented. I'll try in the next days.

Liviu Lalescu

Hello, Omar,

I did an implementation of max two consecutive mornings/afternoons for teachers, hardcoded in FET (it does not appear in the interface, it is used only internally for all the teachers). The link: http://lalescu.ro/liviu/fet/download/custom/omar/

Unfortunately, for your input "Colege test 2.fet" (I think this was the file), I waited for 7 hours and still no solution. It seems that it is easier with teacher not available than with this constraint.