FET Forum

FET Support (English) => Get Help => Topic started by: agemagician on September 10, 2013, 11:42:45 PM

Title: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 10, 2013, 11:42:45 PM
Hi,

First, I want to thank you for this amazing program. I am working at an academy and they were doing the scheduling for 6000 students manually. It was talking them weeks to make the schedule which was not satisfying the students nor teacher needs.

Whoever, after I saw this amazing program everything changed. It took me 2 days to enter about 1300 activities and it took the program about 30 min to generate the perfect timing schedule.

Anyway, I have small problem now.

Each student group contains about 250 students so if we having two consecutive lectures it's very hard to move 250 student from one room to another.

Is there any constrain to make consecutive activity tag for any student set should be placed in the same room ?


My current solution :-
1- generate the schedule and look the time.
2- check every and each consecutive lectures for each students set and make a new constrain for those from "A set of activities occupies max different room" and set to to "1".


I can't mark all subjects for each student set to be placed in 1 room because we have limited lectures because after many hours the program only placed tiny fraction of the activities. I don't need student group to study all their subjects in a fixed room.

So is there any automated solution ?
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Liviu Lalescu on September 11, 2013, 02:32:25 PM
Unfortunately, there is no other solution, currently. I'll add your words in the TODO.

Even if I would make such a constraint, I cannot think of a "FET style" name for such a constraint. Could you suggest such a name?
Maybe a good name would be: "Constraint activities if consecutive get same room"?
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 11, 2013, 07:17:23 PM
Hi Liviu,

Thank you so much for your fast response.

This is amazing. I will be waiting your next version and I wish you can add to it this constrain.

I thought of some names:-

1-   Constrain to place specific student set in same room daily.
Max room changes per day for students set

2-   Constrain to place specific activity tag for student set in same room daily.
Max daily room changes per activity tag for students set

3-   Constrain to place consecutive activity tag in same room.
Consecutive Activity tag get same room


Also, I have more great ideas that we needed in our academy.

1- Print the name of the year, group and class under the institute name.
2- Print the schedule from right to left rather than left to right "very useful for Arabic countries like our academy".
3- Make a bold line between each day in the printing and light line between periods.
4- Make a bold line between groups in the printing.
5- Change the font in the printing.
6- Export the schedule to excel.
7- Make a constrain to give a student set a free day automatically if their schedule can be distributed over the rest of days, like teachers "Max days per week for student set".
"Currently I am making a dummy activity with 5 periods to fill a day, a dummy activity tag and dummy rooms to make this"


I will continue to test the program with our heavy schedule needs and I will report to you everything.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Liviu Lalescu on September 11, 2013, 08:27:14 PM
Quote from: agemagician on September 11, 2013, 07:17:23 PM
Hi Liviu,

Thank you so much for your fast response.

This is amazing. I will be waiting your next version and I wish you can add to it this constrain.


Well, it would be quite difficult, so let's explore the alternatives with what we got, like point 1- below.

Quote

I thought of some names:-

1-   Constrain to place specific student set in same room daily.
Max room changes per day for students set

But why can't you add each room in a different building (the number of buildings equal to the number of rooom) and add the existing constraint for buildings?

Quote

Also, I have more great ideas that we needed in our academy.

1- Print the name of the year, group and class under the institute name.
2- Print the schedule from right to left rather than left to right "very useful for Arabic countries like our academy".
3- Make a bold line between each day in the printing and light line between periods.
4- Make a bold line between groups in the printing.
5- Change the font in the printing.
6- Export the schedule to excel.

These are Volker's responsability. I can tell you that 2- is a Qt bug - but you can print the HTML timetables, which are good.

Quote
7- Make a constrain to give a student set a free day automatically if their schedule can be distributed over the rest of days, like teachers "Max days per week for student set".
"Currently I am making a dummy activity with 5 periods to fill a day, a dummy activity tag and dummy rooms to make this"

You can use for 7- the constraint students set interval max days per week, with the interval being the whole day.

Quote
I will continue to test the program with our heavy schedule needs and I will report to you everything.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 13, 2013, 01:42:14 PM
QuoteBut why can't you add each room in a different building (the number of buildings equal to the number of room) and add the existing constraint for buildings?
It will not work because students can change room in the same day if it was a section not a lecture "depend on the activity tag".
We have 3 activity tags :-
1- Lecture should be placed in specific rooms because of the number of students. Each lecture contains a group of students.
2- Section should be place in specific rooms. Each section contain a class of students.
3- Lab should be place in specific rooms. Each section contain a class of students.

If a student set have 2 consecutive lectures, 1 section and 1 lab. They must take the two lectures in the same room then it's ok to change room for lap or section. For that the building trick will not work.

QuoteThese are Volker's responsability. I can tell you that 2- is a Qt bug - but you can print the HTML timetables, which are good.
Ok, can you please forward it to him to make it in his ToDo list?

QuoteYou can use for 7- the constraint students set interval max days per week, with the interval being the whole day.
mmm, I think this constrain will work. Thank you.

Thank you so much for your time and effort :)
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Liviu Lalescu on September 13, 2013, 01:57:13 PM
Quote from: agemagician on September 13, 2013, 01:42:14 PM
QuoteBut why can't you add each room in a different building (the number of buildings equal to the number of room) and add the existing constraint for buildings?
It will not work because students can change room in the same day if it was a section not a lecture "depend on the activity tag".
We have 3 activity tags :-
1- Lecture should be placed in specific rooms because of the number of students. Each lecture contains a group of students.
2- Section should be place in specific rooms. Each section contain a class of students.
3- Lab should be place in specific rooms. Each section contain a class of students.

If a student set have 2 consecutive lectures, 1 section and 1 lab. They must take the two lectures in the same room then it's ok to change room for lap or section. For that the building trick will not work.


I understood. I will keep in mind your request, but it is a bit difficult and I cannot guarantee I'll add it.

Quote

QuoteThese are Volker's responsability. I can tell you that 2- is a Qt bug - but you can print the HTML timetables, which are good.
Ok, can you please forward it to him to make it in his ToDo list?


He will read this message when he returns, today.

Quote

QuoteYou can use for 7- the constraint students set interval max days per week, with the interval being the whole day.
mmm, I think this constrain will work. Thank you.

Thank you so much for your time and effort :)
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Liviu Lalescu on September 13, 2013, 04:35:53 PM
Maybe: ConstraintActivitiesSameRoomIfConsecutive and A set of activities are in the same room if they are consecutive?

Could you send me your input file, giving me also the list of such constraints to be added (if it is not too long)?

Again, I won't promise anything for the moment.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 13, 2013, 08:49:27 PM
QuoteMaybe: ConstraintActivitiesSameRoomIfConsecutive and A set of activities are in the same room if they are consecutive?
Yes, this will be amazing. Also, if it's easier you can make "ConstraintActivityTagsSameRoomIfConsecutive" and A set of activity tags are in the same room if they are consecutive.

QuoteCould you send me your input file, giving me also the list of such constraints to be added (if it is not too long)?
I could not upload the file in the attach files because it's bigger than 512KB. Please, download it form the following link:-
http://www.multiupload.nl/MT3T24W9CI
Whoever, it is in Arabic "I don't know if you can understand it or not".

Constrains :-

Urgent:-
1- ConstraintActivitiesSameRoomIfConsecutive and A set of activities are in the same room if they are consecutive.
2- ConstraintActivityTagsSameRoomIfConsecutive and A set of activity tags are in the same room if they are consecutive.

Maybe:-
1- MaxRoomChangesPerDayForStudentsSet.
2- MaxDailyRoomChangesPerActivityTagForStudentsSet.

QuoteAgain, I won't promise anything for the moment.
It's enough for me that you are caring and you will try to make it :)

Notes:-
1- The input file is locked so you can see the current output.
2- If you unlocked it. It will take time to generate the schedule because of the "A set of Activities occupies max different rooms" constrain, so you can remove these constrain to make the schedule produce faster.
3- I don't know if it's a bug or not. I made "A set of students has a set of home rooms" because I have some student groups that must study in Building A and another student groups that must study in Building B. Whoever, this didn't work and I had to make "A subject has a set of preferred rooms" so I can force student groups to study in Building A or B.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Liviu Lalescu on September 14, 2013, 09:38:54 AM
Quote from: agemagician on September 13, 2013, 08:49:27 PM
3- I don't know if it's a bug or not. I made "A set of students has a set of home rooms" because I have some student groups that must study in Building A and another student groups that must study in Building B. Whoever, this didn't work and I had to make "A subject has a set of preferred rooms" so I can force student groups to study in Building A or B.

Home room(s) does not work if an activity has more students sets, or if that activity has preferred room(s) (preferred room(s) is more powerful than home room(s)).
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Volker Dirr on September 14, 2013, 12:13:20 PM
Quote from: agemagician on September 11, 2013, 07:17:23 PM
1- Print the name of the year, group and class under the institute name.
2- Print the schedule from right to left rather than left to right "very useful for Arabic countries like our academy".
3- Make a bold line between each day in the printing and light line between periods.
4- Make a bold line between groups in the printing.
5- Change the font in the printing.
6- Export the schedule to excel.

1. I am not sure. Are you talking about the subgroup tables?
2. it's a qt bug. the bug is already in their TODO list.
3. to 5. you can change the style by css if you print the html files. or are you talking about printing directly from fet? i am not sure if i do that, because there are much more options that can be added then. so in my opinion you should use the css file to style and print html files.
6. you can import the html files with excel and use them.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 14, 2013, 01:18:09 PM
QuoteHome room(s) does not work if an activity has more students sets, or if that activity has preferred room(s) (preferred room(s) is more powerful than home room(s)).
Aha, thank you so much for clearing that to me. You are really the best :)
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 14, 2013, 01:40:09 PM
Quote1. I am not sure. Are you talking about the subgroup tables?
I am talking about any table.
In case of group. There should be a header under the institue name contains information like :-
Year:1st year          Group:Computer Science
In case of subgroups. There should be a header contains information like:-
Year:1st year          Group:Computer Science        Subgroup:Class 1

Quote2. it's a qt bug. the bug is already in theit TODO list.
Great waiting for the next version :)

Quote3. to 5. you can change the style by css if you print the html files. or are you talking about printing directly from fet? i am not sure if i do that, because there are much more options that can be added then. so in my currently opinion you should use the css file to style and print html files.
Yes, I am talking about printing them directly from FET because FET can allow me in "Subgroups" using "Time Vertical" to print specific "subgroups" while in HTML I have to split them manually in the excel "see attach: Fet-1.jpg".
Ok, I think I will go with CSS for now and excel.
----Which part of CSS I need to change to make :-
1- A horizontal bold line between days in "Subgroups, Time Vertical" "see attach: Fet-2.jpg".
2- A vertical bold line between each group in "Subgroups, Time Vertical" "see attach: Fet-3.jpg".
3- Make a new table after a specific number of groups or after each group in "Subgroups, Time Vertical".

Quote6. you can import the html files with excel and use them.
Yes, I know but I am talking about exporting it from the program because in the program I can choose which subgroups I want to print. In case I need to print specific "subgroups" using "Time Vertical" It will be easy in the program. While in HTML version the "subgroups" using "Time Vertical" displaying all the subgroups from all groups and years. So I need to split them manually.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Liviu Lalescu on September 14, 2013, 01:58:23 PM
I saw your file. But why does it have activities occupy max different rooms with max different rooms = 2 (not 1) ?
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 14, 2013, 02:10:01 PM
QuoteI saw your file. But why does it have activities occupy max different rooms with max different rooms = 2 (not 1) ?
I left the program running for about 15 hours and he could not find a solution when I set it to 1 "Max placed activities was around 200 activities"

I think this because we have limited number of rooms and large number of students. some students groups can study in big rooms "like lec1, lec2, ..." and some student groups can study in medium rooms "like gr1, gr2,...." depend on their numbers. It will be perfect to make them study in their specific rooms depend on their numbers.
Whoever, some teachers have health issues so they can only work in floor number one or two. The problem is that the student that are going to study with those teachers should be placed in medium rooms whoever only the large rooms in the first and second floor so the small number of students must study in large rooms which limited the choose for the algorithm because they will take space from large number of students.
So the only solution to make the algorithm to force consecutive activity tags to have same room per day.

I don't know if I can explain the problem.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Liviu Lalescu on September 14, 2013, 02:27:32 PM
My thought is to try with constraint activities same room if consecutive. Will these replace your activities occupy max rooms constraints, keeping the same activities ids?
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 14, 2013, 02:33:20 PM
QuoteMy thought is to try with constraint activities same room if consecutive. Will these replace your activities occupy max rooms constraints, keeping the same activities ids?
Yes, a constraint like "activities same room if consecutive" can replace "activities occupy max rooms" and will solve the problem.
I am sure if you can make constraint like this will help many institutions.
Thank you again for your time :)
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Liviu Lalescu on September 14, 2013, 09:24:50 PM
The good news is that the new constraint is ready (see http://lalescu.ro/liviu/fet/forum/index.php?topic=1499 in the Snapshots section).

The bad news is that it seems that your file is a bit too hard. I replaced constraints occupy max different rooms with the new constraint activities same room if consecutive and it remained at 1101 activities max placed. I hope that you will try to solve it by lowering a bit the constraints.

Please report results!

I attach your modified file (I just replaced ConstraintActivitiesOccupyMaxDifferentRooms by string ConstraintActivitiesSameRoomIfConsecutive, opened the file, then saved it).
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 14, 2013, 10:49:02 PM
QuoteThe bad news is that it seems that your file is a bit too hard. I replaced constraints occupy max different rooms with the new constraint activities same room if consecutive and it remained at 1101 activities max placed. I hope that you will try to solve it by lowering a bit the constraints.
Wow, Amazing you are one of the best developers I have ever seen "Fast and reliable". The constraint worked absolutely perfect for me.
I know what was the problem when you generated the schedule. There are few subjects that many subgroups from different years and groups join together to study it which make it difficult to make them all study in the same room after this subject. Whoever, I know this is impossible and it's ok to let them change the room in that rare case.

Results:-
1- When using the "A set of activities occupies max different room" with 2 rooms the program was able to generate the schedule after about one hour and it was impossible to generate the schedule with 1 room.
2- When using the new constrain the program was able to produce the schedule in less that a minute and all students never changed their room if the activities was consecutive.

I don't know how to thank you. You really made my day :)
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Liviu Lalescu on September 14, 2013, 10:55:19 PM
You are welcome! Thank you for your suggestion as well, you make the program become better!

Could you give me your corrected file, please? Attach on the forum, archived.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 14, 2013, 11:35:07 PM
QuoteYou are welcome! Thank you for your suggestion as well, you make the program become better!
Could you give me your corrected file, please? Attach on the forum, archived.

Yes, sure. It's from my pleasure.
Whoever, the file is too large to uploaded in the forum "2.41 MB when it's locked and about 1.7 MB unlocked".

I uploaded it to here:-
http://www.multiupload.nl/M8Y0J1BL3G

Thank you again for your effort and time.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Liviu Lalescu on September 14, 2013, 11:56:32 PM
I can tell you that I let more time my original file and it solved in 2 hours, 5 minutes and 6 seconds for starting random seed X=123, Y=123, then next run was done in 17 minutes and 16 seconds. So, more good news :)
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 15, 2013, 12:11:01 AM
QuoteI can tell you that I let more time my original file and it solved in 2 hours, 5 minutes and 6 seconds for starting random seed X=123, Y=123, then next run was done in 17 minutes and 16 seconds. So, more good news :)

If I was not a computer science graduate I was going to say this program contains a demon that solve the schedules  ;D

Great news :)

I have test a lot of schedule software and by a lot I mean a lot. Including Timefinder, tablex, unitime, Lantiv, Mimosa, wise timetable and  asc timetable. I can say without hesitating that FET is the best among them in very single thing.

I think the only weak point in the program is the printing module. Anyway, I will continue discussing with Volker the possibility of adding more abilities to the printing module.

Thank you again for your time and effort.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Liviu Lalescu on September 15, 2013, 03:15:10 AM
Please let me know if I can add your file to the official examples (no privacy problems). Also, tell me in which directory.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Volker Dirr on September 15, 2013, 10:36:34 AM
Quote from: agemagician on September 14, 2013, 01:40:09 PM
Quote1. I am not sure. Are you talking about the subgroup tables?
I am talking about any table.
In case of group. There should be a header under the institue name contains information like :-
Year:1st year          Group:Computer Science
In case of subgroups. There should be a header contains information like:-
Year:1st year          Group:Computer Science        Subgroup:Class 1

ah. ok. Now i see it again.
There are 2 things why i didn't wrote that.
the minor problem:
data is at several schools redundant. so for example it is year "5" and group "5a". so it is clear: of course group "5a" containt into year "5". So i don't need to print "5 - 5a". it is redundant.
the bug problem:
A subgroup might be member of a lot of other groups. So it will be a very long list of groups and years.
Similar problem for years.
All this information won't fit in a single line.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Volker Dirr on September 15, 2013, 10:40:37 AM
Quote from: agemagician on September 14, 2013, 01:40:09 PM
Quote2. it's a qt bug. the bug is already in theit TODO list.
Great waiting for the next version :)

Don't expect a quick fix of that bug. I reported it already some time ago and they didn't fixed it in the last version.
It is only a "priority 3 bug". So they will fix bugs with priority 1 and 2 first. They also have limited resources.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: Volker Dirr on September 15, 2013, 11:00:26 AM
Quote from: agemagician on September 14, 2013, 01:40:09 PM
1- A horizontal bold line between days in "Subgroups, Time Vertical" "see attach: Fet-2.jpg".
2- A vertical bold line between each group in "Subgroups, Time Vertical" "see attach: Fet-3.jpg".
3- Make a new table after a specific number of groups or after each group in "Subgroups, Time Vertical".

ah. ok. I understand what you mean:
1. No easy solution by css at the moment. But that shouldn't very difficult to code. I will write this in my TODO.
2. No easy solution by css at the moment. This will be more difficult to code. (See also point 3b)
3.a. "Make a new table after a specific number of groups". Impossible by css, but will be easy to code (because it is already coded for internal printing, just not for html export in a file)
3.b.  "Make a new table after each group". Impossible by css. Also don't forget this will be more difficult, because a subgroup might be member of several groups. So what should i do: print the subgroup into each group? this will make very large files with a lot of redundant data. Or shouldn't i print redundant data (like now). the files will be much smaller, but you might miss data at some places.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 15, 2013, 10:35:10 PM
QuotePlease let me know if I can add your file to the official examples (no privacy problems). Also, tell me in which directory.

Yes, sure but please wait until the end of this weekend because we are still refining the schedule "Removing subjects, adding new teachers, etc.."
I will send you the final version of the schedule this weekend. Thank you again for everything :)
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 15, 2013, 10:42:04 PM
Quoteah. ok. Now i see it again.
There are 2 things why i didn't wrote that.
the minor problem:
data is at several schools redundant. so for example it is year "5" and group "5a". so it is clear: of course group "5a" containt into year "5". So i don't need to print "5 - 5a". it is redundant.
the bug problem:
A subgroup might be member of a lot of other groups. So it will be a very long list of groups and years.
Similar problem for years.
All this information won't fit in a single line.

mmm, aha. I think I have a solution for these problems:-
1- Make a comment for each group or a minor name for printing beside the group name.
2- For subgroups allow a comment or a minor name beside the full name for printing.

An easier solution why you don't just add a textbox in the printing form and call it header and let the user fill it with whatever they need to be printed in top of the current page?
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 15, 2013, 10:44:27 PM
QuoteDon't expect a quick fix of that bug. I reported it already some time ago and they didn't fixed it in the last version.
It is only a "priority 3 bug". So they will fix bugs with priority 1 and 2 first. They also have limited resources.

Ok, waiting for this bug to be fixed. It maybe a priority 3 bug but It's a priority 1 for all arab continues :)
Anyway, I really appreciate your time and effort.
Title: Re: Consecutive activity tag for student group should be placed in same room
Post by: agemagician on September 15, 2013, 10:48:11 PM
Quote1. No easy solution by css at the moment. But that shouldn't very difficult to code. I will write this in my TODO.
Ok, great waiting for this :)

Quote2. No easy solution by css at the moment. This will be more difficult to code. (See also point 3b)
But it's not impossible and I trust you can do it :)

Quote3.a. "Make a new table after a specific number of groups". Impossible by css, but will be easy to code (because it is already coded for internal printing, just not for html export in a file)
3.b.  "Make a new table after each group". Impossible by css. Also don't forget this will be more difficult, because a subgroup might be member of several groups. So what should i do: print the subgroup into each group? this will make very large files with a lot of redundant data. Or shouldn't i print redundant data (like now). the files will be much smaller, but you might miss data at some places.
Both will not be necessary if you could do number 1 and 2.