FET Forum

FET Development => Suggestions => Topic started by: math on January 16, 2018, 01:20:50 PM

Title: Set of activities are ordered
Post by: math on January 16, 2018, 01:20:50 PM
In my planning scenario I have a number of lectures, each lecture having a number of tutorials. The teachers basically don't care how the lectures and tutorials are placed in the schedule as long as the lecture isn't "in the middle" of the tutorials. What they want is:
Either:
a) lecture precedes tutorials: here the lecture may be planned at tuesday 10am, having the tutorials on tuesday 2am, 4am and wednesday. (lecture and tutorials on same day is ok)
Or:
b) tutorials precede lecture: here the week starts with tutorials (focusing on content of last week's lecture), followed by the new lecture. (here the lecture has to be planned at least one day after the last tutorial; it is NOT ok to have a tutorial at 8am followed by the new lecture at 10am).

FET is perfectly able to generate a schedule with these requirements.
a) can be realized with a number of "Time -> Activities -> Two activities are ordered" constraints (one constraint for each pair of lecture and tutorial)
b) can be realized with a number of "Time -> Activities -> Two activities are ordered" constraints (reverse order of a) as well as a number of "Time -> Activities -> Min days between set of activities" constraints (again one constraint for each pair of lecture and tutorial)

Even though planning is working from the technical point of view, this procedure has some drawbacks:
- Planning is quite time consuming since I have to add a large number of constraints
- Reversing the order (switching from version a to b or vice versa) of a lecture is time consuming as well since the order of all "Time -> Activities -> Two activities are ordered" constraints has to be reversed and all "Time -> Activities -> Min days between set of activities" constraints have to be added/deleted

Unfortunately reversing the order is the most time consuming step of my planning process since generating a schedule usually fails due to a lack of rooms. So I have to "play" with the variants a and b for all the lectures until I find a combination that satisfies my room availabilities.

So I wonder if FET couldn't be a little bit more flexible in this regard, finding a combination of variants a und b for all the lectures itself.

I'm suggesting to add a dialog "Time -> Activities -> A set of activities is ordered".
- When adding a constraint in this dialog, I see two boxes "Activities of Set A" and "Activities of Set B". Adding and removing activities from these boxes works as usual.
- Besides these two boxes I see a checkbox "Activities of Set A precede Activities of Set B" as well as a edit box "Min days between activities of Set A and B"
- There is anouther checkbox "Activities of Set A succeed activities of Set B" as well as a edit box "Min days between activities of Set A and B"

In my scenario I would add the lecture to set A and all the tutorials of that lecture to set B.
I would check the first checkbox (preceed), defining "0" as min days.
I would also check the second checkbox (succeed), defining "1" as min days.

This way FET may try to find a combination of variants a and b itself, saving me a lot of time.
Title: Re: Set of activities are ordered
Post by: Volker Dirr on January 16, 2018, 02:19:38 PM
Writing the interface is not too difficult.
As long as a user checks only 1 checkbox it is "easy": FET could "translate" this constraint into already existing constraints before generating.
But as soon as you check both checkboxes it will be difficult. My trick (just translating into already existing constraints) won't work anymore. As soon as someone check both boxes there will be new check needed in the generating source. I fear it will be complicated to code that.
I think Liviu will answer more detailed. Please wait a bit, there is sadly a bereavement, so it might take some time until he answer more detailed.
Title: Re: Set of activities are ordered
Post by: math on January 16, 2018, 05:35:43 PM
I'm very sorry to hear this, Liviu.
Take all the time you need.
Title: Re: Set of activities are ordered
Post by: Liviu Lalescu on January 16, 2018, 08:52:41 PM
I am willing to try this as a custom version, not in the official.

But I don't think it is possible if you have say 10 groups. Because this means 2^10=1024 variants. 1024 files/variants to generate on. It would be possible for you to choose the parameters for each group of activities, and let FET to generate only for this variant, then swap the buttons and try again, but only for this variant.