The optimal location and configuration of wind farms in a large region is important information for policy makers, electricity system planners and wind farm developers. The model developed in this paper uses wind resource data, population data and transmission line locations to find the configuration that produces electricity at minimum cost. Several economic and regulatory scenarios were used to demonstrate the importance of each factor in siting optimally siting wind farms. We demonstrate how gradient based optimization could be applied to discover optimal wind farm location and size. Although the use of gradient based optimization makes the model sensitive to local minima, numerical smoothing is used to reduce this sensitivity.