The current research is conducted with the aim of investigating a multi-generation energy system (MGS) for electricity, hydrogen, heating, cooling and hot water production using SRC, Kalina cycle and proton exchange membrane (PEM) electrolysis as the main subsystems. The thermodynamic analysis namely energy, exergy, and exergo-economic examination carried out. Analysis for each component is done after thermodynamic modeling. The exergy investigation showed that regenerator 2, vapor generator and condenser had the highest exergy destruction rate, respectively. A comparison was made between the current work and the basic system, and according to the results obtained, the system's ability to produce electricity, cooling, heating and hydrogen are calculated as 782 kW, 173.2 kW, 2265 kW and 0.01613 mol/day, respectively. Also, the energy and exergy efficiency of the proposed system increased by 3.13% and 5.37%, respectively. The optimization based on PSO method was carried out. The results of PSO optimization represented that in the case exergy destruction and exergy efficiency will be the optimization target these two outputs can reach the value of 2208 kW and 9.84%, while optimization based on exergy efficiency and production cost rate will lead to 9.86% and 166.6 $/h.