Class WindFarm
java.lang.Object
neqsim.util.NamedBaseClass
neqsim.process.SimulationBaseClass
neqsim.process.equipment.ProcessEquipmentBaseClass
neqsim.process.equipment.powergeneration.WindFarm
- All Implemented Interfaces:
Serializable, Runnable, ProcessEquipmentInterface, ProcessElementInterface, SimulationInterface, NamedInterface
Offshore/onshore wind farm model aggregating multiple turbines with power curves and wake losses.
Models a wind farm using industry-standard approaches:
- Per-turbine power curve (cut-in, rated, cut-out wind speeds)
- Jensen/Park wake loss factor
- Air density correction for altitude, temperature, and pressure
- Weibull wind speed distribution for annual energy production (AEP)
- Time-series wind speed input for dynamic simulations
Usage Example
WindFarm farm = new WindFarm("Dogger Bank", 100);
farm.setRatedPowerPerTurbine(15.0e6); // 15 MW
farm.setRotorDiameter(236.0); // meters
farm.setHubHeight(135.0); // meters
farm.setWindSpeed(10.5);
farm.run();
double totalPower = farm.getPower(); // Watts
- Version:
- 1.0
- Author:
- esol
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate doubleAir density at hub height [kg/m3].private doubleAir temperature [C] for density correction.private doubleAtmospheric pressure [Pa] for density correction.private doubleAvailability factor [0-1], accounts for maintenance downtime.private doubleCalculated capacity factor [0-1].private intCurrent time step index for dynamic simulation.private doubleCut-in wind speed [m/s].private doubleCut-out wind speed [m/s].private doubleElectrical losses [0-1], cables, transformers, etc.private doubleHub height above sea level [m].private doubleMaximum power coefficient (Betz limit is 0.593).private intNumber of turbines in the farm.private doubleCalculated total farm power output [W].private double[]Time-series power output [W].private doubleRated power per turbine [W].private doubleRated wind speed [m/s].private doubleRotor diameter [m].private static final longSerialization version UID.private doubleWake loss factor [0-1], typical 0.05 to 0.15 for offshore.private doubleWeibull scale parameter [m/s] for AEP calculation.private doubleWeibull shape parameter for AEP calculation.private doubleCurrent wind speed at hub height [m/s].private double[]Time-series wind speeds for dynamic simulation [m/s].Fields inherited from class ProcessEquipmentBaseClass
conditionAnalysisMessage, energyStream, hasController, isSolved, properties, reportFields inherited from class SimulationBaseClass
calcIdentifier, calculateSteadyState, timeFields inherited from class NamedBaseClass
name -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoubleCalculate annual energy production using Weibull distribution.doublecalculateTurbinePower(double speed) Calculate single turbine power from wind speed using cubic power curve model.doubleGet current air density [kg/m3].doubleGet availability factor.doubleGet calculated capacity factor.doubleGet corrected air density based on temperature and pressure.intGet current time step index.doubleGet cut-in wind speed [m/s].doubleGet cut-out wind speed [m/s].doubleGet hub height [m].intGet number of turbines.doublegetPower()Get total farm power output [W].doubleGet total farm power output in specified unit.double[]Get time-series power output after running dynamic simulation.doubleGet rated power per turbine [W].doubleGet rated wind speed [m/s].doubleGet rotor swept area [m2].doubleGet rotor diameter [m].doubleGet total rated farm capacity [W].doubleGet wake loss factor.doubleGet Weibull scale parameter.doubleGet Weibull shape parameter.doubleGet current wind speed [m/s].voidIn this method all thermodynamic and unit operations will be calculated in a steady state calculation.voidRun the full time series and populate powerTimeSeries array.voidsetAirTemperature(double temp) Set air temperature for density correction [C].voidsetAtmosphericPressure(double pressure) Set atmospheric pressure for density correction [Pa].voidsetAvailabilityFactor(double factor) Set availability factor [0-1].voidsetCutInSpeed(double cutIn) Set cut-in wind speed [m/s].voidsetCutOutSpeed(double cutOut) Set cut-out wind speed [m/s].voidsetElectricalLossFactor(double factor) Set electrical loss factor [0-1].voidsetHubHeight(double height) Set hub height [m].voidsetMaxPowerCoefficient(double cp) Set max power coefficient (Cp).voidsetNumberOfTurbines(int n) Set number of turbines.voidsetRatedPowerPerTurbine(double ratedPower) Set rated power per turbine [W].voidsetRatedSpeed(double rated) Set rated wind speed [m/s].voidsetRotorDiameter(double diameter) Set rotor diameter [m].voidsetWakeLossFactor(double factor) Set wake loss factor [0-1].voidsetWeibullScale(double scale) Set Weibull scale parameter for AEP calculation.voidsetWeibullShape(double shape) Set Weibull shape parameter for AEP calculation.voidsetWindSpeed(double speed) Set current wind speed at hub height [m/s].voidsetWindSpeedTimeSeries(double[] windSpeeds) Set time-series wind speeds for dynamic simulation.private doubleweibullPDF(double v) Weibull probability density function.Methods inherited from class ProcessEquipmentBaseClass
addCapacityConstraint, addController, copy, displayResult, equals, getAvailableMargin, getAvailableMarginPercent, getBottleneckConstraint, getCapacityConstraints, getConditionAnalysisMessage, getConstraintEvaluationReport, getController, getController, getControllers, getEffectiveCapacityFactor, getEnergyStream, getEntropyProduction, getExergyChange, getFailureMode, getMassBalance, getMassBalance, getMaxUtilization, getMaxUtilizationPercent, getMechanicalDesign, getMinimumFlow, getPressure, getPressure, getProperty, getReferenceDesignation, getReport_json, getResultTable, getSpecification, getTemperature, getTemperature, getThermoSystem, getUtilizationSummary, hashCode, initElectricalDesign, initializeDefaultConstraints, initInstrumentDesign, initMechanicalDesign, isActive, isActive, isCapacityAnalysisEnabled, isCapacityExceeded, isFailed, isHardLimitExceeded, isNearCapacityLimit, isSetEnergyStream, reportResults, restoreFromFailure, run_step, runConditionAnalysis, setCapacityAnalysisEnabled, setController, setEnergyStream, setEnergyStream, setFailureMode, setFlowValveController, setMinimumFlow, setPressure, setReferenceDesignation, setRegulatorOutSignal, setSpecification, setTemperature, simulateDegradedOperation, simulateTrip, solved, toJson, toJsonMethods inherited from class SimulationBaseClass
getCalculateSteadyState, getCalculationIdentifier, getTime, increaseTime, isRunInSteps, setCalculateSteadyState, setCalculationIdentifier, setRunInSteps, setTimeMethods inherited from class NamedBaseClass
getName, getTagNumber, setName, setTagNumberMethods inherited from class Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface NamedInterface
getName, getTagName, getTagNumber, setName, setTagName, setTagNumberMethods inherited from interface ProcessEquipmentInterface
getCapacityDuty, getCapacityMax, getElectricalDesign, getEquipmentState, getExergyChange, getExergyDestruction, getExergyDestruction, getFluid, getInletStreams, getInstrumentDesign, getOperatingEnvelopeViolation, getOutletFlowRate, getOutletPressure, getOutletStreams, getOutletTemperature, getReferenceDesignationString, getRestCapacity, getSimulationValidationErrors, isSimulationValid, isWithinOperatingEnvelope, needRecalculation, validateSetupMethods inherited from interface SimulationInterface
getCalculateSteadyState, getCalculationIdentifier, getTime, increaseTime, isRunInSteps, run, run_step, runTransient, runTransient, setCalculateSteadyState, setCalculationIdentifier, setRunInSteps, setTime
-
Field Details
-
serialVersionUID
private static final long serialVersionUIDSerialization version UID.- See Also:
-
numberOfTurbines
private int numberOfTurbinesNumber of turbines in the farm. -
ratedPowerPerTurbine
private double ratedPowerPerTurbineRated power per turbine [W]. -
rotorDiameter
private double rotorDiameterRotor diameter [m]. -
hubHeight
private double hubHeightHub height above sea level [m]. -
windSpeed
private double windSpeedCurrent wind speed at hub height [m/s]. -
cutInSpeed
private double cutInSpeedCut-in wind speed [m/s]. -
ratedSpeed
private double ratedSpeedRated wind speed [m/s]. -
cutOutSpeed
private double cutOutSpeedCut-out wind speed [m/s]. -
airDensity
private double airDensityAir density at hub height [kg/m3]. -
airTemperature
private double airTemperatureAir temperature [C] for density correction. -
atmosphericPressure
private double atmosphericPressureAtmospheric pressure [Pa] for density correction. -
maxPowerCoefficient
private double maxPowerCoefficientMaximum power coefficient (Betz limit is 0.593). -
wakeLossFactor
private double wakeLossFactorWake loss factor [0-1], typical 0.05 to 0.15 for offshore. -
availabilityFactor
private double availabilityFactorAvailability factor [0-1], accounts for maintenance downtime. -
electricalLossFactor
private double electricalLossFactorElectrical losses [0-1], cables, transformers, etc. -
power
private double powerCalculated total farm power output [W]. -
capacityFactor
private double capacityFactorCalculated capacity factor [0-1]. -
weibullShape
private double weibullShapeWeibull shape parameter for AEP calculation. -
weibullScale
private double weibullScaleWeibull scale parameter [m/s] for AEP calculation. -
windSpeedTimeSeries
private double[] windSpeedTimeSeriesTime-series wind speeds for dynamic simulation [m/s]. -
powerTimeSeries
private double[] powerTimeSeriesTime-series power output [W]. -
currentTimeStep
private int currentTimeStepCurrent time step index for dynamic simulation.
-
-
Constructor Details
-
WindFarm
public WindFarm()Default constructor. -
WindFarm
-
WindFarm
Construct with name and number of turbines.- Parameters:
name- equipment namenumberOfTurbines- number of wind turbines
-
-
Method Details
-
calculateTurbinePower
public double calculateTurbinePower(double speed) Calculate single turbine power from wind speed using cubic power curve model.Uses the standard regions:
- Below cut-in: 0 W
- Cut-in to rated: cubic interpolation P = Prated * ((v - vci)/(vr - vci))^3
- Rated to cut-out: Prated
- Above cut-out: 0 W
- Parameters:
speed- wind speed at hub height [m/s]- Returns:
- single turbine power output [W]
-
getCorrectedAirDensity
public double getCorrectedAirDensity()Get corrected air density based on temperature and pressure.Uses ideal gas law: rho = P / (R_air * T) where R_air = 287.058 J/(kg K).
- Returns:
- corrected air density [kg/m3]
-
calculateAEP
public double calculateAEP()Calculate annual energy production using Weibull distribution.Integrates the power curve against the Weibull probability density function using numerical integration from 0 to 35 m/s with 0.5 m/s steps.
- Returns:
- annual energy production [Wh]
-
weibullPDF
private double weibullPDF(double v) Weibull probability density function.- Parameters:
v- wind speed [m/s]- Returns:
- probability density [1/(m/s)]
-
setWindSpeedTimeSeries
public void setWindSpeedTimeSeries(double[] windSpeeds) Set time-series wind speeds for dynamic simulation.- Parameters:
windSpeeds- array of wind speeds [m/s], one per time step
-
getPowerTimeSeries
public double[] getPowerTimeSeries()Get time-series power output after running dynamic simulation.- Returns:
- array of power outputs [W]
-
runTimeSeries
public void runTimeSeries()Run the full time series and populate powerTimeSeries array. -
run
In this method all thermodynamic and unit operations will be calculated in a steady state calculation.
- Parameters:
id- UUID
-
getPower
public double getPower()Get total farm power output [W].- Returns:
- power [W]
-
getPower
Get total farm power output in specified unit.- Parameters:
unit- unit string: "W", "kW", "MW", "GW"- Returns:
- power in specified unit
-
getCapacityFactor
public double getCapacityFactor()Get calculated capacity factor.- Returns:
- capacity factor [0-1]
-
getTotalRatedPower
public double getTotalRatedPower()Get total rated farm capacity [W].- Returns:
- total rated power [W]
-
setNumberOfTurbines
public void setNumberOfTurbines(int n) Set number of turbines.- Parameters:
n- number of turbines
-
getNumberOfTurbines
public int getNumberOfTurbines()Get number of turbines.- Returns:
- number of turbines
-
setRatedPowerPerTurbine
public void setRatedPowerPerTurbine(double ratedPower) Set rated power per turbine [W].- Parameters:
ratedPower- rated power [W]
-
getRatedPowerPerTurbine
public double getRatedPowerPerTurbine()Get rated power per turbine [W].- Returns:
- rated power [W]
-
setRotorDiameter
public void setRotorDiameter(double diameter) Set rotor diameter [m].- Parameters:
diameter- rotor diameter [m]
-
getRotorDiameter
public double getRotorDiameter()Get rotor diameter [m].- Returns:
- rotor diameter [m]
-
setHubHeight
public void setHubHeight(double height) Set hub height [m].- Parameters:
height- hub height [m]
-
getHubHeight
public double getHubHeight()Get hub height [m].- Returns:
- hub height [m]
-
setWindSpeed
public void setWindSpeed(double speed) Set current wind speed at hub height [m/s].- Parameters:
speed- wind speed [m/s]
-
getWindSpeed
public double getWindSpeed()Get current wind speed [m/s].- Returns:
- wind speed [m/s]
-
setCutInSpeed
public void setCutInSpeed(double cutIn) Set cut-in wind speed [m/s].- Parameters:
cutIn- cut-in speed [m/s]
-
getCutInSpeed
public double getCutInSpeed()Get cut-in wind speed [m/s].- Returns:
- cut-in speed [m/s]
-
setRatedSpeed
public void setRatedSpeed(double rated) Set rated wind speed [m/s].- Parameters:
rated- rated speed [m/s]
-
getRatedSpeed
public double getRatedSpeed()Get rated wind speed [m/s].- Returns:
- rated speed [m/s]
-
setCutOutSpeed
public void setCutOutSpeed(double cutOut) Set cut-out wind speed [m/s].- Parameters:
cutOut- cut-out speed [m/s]
-
getCutOutSpeed
public double getCutOutSpeed()Get cut-out wind speed [m/s].- Returns:
- cut-out speed [m/s]
-
setAirTemperature
public void setAirTemperature(double temp) Set air temperature for density correction [C].- Parameters:
temp- air temperature [C]
-
setAtmosphericPressure
public void setAtmosphericPressure(double pressure) Set atmospheric pressure for density correction [Pa].- Parameters:
pressure- atmospheric pressure [Pa]
-
setWakeLossFactor
public void setWakeLossFactor(double factor) Set wake loss factor [0-1].- Parameters:
factor- wake loss factor
-
getWakeLossFactor
public double getWakeLossFactor()Get wake loss factor.- Returns:
- wake loss factor [0-1]
-
setAvailabilityFactor
public void setAvailabilityFactor(double factor) Set availability factor [0-1].- Parameters:
factor- availability factor
-
getAvailabilityFactor
public double getAvailabilityFactor()Get availability factor.- Returns:
- availability factor [0-1]
-
setElectricalLossFactor
public void setElectricalLossFactor(double factor) Set electrical loss factor [0-1].- Parameters:
factor- electrical loss factor
-
setWeibullShape
public void setWeibullShape(double shape) Set Weibull shape parameter for AEP calculation.- Parameters:
shape- Weibull shape parameter k [-]
-
setWeibullScale
public void setWeibullScale(double scale) Set Weibull scale parameter for AEP calculation.- Parameters:
scale- Weibull scale parameter c [m/s]
-
getWeibullShape
public double getWeibullShape()Get Weibull shape parameter.- Returns:
- shape parameter [-]
-
getWeibullScale
public double getWeibullScale()Get Weibull scale parameter.- Returns:
- scale parameter [m/s]
-
setMaxPowerCoefficient
public void setMaxPowerCoefficient(double cp) Set max power coefficient (Cp).- Parameters:
cp- power coefficient [-]
-
getAirDensity
public double getAirDensity()Get current air density [kg/m3].- Returns:
- air density
-
getRotorArea
public double getRotorArea()Get rotor swept area [m2].- Returns:
- swept area
-
getCurrentTimeStep
public int getCurrentTimeStep()Get current time step index.- Returns:
- time step index
-