A computer simulation procedure is presented for evaluation and design of an electrical submersible pump (ESP). The System Nodal Analysis technique is also presented for modeling ESP lifted wells. The pump performance can be analyzed using the System Nodal Analysis technique by examining the well production rate versus wellhead back pressure, percentage of water cut and different motor speed as monitored by the Variable Speed Controller. The final goal of the computer simulation is to optimize the well production. Examples will be presented to illustrate the optimization procedure.