Logo Search packages:      
Sourcecode: kalzium version File versions  Download package

Public Slots | Public Member Functions | Protected Slots | Protected Member Functions | Private Member Functions | Private Attributes

gasCalculator Class Reference

#include <gasCalculator.h>

List of all members.

Public Slots

void calculate ()
void calculate ()
 This function is called when any quantity is changed.
void calculateMass ()
 Calculates the mass of substance.
void calculateMass ()
 Calculates the mass of substance and updates the UI.
void calculateMolarMass ()
 Calculates the molar mass of the substance and updates the UI.
void calculateMolarMass ()
 Calculates the molar mass of the substance.
void calculateMoles ()
 Calculates the number of moles.
void calculateMoles ()
 Calculates the number of moles and updates the UI.
void calculatePressure ()
 Calculates the Pressure and updates the UI.
void calculatePressure ()
 Calculates the Pressure.
void calculateTemp ()
 Calculates the Temperature and updates the UI.
void calculateTemp ()
 Calculates the Temperature.
void calculateVol ()
 Calculates the Volume.
void calculateVol ()
 Calculates the Volume and updates the UI.
void configChanged ()
void error (int)
void error (int)
void init ()
void massChanged ()
 occurs when the mass is changed
void massChanged ()
 This function is called when the mass is changed.
void molarMassChanged (int value)
void molarMassChanged (double value)
void molesChanged (double value)
void molesChanged (int value)
void pressureChanged ()
 occurs when the pressure is changed
void pressureChanged ()
 This function is called when the pressure is changed.
void reset ()
void setMode (int)
void setMode (int mode)
void tempChanged ()
 occurs when the temperature is changed
void tempChanged ()
 This function is called when the temperature is changed.
void Vand_aChanged ()
 This function is called when Vander Val's constant a is changed.
void Vand_aChanged ()
void Vand_bChanged ()
void Vand_bChanged ()
 This function is called when Vander Val's constant b is changed.
void volChanged ()
void volChanged ()
 occurs when the volume is changed

Public Member Functions

 gasCalculator (QObject *parent, const QVariantList &args)
 gasCalculator (QWidget *parent=0)
virtual QGraphicsWidget * graphicsWidget ()
virtual void init ()

Protected Slots

void gasConfigAccepted ()

Protected Member Functions

void createConfigurationInterface (KConfigDialog *parent)

Private Member Functions

int getCurrentUnitId (QComboBox *comboBox)
void populateUnitCombobox (QComboBox *comboBox, const QList< int > &unitList)
void setupUnitComboboxes ()

Private Attributes

Plasma::ComboBox * m_aUnit
Plasma::ComboBox * m_bUnit
Plasma::ComboBox * m_calculationMode
bool m_configUpdated
Converter * m_converter
Plasma::Label * m_error
bool m_ideal
Value m_mass
Value m_Mass
Plasma::SpinBox * m_mass
Plasma::ComboBox * m_massUnit
int m_mode
double m_molarMass
double m_MolarMass
Plasma::SpinBox * m_molarMass
double m_moles
double m_Moles
Plasma::SpinBox * m_moles
Value m_pressure
Value m_Pressure
Plasma::SpinBox * m_pressure
Plasma::ComboBox * m_pressureUnit
Plasma::PushButton * m_reset
Value m_temp
Value m_Temp
Plasma::SpinBox * m_temperature
Plasma::ComboBox * m_temperatureUnit
Plasma::SpinBox * m_Vand_a
double m_Vand_A
double m_Vand_a
Value m_Vand_B
Value m_Vand_b
Plasma::SpinBox * m_Vand_b
Value m_vol
Value m_Vol
Plasma::SpinBox * m_volume
Plasma::ComboBox * m_volumeUnit
QGraphicsWidget * m_widget
Ui::gasCalculatorConfig ui
 Designer Config file.
Ui::gasCalculator ui

Detailed Description

This class implements the gas calculator. It performs basic calculations like calculation of volume given pressure, temerature, amount etc. and so on.

Van der Val's gas equation ( P + n^2 a / V^2) ( V - nb ) = nRT

where P - pressure V - Volume n - number of moles R - Universal gas constant T - temperature

a,b - Van der Val's constants

Kashyap R Puranik

Definition at line 46 of file gasCalculator.h.

The documentation for this class was generated from the following files:

Generated by  Doxygen 1.6.0   Back to index