Questions tagged [drools-planner]

Drools Planner optimizes planning, routing and scheduling. It solves resource optimization problems such as bin packing, vehicle routing, employee rostering and course timetabling. It scales out in data and constraints. It's open source (ASL), pure java and enterprise ready.

Drools Planner has been renamed to OptaPlanner. It is a lightweight, embeddable planning engine written in Java™. It helps normal Java™ programmers solve constraint satisfaction problems efficiently. Under the hood, it combines optimization heuristics and metaheuristics with very efficient score calculation.

148 questions
2
votes
1 answer

Drool rules using cron expression?

I have one requirement that i want to fire rule only for weekdays.i have some rule like smoke, temperature, motion.can you suggest me how i can make rule as per my requirement.please provide me some example. Is there any better way to fire rules…
Rahul Pandey
  • 605
  • 1
  • 5
  • 17
2
votes
2 answers

drools not exists in collection

I need to fire a rule if a collection does not have a specific object. AuditAssignment is available as problem fact. AuditAssignment has a property "requiredSkill" Audit Assignment has a property "auditor" Auditor object has a list of…
lives
  • 1,243
  • 5
  • 25
  • 61
2
votes
1 answer

Optaplanner: extending the vrp example to tackle multi trip case

At my company we are currently using optaplanner to solve a vehicle routing problem with great results, we built a web app to manage vehicles, clientes, locations, depots and to show a graphic representation of the solution (including showing the…
2
votes
1 answer

Optaplanner : list of planning variables in one planning entity?

I am looking into the example use cases from OptaPlanner. And I could not find any similar example which can solve multiple planning variables in one planning entity. For example, in nurse rostering, each ShiftAssignment(PlanningEntity) for one…
sky.flyer
  • 91
  • 8
2
votes
1 answer

How to make optaplanner a REST webservice

I just started using the Optaplanner as a way to do vehicle routing. However I would like to expose the optaplanner as a web service (preferably REST). Now I've read on several blogs that it can be done with Apache Camel. However finding a decent…
Agilix
  • 182
  • 2
  • 12
2
votes
1 answer

OptaPlanner vehicle routing and relations between customer visits

I am using OptaPlanner to optimize a vehicle routing problem very similar to the provided example. I am faced with the following challenge and will appreciate some ideas. Some of the visits to customers have relations to other visits, for…
Shatz
  • 55
  • 6
2
votes
2 answers

Implementing Custom metaheuristic in OptaPlanner

As of now Opta Planner planner provides support for: Tabu Search. Simulated Annealing. However if i need to implement any other algorithm like Genetic Algorithm with Opta Planner then where and how could it could be used. I have got the code of…
Rajeev Singh
  • 504
  • 2
  • 7
  • 21
2
votes
3 answers

Scheduling timetable algorithm

I was wondering if anyone could please point me the right direction on how to approach the scheduling problem. I have a teacher/student timetable problem, where I have teachers that teach certain subject at certain times and students that have…
JavaFan
  • 1,295
  • 3
  • 19
  • 28
2
votes
3 answers

Installing Drools Planner in Eclipse

I am almost a newbie in Java technologies (exluding programming foundation at school). But I am interested in NP problems and I want to have a look into Drools Planner. So I am trying to install Drool Planner following this…
Alberto De Caro
  • 5,147
  • 9
  • 47
  • 73
2
votes
1 answer

getting list of broken constraints for final best solution in drools-planner

I'm using drools-planner-5.4.0.CR1 and I wanna get list of broken constraints for final best solution and also looked of examples of 5.4.0.CR1 I've implemented like in example but it returns empty list, in other words getScoreDetailList().size() is…
Nurlan
  • 673
  • 4
  • 18
1
vote
1 answer

To satisfy x out of y constraints

I am making a timetabling program which does one to one matches from SubjectTeacherPeriod (planning entity) to Period. There comes a case when I need to: "for y periods, atleast x of the SubjectTeacherPeriod must match a match_condition" For…
Jesvin Jose
  • 22,498
  • 32
  • 109
  • 202
1
vote
1 answer

Can I supply negative values to IntConstraintOccurrence?

I want to enable both positive and negative soft constraints in my application. A +2 implies a positive constraint of weight 2 and a -1 implies a negative constraint of weight 1. Can I supply a negative value as a NEGATIVE_SOFT to imply that it is a…
Jesvin Jose
  • 22,498
  • 32
  • 109
  • 202
1
vote
1 answer

Selecting a set of three distinct objects

Drools Planner used this to select two distinct objects, ensuring that a rule did not fire twice for a given pair of objects. If o1 and o2 made a match, it fired only once, not twice for (o1,o2) and (o2,01). when $stp1 : SubjectTeacherPeriod( …
Jesvin Jose
  • 22,498
  • 32
  • 109
  • 202
1
vote
1 answer

Matching a list (of tags) with another and detecting presence of common elements

My requirement is to match tags. In the example, this particular HourConstraint checks the TeacherHour assigned to Hour(23). Specifically, it checks TeacherHour.attributes["tags"] for the values ["asst_ct","teacher_john_smith"] and detects…
Jesvin Jose
  • 22,498
  • 32
  • 109
  • 202
1
vote
1 answer

Conceptual meaning of 'not' keyword; evaluating between objects

I am trying to find a BucketTotal object which has the smallest total in a Drools Planner project. I adapted this from example code. rule "insertMinimumBucketTotal" when $b : BucketTotal($total : total) not BucketTotal(total > $total) //…
Jesvin Jose
  • 22,498
  • 32
  • 109
  • 202
1
2
3
9 10