Th USODA (U-tube Steam Generator Optimal Controller Design Analysis) code was developed to simulate the transient behavior of a vertical natural circulation Utube steam generator in PWRs and to design the optimal level controller. The linear steam generator model and optimal control theory were used in the model. The steam generator was represented by 6th order linear differential equations through matrix reduction. The momentum equation for the recirculation flow implements the effects of the separators, U-bend regions, and spatial acceleration. To assure stability, Lyapunov theorem was adopted. The optimal gains were obtained by minimizing the quadratic performance index and by using both the Newton-Raphson and Successive Overrelation (SOR) methods. By taking the advantages of both methods, fast converging was achieved. Sample calculation for KNU-2 showed that a control system consisting of standard proportional and reset controls on water level deviation from a desired setpoint and of proportional control on the difference between steam and feedwater mass flow rates can be successfully employed for the control of water level. The optimization procedure led to a stable system with good controlled response. Also it was shown that the system respons can be adjusted to suit the system designer by varying the level weighting.