Starting implementation of controlLaw function