Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

chemistry.h

Go to the documentation of this file.
00001 // -*- C -*-
00002 
00003 /* 
00004  * Gnome Chemisty Utils
00005  * chemistry.h 
00006  *
00007  * Copyright (C) 2003-2004
00008  *
00009  * Developed by Jean Bréfort <jean.brefort@normalesup.org>
00010  *
00011  * This library is free software; you can redistribute it and/or
00012  * modify it under the terms of the GNU Lesser General Public
00013  * License as published by the Free Software Foundation; either
00014  * version 2.1 of the License, or (at your option) any later version.
00015  *
00016  * This library is distributed in the hope that it will be useful,
00017  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00018  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00019  * Lesser General Public License for more details.
00020  *
00021  * You should have received a copy of the GNU Lesser General Public
00022  * License along with this library; if not, write to the 
00023  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
00024  * Boston, MA  02111-1307, USA.
00025  */
00026 
00027 
00042 #ifndef GCU_CHEMISTRY_H
00043 #define GCU_CHEMISTRY_H
00044 
00045 #include <glib.h>
00046 
00056 G_BEGIN_DECLS
00057 
00067 enum gcu_spin_state
00068 {
00069         GCU_N_A_SPIN,
00070         GCU_LOW_SPIN,
00071         GCU_HIGH_SPIN
00072 };
00073 
00086 enum gcu_radius_type
00087 {
00088         GCU_RADIUS_UNKNOWN,
00089         GCU_ATOMIC,
00090         GCU_IONIC,
00091         GCU_METALLIC,
00092         GCU_COVALENT,
00093         GCU_VAN_DER_WAALS
00094 };
00095 
00099 typedef struct
00100 {
00102         double value;
00104         int prec;
00106         int delta;
00107 } GcuValue;
00108 
00112 typedef struct
00113 {
00115         double value;
00117         int prec;
00119         int delta;
00121         char *unit;
00122 } GcuDimensionalValue;
00123 
00127 typedef struct
00128 {
00130         unsigned char Z;
00132         enum gcu_radius_type type;
00134         GcuValue value;
00136         char charge;
00138         char* scale;
00140         char cn;        //coordination number: -1: unspecified
00142         enum gcu_spin_state spin;
00143 } GcuAtomicRadius;
00144 
00148 typedef struct
00149 {
00151         unsigned char Z;
00153         GcuValue value;
00155         char* scale;
00156 } GcuElectronegativity;
00157 
00161 typedef struct
00162 {
00164         unsigned char A;
00166         char *name;
00168         GcuValue abundance;
00170         GcuValue mass;
00172         char spin;
00174         char *decay_modes;
00176         GcuDimensionalValue decay_period;
00177 } GcuIsotope;
00178 
00179 
00186 const gdouble* gcu_element_get_default_color (gint Z);
00192 const gchar* gcu_element_get_symbol (gint Z);
00197 const gchar* gcu_element_get_name (gint Z);
00203 gint gcu_element_get_Z (gchar* symbol);
00221 gboolean gcu_element_get_radius (GcuAtomicRadius* radius);
00234 gboolean gcu_element_get_electronegativity (GcuElectronegativity* en);
00241 const GcuAtomicRadius** gcu_element_get_radii (gint Z);
00248 const GcuElectronegativity** gcu_element_get_electronegativities (gint Z);
00255 void gcu_element_load_databases (char* name, ...);
00256 
00257 G_END_DECLS
00258 
00259 #endif //GCU_CHEMISTRY_H

Generated on Thu Sep 8 10:36:39 2005 for The Gnome Chemistry Utils by  doxygen 1.4.1