Wave equations and reaction-diffusion equations with several nonlinear source terms with critical energy