Generalized nonlinear Lagrangian for pseudoscalar and scalar mesons