Two optimization problems for nonlinear hereditary periodic control systems