Thanks for the ideas. I did know about these possibilities. What I am having
trouble with is actually implementing them.
Could you give me a small example of each? I would really, really, appreciate
it.
Hi,
generally, you have 2 possibilities.
The first is to constrain the task start so that the task can not
intersect the interval (e.g. using the \=: operator). You know the task
length, so no problem here.
The other option is even easier: create an artificial fixed task that
occupies the resource during the outage.
Cheers,
Filip
/ Hi All,
/>/
/>/ I have been studying very hard and have finally created an application
/>/ that will schedule tasks in oz. What is confusing me is how to do the
/>/ following:
/>/
/>/ 1. Don't schedule tasks for a certain time frame on a particular
/>/ resource (Either because the resource is down for repairs/unavailable or
/>/ because a task has already been started and needs to finish)
/>/
/>/ The lines that deal with this in my code are:
/>/
/>/ fun {Compile Problem}
/>/ TaskSpec = Problem.tasks
/>/ Dur = {GetDur TaskSpec}
/>/ TestVal = 10
/>/ TestVal2 = 15
/>/ in
/>/ proc {$ Start}
/>/ Start={GetStart TaskSpec}
/>/ {ForAll TaskSpec
/>/ proc {$ T}
/>/ {ForAll {CondSelect T pre nil}
/>/ proc {$ P}
/>/ Start.P + Dur.P =<: Start.{Label T}
/>/ TestVal =<: Start.{Label T}
/>/ TestVal =<: Start.P
/>/ %% Start.P + Dur.P =<: TestVal2
/>/ %% Start.P \=: TestVal
/>/ %% Start.P \=: TestVal2
/>/ end}
/>/ end}
/>/ {Record.forAll Start proc {$ S}
/>/ S={FD.reflect.min S}
/>/ end}
/>/ end
/>/
/>/ end
/>/
/>/ I can get it to start from a certain point or not schedule after a
/>/ certain point, but I can't figure out how to make the constraints such
/>/ that tasks will be scheduled before a reserved time frame and after.
/>/ Any ideas/help would be greatly appreciated. By the way I am very
/>/ impressed with mozart oz. I am somewhat of a newbie to constraint
/>/ programming but this made it easy to begin./
_________________________________________________________________________________
mozart-users mailing list
[email protected]
http://www.mozart-oz.org/mailman/listinfo/mozart-users