Re: Assignmnet problem with rules



Willem wrote:
Daniel wrote:
) Come up with initial assignments that don't break the independent rules, ) then check to see how many of the dependent rules are broken. Start ) swapping assignments, if fewer rules are broken, keep the swap, if more ) rules are broken swap back. The longer the program runs, the fewer rules ) that will be broken, but you can get a solution at any time.

This way, you'll only reach a local minimum. You could add a variable that
indicates the probability of continuing with a 'worse' swap, and decrease
that variable over time. (I think that's how it works at least...)

This approach is starting to sound more and more like a genetic algorithm.
Which actually might be a good approach to this problem, since it is
designed for problems where there is no direct route to an optimal
solution and since it is usually fairly good at avoiding getting stuck
in a local minimum ("hill climbing"). And a genetic algorithm will also
(up to a point) get better and better solutions the longer it runs, but
will give you a solution at any time.

- Logan
.



Relevant Pages

  • Re: Assignmnet problem with rules
    ... Come up with initial assignments that don't break the independent rules, ... then check to see how many of the dependent rules are broken. ... rules are broken swap back. ... This approach is starting to sound more and more like a genetic algorithm. ...
    (comp.programming)
  • Re: Assignmnet problem with rules
    ... Come up with initial assignments that don't break the independent rules, ... then check to see how many of the dependent rules are broken. ... rules are broken swap back. ... You all think I'm paranoid, ...
    (comp.programming)
  • Re: Summer Swap received - Wow!!!
    ... place in THIS swap, and others like it in the past. ... assignments had been in a different order. ... but I like the part of the swap form that allows me ... I'm not at all interested in collecting when with a sentence or two in the ...
    (rec.collecting.coins)
  • Re: Swapping Values in Vector (STL)
    ... Sami Lakka wrote: ... > what would be the best way to swap to cell values in ... If there is a better way to swap elements than the ... three assignments it is not uncommon to overload std::swap. ...
    (alt.comp.lang.learn.c-cpp)