--- trunk/tcProps/tcProps.c 2004/02/19 21:10:06 1060 +++ trunk/tcProps/tcProps.c 2004/02/28 16:45:57 1073 @@ -10,6 +10,8 @@ #include "readWrite.h" #include "scdCorr.h" #include "directorHead.h" +#include "directorWhole.h" +#include "rmsd.h" #define VERSION_MAJOR 0 @@ -46,7 +48,8 @@ int main( int argC, char *argV[] ){ int scdCorr; double startTime; double maxLength; - int directorHead; + int directorHead, directorWhole, doRMSD; + enum atomNames rmsdType; // system initialization @@ -65,6 +68,8 @@ int main( int argC, char *argV[] ){ scdCorr = 0; startTime = 0.0; directorHead = 0; + directorWhole = 0; + doRMSD = 0; // parse the command line @@ -81,27 +86,31 @@ int main( int argC, char *argV[] ){ // parse long word options - if( !strcmp( argV[i], "--gofr" ) ){ + if( !strcmp( argV[i], "--rmsd" ) ){ + doRMSD = 1; i++; if( i>=argC ){ fprintf( stderr, "\n" - "not enough arguments for --gofr\n"); + "not enough arguments for --rmsd\n"); usage(); exit(0); } pair1 = argV[i]; - i++; - if( i>=argC ){ - fprintf( stderr, - "\n" - "not enough arguments for --gofr\n"); - usage(); + if( !strcmp(pair1, "HEAD") ) rmsdType = HEAD; + else if( !strcmp(pair1, "CH") ) rmsdType = CH; + else if( !strcmp(pair1, "CH2") )rmsdType = CH2; + else if( !strcmp(pair1, "CH3") )rmsdType = CH3; + else if( !strcmp(pair1, "SSD") )rmsdType = SSD; + else if( !strcmp(pair1, "COM") )rmsdType = COM; + else{ + fprintf( stderr, + "Unrecognized rmsd atom type \"%s\"\n", + pair1 ); exit(0); - } - pair2 = argV[i]; + } } @@ -306,6 +315,12 @@ int main( int argC, char *argV[] ){ // -h turn on director head directorHead = 1; + break; + + case 'w': + // -h turn on director head + + directorWhole = 1; break; @@ -356,50 +371,71 @@ int main( int argC, char *argV[] ){ for(i=0;i set the maximum value of r\n" " *Defaults to 1/2 smallest length of first frame.\n" " -s Calculate the Scd chain correlation.\n" + " -h Calculate the directors for the head groups\n" + " -w Calculate the director fro the bilayers\n" "\n" " long:\n" " -----\n" - " --gofr g(r) for atom1 and atom2\n" + " --rmsd rmsd for atom1\n" " --gofrTheta g(r, theta) for atom1 and atom2\n" " --gofrOmega g(r, omega) for atom1 and atom2\n" " --version displays the version number\n"