programming
##
Evolving Virtual Creatures 2018-11-30

### Research

### Attributes

- Cold resistance
- Heat resistance
- Simulation priority
- Reproduction penalty time ( = sum of all settable attributes )

### Inputs

- Potential mate pearson correlation coefficient (primary matrix)
- Temperature (between -1 and 1)
- Light level (-1 to 1)
- Crowdedness (0 to 1)

### Outputs

- Reproduce
- Move north
- Move east
- Move south
- Move west

### DNA

- Two matrices
- one from Inputs + Attributes to vector with length N
- one from length N to Outputs

- Crossover is done over Attributes and two matrices
- Mutation is done with low probability on primary matrix, medium probability on attributes and high probability on secondary matrix
- Only creatures with same length N can reproduce with each other
- Potential mate is computed by selecting closest other creature with length N

### Simulation

- Rectangular grid, split in subrectangles. Loops horizontally
- Each step, y subrectangles are chosen, with higher probability at the north and south pole
- For each chosen subrectangle, x times, choose a creature and simulate a step
- Temperature simulation is done with a linear falloff each step, temperature is added according to sunlight on a sphere
- Each step sun angle is updated