chemistry.h File Reference

Go to the source code of this file.

Classes

struct  GcuValue
struct  GcuDimensionalValue
struct  GcuAtomicRadius
struct  GcuElectronegativity
struct  GcuIsotope

Defines

#define MAX_ELT   116

Enumerations

enum  gcu_spin_state
enum  gcu_radius_type

Functions

const gdouble * gcu_element_get_default_color (gint Z)
const gchar * gcu_element_get_symbol (gint Z)
const gchar * gcu_element_get_name (gint Z)
gint gcu_element_get_Z (gchar *symbol)
gboolean gcu_element_get_radius (GcuAtomicRadius *radius)
gboolean gcu_element_get_electronegativity (GcuElectronegativity *en)
GcuDimensionalValue const * gcu_element_get_ionization_energy (int Z, int N)
GcuDimensionalValue const * gcu_element_get_electron_affinity (int Z, int N)
const GcuAtomicRadius ** gcu_element_get_radii (gint Z)
const GcuElectronegativity ** gcu_element_get_electronegativities (gint Z)
void gcu_element_load_databases (char *name,...)
gchar * gcu_value_get_string (GcuValue const *value)
gchar * gcu_dimensional_value_get_string (GcuDimensionalValue const *value)


Detailed Description

C interface to the chemistry library.

To use this file, add the following line to your source file:

#include <gcu/chemistry.h>

Definition in file chemistry.h.


Enumeration Type Documentation

enum gcu_radius_type

gcu_radius_type gcu_radius_type describes the type of the atomic radius Possible values are:

This enumeration is used in the GcuAtomicRadius structure.

Definition at line 87 of file chemistry.h.

enum gcu_spin_state

gcu_spin_state gcu_spin_state describes the spin state of a central atom in a complex. Possible values are:

This enumeration is used in the GcuAtomicRadius structure.

Definition at line 68 of file chemistry.h.


Function Documentation

gchar* gcu_dimensional_value_get_string ( GcuDimensionalValue const *  value  ) 

Parameters:
value,: the GcuDimensionalValue to represent as a string.
Returns:
the GcuDimensionalValue as a string taking into account the precision and incertitude

const gdouble* gcu_element_get_default_color ( gint  Z  ) 

Parameters:
Z,: the atomic number of the element.
Retreives the default color used for the element.
Returns:
an array of three double values for the red, green and blue components of the color.

GcuDimensionalValue const* gcu_element_get_electron_affinity ( int  Z,
int  N 
)

Parameters:
Z,: the atomic number.
N,: the rank of the extra electron.
For some elements, second and even third electron affinities have been estimated. The program searches the Nth electron affinity value for the element and returns it if found. A value of 0 means that the anion is unstable in the gaseous phase and that no better etimation is available.

Returns:
the electronic affinity as a GcuDimensionalValue if known or NULL.

const GcuElectronegativity** gcu_element_get_electronegativities ( gint  Z  ) 

Parameters:
Z,: the atomic number of the element.
Returns:
a pointer to the array of pointers to GcuElectronegativity structures for all known electronegativities for the element. Last value in the array is NULL.

gboolean gcu_element_get_electronegativity ( GcuElectronegativity en  ) 

Parameters:
en,: a pointer to a GcuElectronegativity structure.
Before calling this function, the following fields in the GcuElectronegativity structure must be filled:

The programs searches an electronegativity value for the element in the scale if given. If one is found the value and the scale (if NULL on calling) are given the corresponding values of the first match before returning.

Returns:
TRUE if a match has been found and FALSE if not.

GcuDimensionalValue const* gcu_element_get_ionization_energy ( int  Z,
int  N 
)

Parameters:
Z,: the atomic number.
N,: the rank of the ionization.
The program searches for the Nth ionization energy value for the element and returns it if found.

Returns:
the ionization energy as a GcuDimensionalValue if known or NULL.

const gchar* gcu_element_get_name ( gint  Z  ) 

Parameters:
Z,: the atomic number of the element.
Returns:
the name of the element in the current locale or in english if the current locale is not supported in the database.

const GcuAtomicRadius** gcu_element_get_radii ( gint  Z  ) 

Parameters:
Z,: the atomic number of the element.
Returns:
a pointer to the array of pointers to GcuAtomicRadius structures for all known radii for the element. Last value in the array is NULL.

gboolean gcu_element_get_radius ( GcuAtomicRadius radius  ) 

Parameters:
radius,: a pointer to a GcuAtomicRadius structure.
Before calling this function, most fields in the GcuAtomicRadius structure must be filled:

The programs searches a value corresponding to the fields having a non default value. If one is found the other fields are given the corresponding values f the first match before returning.

Returns:
TRUE if a radius has been found and FALSE if not.

const gchar* gcu_element_get_symbol ( gint  Z  ) 

gcu_element_get_symbol:

Parameters:
Z,: the atomic number of the element.
Returns:
the symbol of the element.

gint gcu_element_get_Z ( gchar *  symbol  ) 

gcu_element_get_Z:

Parameters:
symbol,: the symbol of the element (e.g. "C" ot "Pt").
Returns:
the atomic number of the element.

void gcu_element_load_databases ( char *  name,
  ... 
)

Parameters:
name,: name of a database to load such as "radii", "elecprops", "isotopes", the first name is followed by a list of other database terminated by NULL.
Loads the listed databases.

Referenced by main().

gchar* gcu_value_get_string ( GcuValue const *  value  ) 

Parameters:
value,: the GcuValue to represent as a string.
Returns:
the GcuValue as a string taking into account the precision and incertitude


Generated on Tue Aug 15 10:47:35 2006 for The Gnome Chemistry Utils by  doxygen 1.4.7