Class IdealGas
java.lang.Object
org.episteme.natural.physics.classical.thermodynamics.IdealGas
- All Implemented Interfaces:
ThermodynamicState
Represents an ideal gas following the law PV = nRT.
Uses type-safe Quantity classes and Real arithmetic for all physical properties.
- Since:
- 1.0
- Author:
- Silvere Martin-Michiellot, Gemini AI (Google DeepMind)
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns amount of substance in moles.Enthalpy ($H = U + PV$).Returns the entropy of this state.Internal energy ($U$).Returns the pressure of this state.Returns the temperature of this state.Returns the volume of this state.voidsetTemperatureIsobaric(Real newT) Sets temperature (isobaric) using Real.voidIsobaric expansion/compression (Pressure constant).voidsetTemperatureIsochoric(Real newT) Sets temperature (isochoric) using Real.voidIsochoric heating/cooling (Volume constant).
-
Constructor Details
-
IdealGas
Creates an ideal gas with specified moles, temperature, and volume. Pressure is calculated using PV = nRT.- Parameters:
moles- amount of substance in molestemperature- initial temperaturevolume- initial volume
-
IdealGas
-
-
Method Details
-
getTemperature
Description copied from interface:ThermodynamicStateReturns the temperature of this state.- Specified by:
getTemperaturein interfaceThermodynamicState- Returns:
- temperature in standard units (Kelvin)
-
getPressure
Description copied from interface:ThermodynamicStateReturns the pressure of this state.- Specified by:
getPressurein interfaceThermodynamicState- Returns:
- pressure in standard units (Pascal)
-
getVolume
Description copied from interface:ThermodynamicStateReturns the volume of this state.- Specified by:
getVolumein interfaceThermodynamicState- Returns:
- volume in standard units (cubic meters)
-
getInternalEnergy
Description copied from interface:ThermodynamicStateInternal energy ($U$).- Specified by:
getInternalEnergyin interfaceThermodynamicState- Returns:
- internal energy in standard units (Joules)
-
getEntropy
Description copied from interface:ThermodynamicStateReturns the entropy of this state.- Specified by:
getEntropyin interfaceThermodynamicState- Returns:
- entropy (J/K)
-
getEnthalpy
Description copied from interface:ThermodynamicStateEnthalpy ($H = U + PV$).- Specified by:
getEnthalpyin interfaceThermodynamicState- Returns:
- enthalpy in standard units (Joules)
-
setTemperatureIsochoric
Isochoric heating/cooling (Volume constant).- Parameters:
newT- new temperature
-
setTemperatureIsobaric
Isobaric expansion/compression (Pressure constant).- Parameters:
newT- new temperature
-
setTemperatureIsochoric
Sets temperature (isochoric) using Real. -
setTemperatureIsobaric
Sets temperature (isobaric) using Real. -
getAmountOfSubstance
Returns amount of substance in moles.
-