Based on fractional differential equations, this paper proposes an optimization modeling method for the mental health quality of vocational students. This article quantifies the psychology of higher vocational students from the perspective of fractional differential equations. At the same time, we use alertness to characterize the risk of mental fatigue and propose a mental health energy equation. We propose a mental health energy replenishment function and consumption function and describe mental health energy during sleep. Finally, we use fractional differential equations to reason about the model deductively. The research shows that it is feasible for us to apply fractional differential equations to predict the mental health problems of vocational students.