This repo contains 4 projects implemented during my classes.
Genetic alghoritm imlementation in code used to solve problem of Facility Layout Optimization(see example).
9 "machines" placed in 3x4 grid need to be set up in such way, that cost (dependent on machine placement) is lowest or very close to lowest possible. Data samples here. Data doc here
CSP solver implemented along with two examples:
- 0 or 1 for each cell
- max sequence of same numbers in row and cols is less than 3
- each row and collumn is unique
- each row and collumn has same number of 0 and 1
Rules explained here
- CSP - the definiton of CSP problem. Consists of constraints and current state
- ForwardChecking - after setting variable value updates remaining variables domains. If some is empty we need to go back.
- BackTracking - sets next variable value until constraint is broken. If so then it's going back.
- Constraint - specify constraint (each problem has it's own constraints)
- Variable selector - heuristic that determins wich variable shloud be selected next.
Implemented Players:
You can observe how players play togethger in console:
You can also paly against any palyer: