Struct Power
- Namespace
- UnitsNet
- Assembly
- UnitsNet.Power.dll
In physics, power is the rate of doing work. It is equivalent to an amount of energy consumed per unit time.
public struct PowerConstructors
Power(double, PowerUnit)
Creates the quantity with the given numeric value and unit.
public Power(double value, PowerUnit unit)Parameters
- valuedouble
- The numeric value to construct this quantity with. 
- unitPowerUnit
- The unit representation to construct this quantity with. 
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
Properties
BaseUnit
The base unit of Power, which is Second. All conversions go via this value.
public static PowerUnit BaseUnit { get; }Property Value
BoilerHorsepower
Gets a double value of this quantity converted into BoilerHorsepower
public double BoilerHorsepower { get; }Property Value
BritishThermalUnitsPerHour
Gets a double value of this quantity converted into BritishThermalUnitPerHour
public double BritishThermalUnitsPerHour { get; }Property Value
Decawatts
public double Decawatts { get; }Property Value
Deciwatts
public double Deciwatts { get; }Property Value
ElectricalHorsepower
Gets a double value of this quantity converted into ElectricalHorsepower
public double ElectricalHorsepower { get; }Property Value
Femtowatts
public double Femtowatts { get; }Property Value
GigajoulesPerHour
Gets a double value of this quantity converted into GigajoulePerHour
public double GigajoulesPerHour { get; }Property Value
Gigawatts
public double Gigawatts { get; }Property Value
HydraulicHorsepower
Gets a double value of this quantity converted into HydraulicHorsepower
public double HydraulicHorsepower { get; }Property Value
JoulesPerHour
Gets a double value of this quantity converted into JoulePerHour
public double JoulesPerHour { get; }Property Value
KilobritishThermalUnitsPerHour
Gets a double value of this quantity converted into KilobritishThermalUnitPerHour
public double KilobritishThermalUnitsPerHour { get; }Property Value
KilojoulesPerHour
Gets a double value of this quantity converted into KilojoulePerHour
public double KilojoulesPerHour { get; }Property Value
Kilowatts
public double Kilowatts { get; }Property Value
MaxValue
Represents the largest possible value of Power.
public static Power MaxValue { get; }Property Value
MechanicalHorsepower
Gets a double value of this quantity converted into MechanicalHorsepower
public double MechanicalHorsepower { get; }Property Value
MegabritishThermalUnitsPerHour
Gets a double value of this quantity converted into MegabritishThermalUnitPerHour
public double MegabritishThermalUnitsPerHour { get; }Property Value
MegajoulesPerHour
Gets a double value of this quantity converted into MegajoulePerHour
public double MegajoulesPerHour { get; }Property Value
Megawatts
public double Megawatts { get; }Property Value
MetricHorsepower
Gets a double value of this quantity converted into MetricHorsepower
public double MetricHorsepower { get; }Property Value
Microwatts
public double Microwatts { get; }Property Value
MillijoulesPerHour
Gets a double value of this quantity converted into MillijoulePerHour
public double MillijoulesPerHour { get; }Property Value
Milliwatts
public double Milliwatts { get; }Property Value
MinValue
Represents the smallest possible value of Power.
public static Power MinValue { get; }Property Value
Nanowatts
public double Nanowatts { get; }Property Value
Petawatts
public double Petawatts { get; }Property Value
Picowatts
public double Picowatts { get; }Property Value
Terawatts
public double Terawatts { get; }Property Value
TonsOfRefrigeration
Gets a double value of this quantity converted into TonOfRefrigeration
public double TonsOfRefrigeration { get; }Property Value
Unit
public PowerUnit Unit { get; }Property Value
Value
The numeric value this quantity was constructed with.
public double Value { get; }Property Value
Watts
public double Watts { get; }Property Value
Zero
Gets an instance of this quantity with a value of 0 in the base unit Second.
public static Power Zero { get; }Property Value
Methods
As(PowerUnit)
Convert to the unit representation unit.
public double As(PowerUnit unit)Parameters
- unitPowerUnit
Returns
- double
- Value converted to the specified unit. 
From(double, PowerUnit)
public static Power From(double value, PowerUnit fromUnit)Parameters
Returns
- Power
- Power unit value. 
FromBoilerHorsepower(double)
Creates a Power from BoilerHorsepower.
public static Power FromBoilerHorsepower(double boilerhorsepower)Parameters
- boilerhorsepowerdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromBritishThermalUnitsPerHour(double)
Creates a Power from BritishThermalUnitPerHour.
public static Power FromBritishThermalUnitsPerHour(double britishthermalunitsperhour)Parameters
- britishthermalunitsperhourdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromDecawatts(double)
public static Power FromDecawatts(double decawatts)Parameters
- decawattsdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromDeciwatts(double)
public static Power FromDeciwatts(double deciwatts)Parameters
- deciwattsdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromElectricalHorsepower(double)
Creates a Power from ElectricalHorsepower.
public static Power FromElectricalHorsepower(double electricalhorsepower)Parameters
- electricalhorsepowerdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromFemtowatts(double)
public static Power FromFemtowatts(double femtowatts)Parameters
- femtowattsdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromGigajoulesPerHour(double)
Creates a Power from GigajoulePerHour.
public static Power FromGigajoulesPerHour(double gigajoulesperhour)Parameters
- gigajoulesperhourdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromGigawatts(double)
public static Power FromGigawatts(double gigawatts)Parameters
- gigawattsdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromHydraulicHorsepower(double)
Creates a Power from HydraulicHorsepower.
public static Power FromHydraulicHorsepower(double hydraulichorsepower)Parameters
- hydraulichorsepowerdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromJoulesPerHour(double)
Creates a Power from JoulePerHour.
public static Power FromJoulesPerHour(double joulesperhour)Parameters
- joulesperhourdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromKilobritishThermalUnitsPerHour(double)
Creates a Power from KilobritishThermalUnitPerHour.
public static Power FromKilobritishThermalUnitsPerHour(double kilobritishthermalunitsperhour)Parameters
- kilobritishthermalunitsperhourdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromKilojoulesPerHour(double)
Creates a Power from KilojoulePerHour.
public static Power FromKilojoulesPerHour(double kilojoulesperhour)Parameters
- kilojoulesperhourdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromKilowatts(double)
public static Power FromKilowatts(double kilowatts)Parameters
- kilowattsdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromMechanicalHorsepower(double)
Creates a Power from MechanicalHorsepower.
public static Power FromMechanicalHorsepower(double mechanicalhorsepower)Parameters
- mechanicalhorsepowerdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromMegabritishThermalUnitsPerHour(double)
Creates a Power from MegabritishThermalUnitPerHour.
public static Power FromMegabritishThermalUnitsPerHour(double megabritishthermalunitsperhour)Parameters
- megabritishthermalunitsperhourdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromMegajoulesPerHour(double)
Creates a Power from MegajoulePerHour.
public static Power FromMegajoulesPerHour(double megajoulesperhour)Parameters
- megajoulesperhourdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromMegawatts(double)
public static Power FromMegawatts(double megawatts)Parameters
- megawattsdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromMetricHorsepower(double)
Creates a Power from MetricHorsepower.
public static Power FromMetricHorsepower(double metrichorsepower)Parameters
- metrichorsepowerdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromMicrowatts(double)
public static Power FromMicrowatts(double microwatts)Parameters
- microwattsdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromMillijoulesPerHour(double)
Creates a Power from MillijoulePerHour.
public static Power FromMillijoulesPerHour(double millijoulesperhour)Parameters
- millijoulesperhourdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromMilliwatts(double)
public static Power FromMilliwatts(double milliwatts)Parameters
- milliwattsdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromNanowatts(double)
public static Power FromNanowatts(double nanowatts)Parameters
- nanowattsdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromPetawatts(double)
public static Power FromPetawatts(double petawatts)Parameters
- petawattsdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromPicowatts(double)
public static Power FromPicowatts(double picowatts)Parameters
- picowattsdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromTerawatts(double)
public static Power FromTerawatts(double terawatts)Parameters
- terawattsdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromTonsOfRefrigeration(double)
Creates a Power from TonOfRefrigeration.
public static Power FromTonsOfRefrigeration(double tonsofrefrigeration)Parameters
- tonsofrefrigerationdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
FromWatts(double)
public static Power FromWatts(double watts)Parameters
- wattsdouble
Returns
Exceptions
- ArgumentException
- If value is NaN or Infinity. 
ToUnit(PowerUnit)
Converts this Power to another Power with the unit representation unit.
public Power ToUnit(PowerUnit unit)Parameters
- unitPowerUnit
Returns
- Power
- A Power with the specified unit.