Two-Stage Optimization of Battery Energy Storage Capacity to Decrease Wind Power Curtailment in Grid-Connected Wind Farms