MATLAB project to optimize army value