The formulation of antenna array optimization with variable phase and constant amplitude excitation is presented. The method shown using steepest ascents is general in that a nonlinear performance index expressible as a ratio of Hermitian quadratic forms can be optimized. Directive gain optimization of a linear array of isotropic elements is illustrated and compared with gain optimization using variable excitation. Endfire gain is emphasized and compared to the Hansen-Woodyard condition showing that the Hansen-Woodyard condition is not optimum in the directive gain sense for a discrete endfire array. In addition a <tex xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">0.4\lambda</tex> spaced linear array is optimized using phase only for scanning from endfire to broadside.