Distributed second‐order multi‐agent constrained optimization algorithm with time‐varying cost function