Timetable lasts Monday to Friday and distinguishes between odd and even weeks, therefore timetable cosists of 10 days - 5 in odd and 5 in even week. There's no problem with activities scheduled once in two weeks, but an issue appears with activities scheduled every week. Constrains of
every week activities are:
Split into ... activities per week = 2
The minimum requiered distance In days between each pair of activities = 5
Percentage of addend constraint = 100%
Constraints max days between activities , Max days = 5, Weight percentage = 100%
Constraints activities same starting hor, Weight percentage = 100%
This configuration results with FET planning activities in Room A (even week) and Room B (odd week). Is there any option or configuration to block the same Rooms for the same activities every week?
There is a file attached for better understanding of this case. Below you can find Room change for the same activity.
Even week
Activity: Id=73
Activity group id=73
Active=yes
Duration=1
Total duration=2
Teacher=xxxxx
Subject=Analiza ekonomiczna
Activity tag=W
Students=E1/2
Total number of students=110
Room: Aula-A_WR
Odd week
Activity: Id=74
Activity group id=73
Active=yes
Duration=1
Total duration=2
Teacher= xxxxx
Subject=Analiza ekonomiczna
Activity tag=W
Students=E1/2
Total number of students=110
Room: 412-A_WR
Best regards
You forgot to attach the file.
This is an interesting approach to scheduling fortnightly activities. I didn't think of that.
Unfortunately, I do not see a perfect solution to your problem.
Maybe try this: generate a timetable once. Then, try to fix the activities in the first week to their rooms, chosen by FET, and fix the activities in the second week for respectively the same rooms of the pair activities from the first week. Maybe FET will find a timetable (hopefully, the data will not be too constrained).
For example: A1 (week 1)->R1, A2 (week 2)->R2. A1 and A2 should have the same room (they represent the same weekly activity). Then, fix A1->R1, A2->R1.
Please tell me if my words are clear.
A simpler approach would be to make a weekly timetable. There is an entry in the FAQ (search "fortnightly"). The only problem is if you need to care about real gaps for teachers and students, because there will appear real gaps in even (or odd) weeks. This approach may be more efficient in terms of searching for the solution (generation time).
Please let me know.
Edited to add: may I add your words in the FAQ?
QuoteTimetable lasts Monday to Friday and distinguishes between odd and even weeks, therefore timetable cosists of 10 days - 5 in odd and 5 in even week. There's no problem with activities scheduled once in two weeks, but an issue appears with activities scheduled every week. Constrains of
every week activities are:
Split into ... activities per week = 2
The minimum requiered distance In days between each pair of activities = 5
Percentage of addend constraint = 100%
Constraints max days between activities , Max days = 5, Weight percentage = 100%
Constraints activities same starting hor, Weight percentage = 100%
Thta is not 100% correct. If you have bad luck, your timetable will not solved, even it is possible to solve.
Example:
in the first activity is an activity at friday.
now imagine the table is possible to solve if you will set the activity in the other week on moday, but that is not possible because of your min n day constraint.
i think your solution is only correct if you add between the two weeks a pseudo week. (so you need 15 days week!) All days of that pseudo week get a break constraint.
i know, the printed table doesn't look fine, but it will solve the problem i descriped a few lines before.
Volker, I think his method is correct. He has two weeks, but weekly activities (split into 2) should have the exact same real day and same hour.
Dear nomad,
I have thought of your problem some more.
I think you need a constraint of type activities same room, but: this was also suggested previously by some other users, and I thought this was too difficult for me to implement.
If it is imperative for your case, I will try to think about it. But I think it is very difficult and also in the past I thought it was very difficult.
Please answer me: do you imperatively need it for the generation of the timetable, or it is only cosmetic, for the HTML timetables?
I mean, you could, for the second week timetable, after the generation of the timetable, manually change the rooms to the rooms of the first week. Or is this wrong?
Also, I saw that you are not using building changes (second building has only one room, unused). Even if you did, I suppose that a certain activity (and its pair) has only preferred rooms from a certain building, and you'll have no problems with that.
So, I want you to confirm me my reasoning and let me know if you can do your timetabling job without activities same room constraint type.
QuoteVolker, I think his method is correct. He has two weeks, but weekly activities (split into 2) should have the exact same real day and same hour.
In that case he should check to use a workaround.
compare:
http://www.timetabling.de/manual/FET-manual.en.html#id_36
If he has not to many activities only every second week the workaround will be much faster to use, generate and easier to read.
If he has many activities only every second week, then the workaround is of course not very good, but in that case (in my opinion) it is also not needed to have exact the same time for weekly activities.
Difficult to say, it depend on the number of activities that are weekly or not. He must decide hisself.
I am not sure, if the number of biweekly activities is not to low (because workaround is better) and also not to high (because not care about same time is better), his variant is better.
Hi,
from my point of view, solution to this issue is quite simple - it's enough to add another constraint to the algorithm - a set of activities have the same Room. As a result, algorithm should create a set of activities strating the same time, regardless of the day - a set of activities has the same starting hour (any days). Number of days can be set with min and/or max gap between them. It's just a theory, i don't know how complex in is to programm it.
QuoteLiviu Lalescu wrote on 08/23/10 at 02:11:22
Maybe try this: generate a timetable once. Then, try to fix the activities in the first week to their rooms, chosen by FET, and fix the activities in the second week for respectively the same rooms of the pair activities from the first week. Maybe FET will find a timetable (hopefully, the data will not be too constrained).
For example: A1 (week 1)->R1, A2 (week 2)->R2. A1 and A2 should have the same room (they represent the same weekly activity). Then, fix A1->R1, A2->R1.
I think that's one of the best ideas to solve it, but the overwhelming number of 800 activities make it a long shot to implement without any conflicts. Moreover, there are two beginnings of week in generated timetables , which may become a big challenge to organizationally implement, people may not actually go for it. So these 'double days' would need to be somehow joined, like "Monday(even)+Monday(Odd)=Monday". I need to have 3 windows opened ( "Timetable Teachers", "Timetable Students", "Timetable Rooms") to go through it. Anyway, it makes statistics clear - no dummy activities. Next problem it presents, is pairing activities with exchanging teachers and students. Algorithm places activities symmetrically (4 hour activities in one week = 2 activities 2 hours each in another respectively), see my file 07:15-12:00 (Activity Id=5 Even Tuesday)/(Activity Id=32 Odd Tuesday & Activity Id=12 Odd Tuesday).
QuoteLiviu Lalescu wrote on 08/23/10 at 02:11:22
may I add your words in the FAQ?
Yes of course, but i would like specifics to be more individual (no names, or activities names, etc.)
QuoteVolker Dirr wrote on 08/23/10 at 02:44:49
Thta is not 100% correct. If you have bad luck, your timetable will not solved, even it is possible to solve.
Why gaps between activities have been set by
The minimum requiered distance In days between each pair of activities = 5 and Constraints max days between activities Max days = 5 constrains. Because if activity set on, ie. Wednesday (even week) it will set next on next
Wendesday in odd week, respectively. Algorithm is being generated in 8 secs.
QuoteVolker Dirr wrote on 08/23/10 at 02:44:49
i think your solution is only correct if you add between the two weeks a pseudo week. (so you need 15 days week!) All days of that pseudo week get a break constraint. i know, the printed table doesn't look fine, but it will solve the problem i descriped a few lines before.
I don't get this at all, actually. Please describe it in some example for better understanding.
QuoteLiviu Lalescu wrote on 08/23/10 at 07:01:06
If it is imperative for your case, I will try to think about it. But I think it is very difficult and also in the past I thought it was very difficult.
It is imperative, beacause having scarce resources, like rooms , having them tagged differently for different purposes, etc. Additionally, there are lecture and laboratory rooms. Each teacher can run couple of different activities. This results in "Space - Teacher has a set of home rooms" and "Space - Activities hah a set of preferred rooms" constrains have little help and can be useful only in individual examples. If, for instance constrain for T1 is set "Space - Teacher has a set of home rooms: 20-A_WR i Aula-A_WR"and for A1 "Space - Activities has a set of preferred rooms: 20-A_WR i Aula-A_WR", program will choose one room or another without any predetermination - there's no constraint to block one room for activity for the next week respectively. 800 activities is a little to much to change it after the program has set it once.
QuoteLiviu Lalescu wrote on 08/23/10 at 07:01:06
do you imperatively need it for the generation of the timetable, or it is only cosmetic, for the HTML timetables?
I need a clear timetable, with fair statistics - no dummies. Cosmetics would it be, if we start over with a normal week - no odd no even with different than default view like in previously attached file. My knowledge with handling XML is null, so i'd have to do it manually.
QuoteLiviu Lalescu wrote on 08/23/10 at 07:01:06
manually change the rooms to the rooms of the first week. Or is this wrong?
Manual changes and repeatedly generating to look for conflicts is aroad to nowhere - see 800 activities.
QuoteLiviu Lalescu wrote on 08/23/10 at 07:01:06
Also, I saw that you are not using building changes (second building has only one room, unused). Even if you did, I suppose that a certain activity (and its pair) has only preferred rooms from a certain building, and you'll have no problems with that.
Second building is a sports building. No help here.
QuoteVolker Dirr wrote on 08/23/10 at 08:08:56
If he has not to many activities only every second week the workaround will be much faster to use, generate and easier to read.
Number of fortnightly activities is a result od teachers requests and lectures specification, it's no my doing.
----
Another solution is to link activities together (subjects) and create new activities before planning in Fet.
Example: students group G1 is having activities S1 that are run by teacher T1 once in two weeks for 4 hours tagged W. Now i need to find manually activity/es for G1 for 4 hours with different teacher T2 next week. If found i need to create new kind of activity 'S1S2' and add it to the program. Then, it needs to get two teachers T1 and T2 with group G1.
Definition:
T1->G1->S1 (4) Week 1
T2->G1->S2 (4) Week 2
Solution:
T1/T2->G1->S1S2 (4)
Rooms have some capacity and additional group need bigger space ;]
If there's no equivalent activity in lenght, so the solution is:
Problem:
T1->G1->S1 (4) Tydzień 1
T2->G1->S2 (2) Tydzień 2
T3->G1->S3 (2) Tydzień 2
Solution:
T1/T2->G1->S1S2 (2)
T1/T3->G1->S1S3 (2)
OK, I'll think of your suggested constraint, a set of activities have same room. But it looks very complicated to add in current algorithm. If I have designed it from the beginning, it might have been easier.
Meanwhile, please let us know if you managed to find other good solution(s), based on the suggested tricks. Let me know if you managed to obtain a good usable timetable and you no longer need the same room constraint type.
I will not add your words into the FET help, because they may contain private information. If you want your method listed, write me a few words about your method above which you used to make a timetable for two weeks, without the sensitive information, and I'll add them into FET help.
I have put some thoughts into doing 10 days cycle. I think a cool way to do that is to use a 5 days cycle, double each of the period, so you have P1-a and P1-b, P2-a and P2-b...etc.
a being odd week, and b being even weeks.
If you want an activities to "mirror" on the next week, just make that a double period. Other, let it float. Add constraints that some activities must go to the a-periods and some on the b-periods.
You need to artificially insert breaks between every 2 periods to avoid consecutive activities to be placed on P1-b and P2-a, for example.
I actually haven't try this yet, just in theory. I hope this make sense.
By the way, I enthusiastically second the "activity using the same room" constraint. It will solve not only room problem, teacher problem as well!
I'll think about constraint activities same room, but it looks too difficult to me for the moment.
Reviving an old topic:
The new constraint is ready: Activities occupy max rooms (in your case, 1 room maximum).
Attached is the solution to your original problem.
The new constraint was easier than I thought.
I'll add soon a snapshot and probably the new version 5.18.0 will contain this new constraint.
nomad, please let me know if I can make your file an official FET example (no copyright/privacy problems, or school's principal approval), and if affirmative, in which directories (country, city, institution)?
Please see also http://lalescu.ro/liviu/fet/forum/index.php?topic=1197.msg6789#msg6789
Quote
Zsolt, I think a nice constraint to help you is the new (since 5.15.0) constraint activities occupy max time slots from selection. Say you have 4 activities, each duration 1, in first week, then 3 in second week. Add constraint, all time slots, max occupied = 4, these 4+3 activities. Later thinking: this in case you need to double your students, teachers and rooms. And constraint activities occupy max different rooms.
Quote from: Liviu Lalescu on April 29, 2012, 04:28:02 PM
Reviving an old topic:
The new constraint is ready: Activities occupy max rooms (in your case, 1 room maximum).
Attached is the solution to your original problem.
The new constraint was easier than I thought.
I'll add soon a snapshot and probably the new version 5.18.0 will contain this new constraint.
nomad, please let me know if I can make your file an official FET example (no copyright/privacy problems, or school's principal approval), and if affirmative, in which directories (country, city, institution)?
Can you explain more about the usage of "Activities occupy max rooms"?
I don't get the meaning in faq:
Q: How can I specify that some activities must be in the same room (at different time slots, of course, because a single room can hold a single activity in a certain time slot)? This is needed for instance to constrain the Physics activities of a certain students set to take place in the same room, be it Lab-1 or Lab-2
I go two activities, say A1, A2, I want them use the same room at two different week, say A1 use odd week, A2 use even week, is that I should use this constraint?
Quote from: gilbert on July 13, 2016, 02:35:15 PM
I go two activities, say A1, A2, I want them use the same room at two different week, say A1 use odd week, A2 use even week, is that I should use this constraint?
I am not sure I understand correctly. Do you make the timetable with the number of days per "week" (FET week) = 10 (2*5)? And you add double the number of activities?
This constraint is in fact "constraint activities occupy max
different rooms" (I improved its name).
I think this is what you should use, with max different rooms = 1.
Thanks for your reply, is that the only way to achieve this by making 10 (2*5) days? and need to double all the activities? (also need to double other time constraint?)
Besides, I want to know the usage of the following:
"A set of activities occupies max time slots from selection" and
"maximum simultaneous activities from a set in selected time slots"
Thanks a lot again!
No. you might do it also with an other trick. Please read "Add a fortnightly activity":
http://www.timetabling.de/manual/FET-manual.en.html#id_36
Quote from: gilbert on July 13, 2016, 03:54:29 PM
Thanks for your reply, is that the only way to achieve this by making 10 (2*5) days? and need to double all the activities? (also need to double other time constraint?)
You have basically two ways, as Volker said. The exact way (in this topic) and using tricks like in Volker's manual. Please let me know if these are clear or we need to talk some more.
Also, quotes from the FAQ:
---
Q: Can I work with fortnightly activities like in older FET versions?
A: You have to use some tricks. It would be difficult to consider fortnightly activities into the new FET algorithm (from 5.0.0 up). But I think you can apply this: for instance, I suppose that you would like the first week to have activity A1 (teacher T1, student S1) and A2 (T2, S2), and second week A3 (T1, S2) and A4 (T2, S1) (simultaneously). You could define a weekly activity A (T1, T2, S1, S2). If you need 2 rooms for A, then you can define dummy A' (no teachers, no students) and constraint activities same starting time A and A' and add rooms for A and A' .
---
-- This entry by Regis Bouguin --
Q: A trick to deal with fortnightly activities (my institution has a lot of fortnightly activities):
A: I divided hours in two, the first half (8.00 to 8.30, 9.00 to 9.30, ...) represents week A, the second half (8.30 to 9.00, 9.30 to 10.00, ...) represents week B, fortnightly activities have duration 1, weekly activities have duration 2.
I created an activity tag 'Start hour'. It should be added to each weekly activity to make sure they start at the same time (same day + same hour) on each week. Otherwise, an activity with duration 2 can start on a second half of hour in the timetable, so this activity is placed on a certain day and at a certain hour on week A, and on the same day but at the next hour on week B.
Add time constraint: activities with all teachers, all students, all subjects, activity tag = 'Start hour' have a set of preferred starting times: Monday 8.00, Monday 9.00, ...
It works fine and I got good timetables with strong teachers time constraints.
---
Quote
Besides, I want to know the usage of the following:
"A set of activities occupies max time slots from selection" and
There is a button Help in the dialog of this constraint. Please read it and come back here or in another topic if more help is needed.
We (the FET authors and other users) found many usages of this constraint. You can for instance make two teachers or two students have the same timetable (if they have m > n activities, add occupy max occupied slots m, all their activities, select all slots of the week - in case they want to come and leave school together). Or, the documented feature, you can make a teacher or a student have activities in some exact slots. Another usage was in: http://lalescu.ro/liviu/fet/forum/index.php?topic=1782.0 (long topic, no need to read though if you don't have time).
Quote
"maximum simultaneous activities from a set in selected time slots"
Thanks a lot again!
Again, please read the Help button of the dialog in this constraint and come back here or in another topic if more help is needed.