Author Topic: Challenge #4: Dynamic Predation  (Read 5422 times)

Offline Elite

  • Bot Overlord
  • ****
  • Posts: 532
    • View Profile
Challenge #4: Dynamic Predation
« on: October 01, 2007, 02:04:02 PM »
The second in the new challenge batch.

Programming an effective and innovative dynamic predator is harder than it sounds. The challenges here include ways of softening and ramping the viciousness of the predators depending on prey population, predator attack strategies, and effectively utilising the new features to implement predation as an effective selection pressure.

(told you they were going to be vague)

What works and what doesn't when it comes to dynamic predators?
« Last Edit: October 01, 2007, 02:04:33 PM by Elite »

Offline EricL

  • Administrator
  • Bot God
  • *****
  • Posts: 2266
    • View Profile
Challenge #4: Dynamic Predation
« Reply #1 on: October 01, 2007, 02:28:28 PM »
This may be obvious, but I have had great success throttling preditors in a very simple way using only two rules.  

1) They limit their own population to some fixed number, e.g. 100, or to some a percentage of the total population in the sim using the ratio of .totalmyspecies to .totalspecies.  That is, they simply do not reproduce when their population exceeds this value.

2) They use some ratio of .totalmyspecies to .totalspecies (perhaps a different ratio from above) to determine when to hunt.  That is, I build a very effective and lethal preditor that is either all or nothing based on this ratio.  It kills everything it can as fast as it can when that ratio is below a certain level and "blacks out" and does nothing when it is above.

What happens is that the preditor stutters.  It kills for a few cycles, then the ratio climbs and it blacks out and drifts, going into limbo.  Prey see a preditor coming at them that effectivly executes only 1 cycle for every N of theirs.  They effectively can dodge, flee, etc. even when their skills are greatly inferior to the preditor.  Selection favors prey that do this better than others.  The slow , the weak, the stupid get killed off.   Now, here's the beauty.  As prey evolve and get better, the preditor naturally does too without any changes of fancy throttling of shot power or chase speed or whatever since it effectivly gets to execute a larger percentage of the time, becoming more effective automatically.  It simply doesn't "black out" as much.

Slick, huh?

EDIT: Oh, I should point out that in order to avoid doubling of the preditor population the moment the ratio hits the magic number, I generally add something like

1 100 rnd 1 =

as a condition in the reproduction gene.  You can do the same thing in the hunting conditions if you want to make the ratio at which the bots hunt fuzzy.  In this way, prey can never be sure that a preditor is safe to approach or feed on.  They can try it, but it's risky.  

Those gazelles need to always keep one eye on that lion pride...
« Last Edit: October 01, 2007, 02:41:29 PM by EricL »
Many beers....

Offline fulizer

  • Bot Destroyer
  • ***
  • Posts: 198
    • View Profile
Challenge #4: Dynamic Predation
« Reply #2 on: November 11, 2007, 04:49:43 AM »
I find a predetor evolve it find the best one save it start a new simulation with the improved predetor. the lazy mans way of programming! but it can sometimes be slow I normally ennd up programming them myself after a little bit of evolution
"If this is coffee bring me tea, If this is tea, bring me coffee"