A mathematical model for energy generation in the cells of the leaves of a plant is obtained and solved to show that the sun intensity at various times of the day affects the level of carbohydrate produced. The result also shows that excessive sun intensity produces less carbohydrate in a plant, which means the deactivation of enzymatic action. Particularly, we show the effect of the term which is likened to the case of diabetes in man.