Fixing static field/method bag + adding initial data structures for the
core algorithm.
Signed-off-by: Tihomir Gvero <tihomir.gvero@gmail.com>