URI:
   DIR Return Create A Forum - Home
       ---------------------------------------------------------
       techno game dev forum
  HTML https://technogamedevforum.createaforum.com
       ---------------------------------------------------------
       *****************************************************
   DIR Return to: General Discussion
       *****************************************************
       #Post#: 108--------------------------------------------------
       Have Fun experimenting with Mapping
       By: johnfree Date: May 19, 2012, 1:11 pm
       ---------------------------------------------------------
       When a flea hops, where he lands depends where he hopped from.
       YOU can make up the rules!
       It is fun because this way you can draw his tracks on the screen
       as fabulous coloured patterns.
       For thousands of years everyone "knew" (it was "obvious") that
       simple mappings (hopping rules) give simple patterns (maps)
       A very few people knew otherwise, but were ridiculed.
       Then, surprisingly recently, it was discovered that even the
       SIMPLEST hopping rule can give results that are UTTERLY
       UNPREDICTABLE long term.
       Where you will end up is fixed (predestined) but the ONLY way to
       find out is to take ALL the jumps and see!
       For example  think of a flea hopping along a line.
       He is now at position 0.6
       He has an amount of energy we will call 1 (or 100%).
       This would be enough to hop  from 0.6 to 2.4 (increasing his
       distance by 4 times)
       But to get to 0.6 he used some of his energy, leaving him with
       only 1-.6 = .4
       So his next position is 0.6 times 4 times (1- 0.6), which is
       0.96
       His next hop now takes him to 0.96 times 4 times (1-.96)
       And so on.......
       It is a bit like an animal population (rabbits) that would
       quadruple each year but cannot do that because there is not
       enough food.
       The interersting thing is this ever-so-simple rule next
       x=4x(1-x) gives results that NEVER repeat!
       One of the first games I ever wrote was like this.
       I had fish and plants in a tank
       The fish eat the plants and the plants give the oxygen needed by
       the fish.
       So the fish population goes up and down (often while the plant
       population goes down and up - but not always!)
       I called this the "Fish Oscillator" for it was spectacularly
       unpredictable.
       You can do the same thing using a flea that hops horizontally
       (x) on the screen as well as vertically (y)
       Start him at x=0.1, y=0.31 and use the mapping hop rules
       next x=4x(1-x)
       next y=4y(1-y)
       You will eventually get the whole screen chaotically filled with
       flea-landings.
       But now try not a 4 times growth but a growth between 3 and 4
       Now VERY strange things happen! Not always chaos!
       *****************************************************