This paper is focused on the study of a vibrating system forced by a rotating unbalance and coupled to a tuned mass damper (TMD). The analysis of the dynamic response of the entire system is used to define the parameters of such device in order to achieve optimal damping properties. The inertial forcing due to the rotating unbalance depends quadratically on the forcing frequency and it leads to optimal tuning parameters that differ from classical values obtained for pure harmonic forcing. Analytical results demonstrate that frequency and damping ratios, as a function of the mass parameter, should be higher than classical optimal parameters. The analytical study is carried out for the undamped primary system, and numerically investigated for the damped primary system. We show that, for practical applications, proper TMD tuning allows to achieve a reduction in the steady-state response of about 20% with respect to the response achieved with a classically tuned damper.