00001
00002 #ifndef IMD_H__
00003 #define IMD_H__
00004
00005 #include <limits.h>
00006
00007 #if ( INT_MAX == 2147483647 )
00008 typedef int int32;
00009 #else
00010 typedef short int32;
00011 #endif
00012
00013 enum IMDType {
00014 IMD_DISCONNECT,
00015 IMD_ENERGIES,
00016 IMD_FCOORDS,
00017 IMD_GO,
00018 IMD_HANDSHAKE,
00019 IMD_KILL,
00020 IMD_MDCOMM,
00021 IMD_PAUSE,
00022 IMD_TRATE,
00023 IMD_IOERROR
00024 };
00025
00026 typedef struct {
00027 int32 tstep;
00028 float T;
00029 float Etot;
00030 float Epot;
00031 float Evdw;
00032 float Eelec;
00033 float Ebond;
00034 float Eangle;
00035 float Edihe;
00036 float Eimpr;
00037 } IMDEnergies;
00038
00039
00040 extern int imd_disconnect(void *);
00041 extern int imd_pause(void *);
00042 extern int imd_kill(void *);
00043 extern int imd_handshake(void *);
00044 extern int imd_trate(void *, int32);
00045
00046
00047 extern int imd_send_mdcomm(void *, int32, const int32 *, const float *);
00048 extern int imd_send_energies(void *, const IMDEnergies *);
00049 extern int imd_send_fcoords(void *, int32, const float *);
00050
00052
00053
00054
00055
00056 extern int imd_recv_handshake(void *);
00057
00058 extern IMDType imd_recv_header(void *, int32 *);
00059 extern int imd_recv_mdcomm(void *, int32, int32 *, float *);
00060 extern int imd_recv_energies(void *, IMDEnergies *);
00061 extern int imd_recv_fcoords(void *, int32, float *);
00062
00063 #endif
00064