Lagrangian formalism is a technique using which we can obtain the time evolution of a dynamical system. Given a dynamical system, can we say whether or not we can write down a Lagrangian (solving it is another thing) i.e. can we say that a given dynamical system is in the realm of lagrangian dynamics (or is it invalid to ask such a question)?