This paper presents the findings of the research aimed at developing computer models to determine the operating conditions in electric power systems (EPSs) feeding DC and AC railway substations. The object of the research is an EPS with a predominant traction load whose high-voltage power lines are connected to transformer and converter substations with 3 kV and 27.5 kV traction networks. The supply network includes 110 kV and 220 kV power lines. The EPS operating parameters are calculated based on the decomposition of the system into alternating and direct current segments. Calculations are performed for the fundamental frequency and high harmonic frequencies. The modeling technique is universal and can be used to determine the operating parameters and power quality indices for any configuration of an EPS and various designs of traction networks. With this technique, one can solve numerous additional problems, such as calculating the processes of ice melting in traction networks and power lines, determining electromagnetic field strengths, and assessing the heating of power line wires and catenary suspensions. The results obtained show that the voltages on the current collectors are within acceptable limits for all AC and DC electric locomotives. The levels of asymmetry on the 110 and 220 kV tires of traction substations (TP) do not exceed the normally permissible values. The values of the asymmetry coefficients for DC TP are tenths of a percent. With an increase in the size of traffic and in post-emergency conditions caused by the disconnection of communication between one of the support substations and the EPS, the asymmetry indicators on the 220 kV buses of AC substations may exceed the permissible limits. Phase-controlled reactive power sources can be used to reduce them. The analysis of the results of the determination of non-sinusoidal modes allows us to formulate the conclusion that the values of harmonic distortion go beyond the normative limits. Passive and active filters of higher harmonics can be used to normalize them. Calculations of thermal modes of traction transformers show that the temperatures of the most heated points do not exceed acceptable values.