21 |
|
#define FIX_UNUSED(X) (void) (X) /* avoid warnings for unused params */ |
22 |
|
#endif |
23 |
|
|
24 |
+ |
#ifdef WIN32 |
25 |
+ |
#include "utils/wingetopt.h" |
26 |
+ |
#else |
27 |
|
#include <getopt.h> |
28 |
+ |
#endif |
29 |
|
|
30 |
|
#include "StaticPropsCmd.h" |
31 |
|
|
47 |
|
" --nbins_z=INT number of bins in z axis (default=`100')", |
48 |
|
" -a, --nanglebins=INT number of bins for cos(angle) (default=`50')", |
49 |
|
" -c, --rcut=DOUBLE cutoff radius (rcut)", |
50 |
+ |
" --thetacut=DOUBLE cutoff angle (thetacut)", |
51 |
|
" --dz=DOUBLE slab width (dz)", |
52 |
|
" --length=DOUBLE maximum length (Defaults to 1/2 smallest length \n of first frame)", |
53 |
|
" --zlength=DOUBLE maximum length (Defaults to 1/2 smallest length \n of first frame)", |
58 |
|
" --refsele=selection script\n select reference (use and only use with --gxyz)", |
59 |
|
" --comsele=selection script\n select stunt doubles for center-of-mass \n reference point", |
60 |
|
" --seleoffset=INT global index offset for a second object (used \n to define a vector between sites in molecule)", |
61 |
+ |
" --seleoffset2=INT global index offset for a third object (used to \n define a vector between sites in molecule)", |
62 |
|
" --molname=STRING molecule name", |
63 |
|
" --begin=INT begin internal index", |
64 |
|
" --end=INT end internal index", |
65 |
|
" --radius=DOUBLE nanoparticle radius", |
66 |
+ |
" -v, --voxelSize=DOUBLE voxel size (angstroms)", |
67 |
+ |
" --gaussWidth=DOUBLE Gaussian width (angstroms)", |
68 |
|
"\n Group: staticProps\n an option of this group is required", |
69 |
|
" --bo bond order parameter (--rcut must be specified)", |
70 |
< |
" --bor bond order parameter as a function of radius \n (--rcut must be specified)", |
70 |
> |
" --ior icosahedral bond order parameter as a function \n of radius (--rcut must be specified)", |
71 |
> |
" --for FCC bond order parameter as a function of \n radius (--rcut must be specified)", |
72 |
|
" --bad N(theta) bond angle density within (--rcut must \n be specified)", |
73 |
|
" --count count of molecules matching selection criteria \n (and associated statistics)", |
74 |
|
" -g, --gofr g(r)", |
84 |
|
" -s, --scd scd order parameter (either --sele1, --sele2, \n --sele3 are specified or --molname, --begin, \n --end are specified)", |
85 |
|
" -d, --density density plot", |
86 |
|
" --slab_density slab density", |
87 |
< |
" --p_angle p(cos(theta))", |
87 |
> |
" --p_angle p(cos(theta)) (--sele1 must be specified, \n --sele2 is optional)", |
88 |
|
" --hxy hxy", |
89 |
|
" --rho_r rho of R", |
90 |
|
" --angle_r angle of R", |
91 |
|
" --hullvol hull volume of nanoparticle", |
92 |
|
" --rodlength length of nanorod", |
93 |
< |
" -Q, --tet_param tetrahedrality order parameter", |
94 |
< |
" --tet_param_z tetrahedrality order parameter by zbin(--sele1 \n must be specified)", |
93 |
> |
" -Q, --tet_param tetrahedrality order parameter (Qk)", |
94 |
> |
" --tet_param_z spatially-resolved tetrahedrality order \n parameter Qk(z)", |
95 |
> |
" --tet_param_xyz volume-resolved tetrahedrality order parameter \n Qk(x,y,z). (voxelSize, rcut, and gaussWidth \n must be specified)", |
96 |
> |
" --rnemdz slab-resolved RNEMD statistics (temperature, \n density, velocity)", |
97 |
> |
" --rnemdr shell-resolved RNEMD statistics (temperature, \n density, angular velocity)", |
98 |
> |
" --rnemdrt shell and angle-resolved RNEMD statistics \n (temperature, density, angular velocity)", |
99 |
> |
" --nitrile electrostatic potential to frequency map based \n on the Cho nitrile fits", |
100 |
> |
" -m, --multipole average multipole moments contained within \n cutoff spheres as a function of radius", |
101 |
> |
" --surfDiffusion X, Y, and R (surface diffusion if Z exposed and \n bulk immobile) diffusion", |
102 |
> |
" --hbond Hydrogen Bonding statistics using geometric \n criteria (rcut and thetacut must be \n specified)", |
103 |
|
0 |
104 |
|
}; |
105 |
|
|
138 |
|
args_info->nbins_z_given = 0 ; |
139 |
|
args_info->nanglebins_given = 0 ; |
140 |
|
args_info->rcut_given = 0 ; |
141 |
+ |
args_info->thetacut_given = 0 ; |
142 |
|
args_info->dz_given = 0 ; |
143 |
|
args_info->length_given = 0 ; |
144 |
|
args_info->zlength_given = 0 ; |
149 |
|
args_info->refsele_given = 0 ; |
150 |
|
args_info->comsele_given = 0 ; |
151 |
|
args_info->seleoffset_given = 0 ; |
152 |
+ |
args_info->seleoffset2_given = 0 ; |
153 |
|
args_info->molname_given = 0 ; |
154 |
|
args_info->begin_given = 0 ; |
155 |
|
args_info->end_given = 0 ; |
156 |
|
args_info->radius_given = 0 ; |
157 |
+ |
args_info->voxelSize_given = 0 ; |
158 |
+ |
args_info->gaussWidth_given = 0 ; |
159 |
|
args_info->bo_given = 0 ; |
160 |
< |
args_info->bor_given = 0 ; |
160 |
> |
args_info->ior_given = 0 ; |
161 |
> |
args_info->for_given = 0 ; |
162 |
|
args_info->bad_given = 0 ; |
163 |
|
args_info->count_given = 0 ; |
164 |
|
args_info->gofr_given = 0 ; |
182 |
|
args_info->rodlength_given = 0 ; |
183 |
|
args_info->tet_param_given = 0 ; |
184 |
|
args_info->tet_param_z_given = 0 ; |
185 |
+ |
args_info->tet_param_xyz_given = 0 ; |
186 |
+ |
args_info->rnemdz_given = 0 ; |
187 |
+ |
args_info->rnemdr_given = 0 ; |
188 |
+ |
args_info->rnemdrt_given = 0 ; |
189 |
+ |
args_info->nitrile_given = 0 ; |
190 |
+ |
args_info->multipole_given = 0 ; |
191 |
+ |
args_info->surfDiffusion_given = 0 ; |
192 |
+ |
args_info->hbond_given = 0 ; |
193 |
|
args_info->staticProps_group_counter = 0 ; |
194 |
|
} |
195 |
|
|
214 |
|
args_info->nanglebins_arg = 50; |
215 |
|
args_info->nanglebins_orig = NULL; |
216 |
|
args_info->rcut_orig = NULL; |
217 |
+ |
args_info->thetacut_orig = NULL; |
218 |
|
args_info->dz_orig = NULL; |
219 |
|
args_info->length_orig = NULL; |
220 |
|
args_info->zlength_orig = NULL; |
231 |
|
args_info->comsele_arg = NULL; |
232 |
|
args_info->comsele_orig = NULL; |
233 |
|
args_info->seleoffset_orig = NULL; |
234 |
+ |
args_info->seleoffset2_orig = NULL; |
235 |
|
args_info->molname_arg = NULL; |
236 |
|
args_info->molname_orig = NULL; |
237 |
|
args_info->begin_orig = NULL; |
238 |
|
args_info->end_orig = NULL; |
239 |
|
args_info->radius_orig = NULL; |
240 |
+ |
args_info->voxelSize_orig = NULL; |
241 |
+ |
args_info->gaussWidth_orig = NULL; |
242 |
|
|
243 |
|
} |
244 |
|
|
258 |
|
args_info->nbins_z_help = gengetopt_args_info_help[8] ; |
259 |
|
args_info->nanglebins_help = gengetopt_args_info_help[9] ; |
260 |
|
args_info->rcut_help = gengetopt_args_info_help[10] ; |
261 |
< |
args_info->dz_help = gengetopt_args_info_help[11] ; |
262 |
< |
args_info->length_help = gengetopt_args_info_help[12] ; |
263 |
< |
args_info->zlength_help = gengetopt_args_info_help[13] ; |
264 |
< |
args_info->zoffset_help = gengetopt_args_info_help[14] ; |
265 |
< |
args_info->sele1_help = gengetopt_args_info_help[15] ; |
266 |
< |
args_info->sele2_help = gengetopt_args_info_help[16] ; |
267 |
< |
args_info->sele3_help = gengetopt_args_info_help[17] ; |
268 |
< |
args_info->refsele_help = gengetopt_args_info_help[18] ; |
269 |
< |
args_info->comsele_help = gengetopt_args_info_help[19] ; |
270 |
< |
args_info->seleoffset_help = gengetopt_args_info_help[20] ; |
271 |
< |
args_info->molname_help = gengetopt_args_info_help[21] ; |
272 |
< |
args_info->begin_help = gengetopt_args_info_help[22] ; |
273 |
< |
args_info->end_help = gengetopt_args_info_help[23] ; |
274 |
< |
args_info->radius_help = gengetopt_args_info_help[24] ; |
275 |
< |
args_info->bo_help = gengetopt_args_info_help[26] ; |
276 |
< |
args_info->bor_help = gengetopt_args_info_help[27] ; |
277 |
< |
args_info->bad_help = gengetopt_args_info_help[28] ; |
278 |
< |
args_info->count_help = gengetopt_args_info_help[29] ; |
279 |
< |
args_info->gofr_help = gengetopt_args_info_help[30] ; |
280 |
< |
args_info->gofz_help = gengetopt_args_info_help[31] ; |
281 |
< |
args_info->r_theta_help = gengetopt_args_info_help[32] ; |
282 |
< |
args_info->r_omega_help = gengetopt_args_info_help[33] ; |
283 |
< |
args_info->r_z_help = gengetopt_args_info_help[34] ; |
284 |
< |
args_info->theta_omega_help = gengetopt_args_info_help[35] ; |
285 |
< |
args_info->gxyz_help = gengetopt_args_info_help[36] ; |
286 |
< |
args_info->twodgofr_help = gengetopt_args_info_help[37] ; |
287 |
< |
args_info->p2_help = gengetopt_args_info_help[38] ; |
288 |
< |
args_info->rp2_help = gengetopt_args_info_help[39] ; |
289 |
< |
args_info->scd_help = gengetopt_args_info_help[40] ; |
290 |
< |
args_info->density_help = gengetopt_args_info_help[41] ; |
291 |
< |
args_info->slab_density_help = gengetopt_args_info_help[42] ; |
292 |
< |
args_info->p_angle_help = gengetopt_args_info_help[43] ; |
293 |
< |
args_info->hxy_help = gengetopt_args_info_help[44] ; |
294 |
< |
args_info->rho_r_help = gengetopt_args_info_help[45] ; |
295 |
< |
args_info->angle_r_help = gengetopt_args_info_help[46] ; |
296 |
< |
args_info->hullvol_help = gengetopt_args_info_help[47] ; |
297 |
< |
args_info->rodlength_help = gengetopt_args_info_help[48] ; |
298 |
< |
args_info->tet_param_help = gengetopt_args_info_help[49] ; |
299 |
< |
args_info->tet_param_z_help = gengetopt_args_info_help[50] ; |
261 |
> |
args_info->thetacut_help = gengetopt_args_info_help[11] ; |
262 |
> |
args_info->dz_help = gengetopt_args_info_help[12] ; |
263 |
> |
args_info->length_help = gengetopt_args_info_help[13] ; |
264 |
> |
args_info->zlength_help = gengetopt_args_info_help[14] ; |
265 |
> |
args_info->zoffset_help = gengetopt_args_info_help[15] ; |
266 |
> |
args_info->sele1_help = gengetopt_args_info_help[16] ; |
267 |
> |
args_info->sele2_help = gengetopt_args_info_help[17] ; |
268 |
> |
args_info->sele3_help = gengetopt_args_info_help[18] ; |
269 |
> |
args_info->refsele_help = gengetopt_args_info_help[19] ; |
270 |
> |
args_info->comsele_help = gengetopt_args_info_help[20] ; |
271 |
> |
args_info->seleoffset_help = gengetopt_args_info_help[21] ; |
272 |
> |
args_info->seleoffset2_help = gengetopt_args_info_help[22] ; |
273 |
> |
args_info->molname_help = gengetopt_args_info_help[23] ; |
274 |
> |
args_info->begin_help = gengetopt_args_info_help[24] ; |
275 |
> |
args_info->end_help = gengetopt_args_info_help[25] ; |
276 |
> |
args_info->radius_help = gengetopt_args_info_help[26] ; |
277 |
> |
args_info->voxelSize_help = gengetopt_args_info_help[27] ; |
278 |
> |
args_info->gaussWidth_help = gengetopt_args_info_help[28] ; |
279 |
> |
args_info->bo_help = gengetopt_args_info_help[30] ; |
280 |
> |
args_info->ior_help = gengetopt_args_info_help[31] ; |
281 |
> |
args_info->for_help = gengetopt_args_info_help[32] ; |
282 |
> |
args_info->bad_help = gengetopt_args_info_help[33] ; |
283 |
> |
args_info->count_help = gengetopt_args_info_help[34] ; |
284 |
> |
args_info->gofr_help = gengetopt_args_info_help[35] ; |
285 |
> |
args_info->gofz_help = gengetopt_args_info_help[36] ; |
286 |
> |
args_info->r_theta_help = gengetopt_args_info_help[37] ; |
287 |
> |
args_info->r_omega_help = gengetopt_args_info_help[38] ; |
288 |
> |
args_info->r_z_help = gengetopt_args_info_help[39] ; |
289 |
> |
args_info->theta_omega_help = gengetopt_args_info_help[40] ; |
290 |
> |
args_info->gxyz_help = gengetopt_args_info_help[41] ; |
291 |
> |
args_info->twodgofr_help = gengetopt_args_info_help[42] ; |
292 |
> |
args_info->p2_help = gengetopt_args_info_help[43] ; |
293 |
> |
args_info->rp2_help = gengetopt_args_info_help[44] ; |
294 |
> |
args_info->scd_help = gengetopt_args_info_help[45] ; |
295 |
> |
args_info->density_help = gengetopt_args_info_help[46] ; |
296 |
> |
args_info->slab_density_help = gengetopt_args_info_help[47] ; |
297 |
> |
args_info->p_angle_help = gengetopt_args_info_help[48] ; |
298 |
> |
args_info->hxy_help = gengetopt_args_info_help[49] ; |
299 |
> |
args_info->rho_r_help = gengetopt_args_info_help[50] ; |
300 |
> |
args_info->angle_r_help = gengetopt_args_info_help[51] ; |
301 |
> |
args_info->hullvol_help = gengetopt_args_info_help[52] ; |
302 |
> |
args_info->rodlength_help = gengetopt_args_info_help[53] ; |
303 |
> |
args_info->tet_param_help = gengetopt_args_info_help[54] ; |
304 |
> |
args_info->tet_param_z_help = gengetopt_args_info_help[55] ; |
305 |
> |
args_info->tet_param_xyz_help = gengetopt_args_info_help[56] ; |
306 |
> |
args_info->rnemdz_help = gengetopt_args_info_help[57] ; |
307 |
> |
args_info->rnemdr_help = gengetopt_args_info_help[58] ; |
308 |
> |
args_info->rnemdrt_help = gengetopt_args_info_help[59] ; |
309 |
> |
args_info->nitrile_help = gengetopt_args_info_help[60] ; |
310 |
> |
args_info->multipole_help = gengetopt_args_info_help[61] ; |
311 |
> |
args_info->surfDiffusion_help = gengetopt_args_info_help[62] ; |
312 |
> |
args_info->hbond_help = gengetopt_args_info_help[63] ; |
313 |
|
|
314 |
|
} |
315 |
|
|
404 |
|
free_string_field (&(args_info->nbins_z_orig)); |
405 |
|
free_string_field (&(args_info->nanglebins_orig)); |
406 |
|
free_string_field (&(args_info->rcut_orig)); |
407 |
+ |
free_string_field (&(args_info->thetacut_orig)); |
408 |
|
free_string_field (&(args_info->dz_orig)); |
409 |
|
free_string_field (&(args_info->length_orig)); |
410 |
|
free_string_field (&(args_info->zlength_orig)); |
420 |
|
free_string_field (&(args_info->comsele_arg)); |
421 |
|
free_string_field (&(args_info->comsele_orig)); |
422 |
|
free_string_field (&(args_info->seleoffset_orig)); |
423 |
+ |
free_string_field (&(args_info->seleoffset2_orig)); |
424 |
|
free_string_field (&(args_info->molname_arg)); |
425 |
|
free_string_field (&(args_info->molname_orig)); |
426 |
|
free_string_field (&(args_info->begin_orig)); |
427 |
|
free_string_field (&(args_info->end_orig)); |
428 |
|
free_string_field (&(args_info->radius_orig)); |
429 |
+ |
free_string_field (&(args_info->voxelSize_orig)); |
430 |
+ |
free_string_field (&(args_info->gaussWidth_orig)); |
431 |
|
|
432 |
|
|
433 |
|
for (i = 0; i < args_info->inputs_num; ++i) |
485 |
|
write_into_file(outfile, "nanglebins", args_info->nanglebins_orig, 0); |
486 |
|
if (args_info->rcut_given) |
487 |
|
write_into_file(outfile, "rcut", args_info->rcut_orig, 0); |
488 |
+ |
if (args_info->thetacut_given) |
489 |
+ |
write_into_file(outfile, "thetacut", args_info->thetacut_orig, 0); |
490 |
|
if (args_info->dz_given) |
491 |
|
write_into_file(outfile, "dz", args_info->dz_orig, 0); |
492 |
|
if (args_info->length_given) |
507 |
|
write_into_file(outfile, "comsele", args_info->comsele_orig, 0); |
508 |
|
if (args_info->seleoffset_given) |
509 |
|
write_into_file(outfile, "seleoffset", args_info->seleoffset_orig, 0); |
510 |
+ |
if (args_info->seleoffset2_given) |
511 |
+ |
write_into_file(outfile, "seleoffset2", args_info->seleoffset2_orig, 0); |
512 |
|
if (args_info->molname_given) |
513 |
|
write_into_file(outfile, "molname", args_info->molname_orig, 0); |
514 |
|
if (args_info->begin_given) |
517 |
|
write_into_file(outfile, "end", args_info->end_orig, 0); |
518 |
|
if (args_info->radius_given) |
519 |
|
write_into_file(outfile, "radius", args_info->radius_orig, 0); |
520 |
+ |
if (args_info->voxelSize_given) |
521 |
+ |
write_into_file(outfile, "voxelSize", args_info->voxelSize_orig, 0); |
522 |
+ |
if (args_info->gaussWidth_given) |
523 |
+ |
write_into_file(outfile, "gaussWidth", args_info->gaussWidth_orig, 0); |
524 |
|
if (args_info->bo_given) |
525 |
|
write_into_file(outfile, "bo", 0, 0 ); |
526 |
< |
if (args_info->bor_given) |
527 |
< |
write_into_file(outfile, "bor", 0, 0 ); |
526 |
> |
if (args_info->ior_given) |
527 |
> |
write_into_file(outfile, "ior", 0, 0 ); |
528 |
> |
if (args_info->for_given) |
529 |
> |
write_into_file(outfile, "for", 0, 0 ); |
530 |
|
if (args_info->bad_given) |
531 |
|
write_into_file(outfile, "bad", 0, 0 ); |
532 |
|
if (args_info->count_given) |
573 |
|
write_into_file(outfile, "tet_param", 0, 0 ); |
574 |
|
if (args_info->tet_param_z_given) |
575 |
|
write_into_file(outfile, "tet_param_z", 0, 0 ); |
576 |
+ |
if (args_info->tet_param_xyz_given) |
577 |
+ |
write_into_file(outfile, "tet_param_xyz", 0, 0 ); |
578 |
+ |
if (args_info->rnemdz_given) |
579 |
+ |
write_into_file(outfile, "rnemdz", 0, 0 ); |
580 |
+ |
if (args_info->rnemdr_given) |
581 |
+ |
write_into_file(outfile, "rnemdr", 0, 0 ); |
582 |
+ |
if (args_info->rnemdrt_given) |
583 |
+ |
write_into_file(outfile, "rnemdrt", 0, 0 ); |
584 |
+ |
if (args_info->nitrile_given) |
585 |
+ |
write_into_file(outfile, "nitrile", 0, 0 ); |
586 |
+ |
if (args_info->multipole_given) |
587 |
+ |
write_into_file(outfile, "multipole", 0, 0 ); |
588 |
+ |
if (args_info->surfDiffusion_given) |
589 |
+ |
write_into_file(outfile, "surfDiffusion", 0, 0 ); |
590 |
+ |
if (args_info->hbond_given) |
591 |
+ |
write_into_file(outfile, "hbond", 0, 0 ); |
592 |
|
|
593 |
|
|
594 |
|
i = EXIT_SUCCESS; |
643 |
|
return; |
644 |
|
|
645 |
|
args_info->bo_given = 0 ; |
646 |
< |
args_info->bor_given = 0 ; |
646 |
> |
args_info->ior_given = 0 ; |
647 |
> |
args_info->for_given = 0 ; |
648 |
|
args_info->bad_given = 0 ; |
649 |
|
args_info->count_given = 0 ; |
650 |
|
args_info->gofr_given = 0 ; |
668 |
|
args_info->rodlength_given = 0 ; |
669 |
|
args_info->tet_param_given = 0 ; |
670 |
|
args_info->tet_param_z_given = 0 ; |
671 |
+ |
args_info->tet_param_xyz_given = 0 ; |
672 |
+ |
args_info->rnemdz_given = 0 ; |
673 |
+ |
args_info->rnemdr_given = 0 ; |
674 |
+ |
args_info->rnemdrt_given = 0 ; |
675 |
+ |
args_info->nitrile_given = 0 ; |
676 |
+ |
args_info->multipole_given = 0 ; |
677 |
+ |
args_info->surfDiffusion_given = 0 ; |
678 |
+ |
args_info->hbond_given = 0 ; |
679 |
|
|
680 |
|
args_info->staticProps_group_counter = 0; |
681 |
|
} |
932 |
|
{ "nbins_z", 1, NULL, 0 }, |
933 |
|
{ "nanglebins", 1, NULL, 'a' }, |
934 |
|
{ "rcut", 1, NULL, 'c' }, |
935 |
+ |
{ "thetacut", 1, NULL, 0 }, |
936 |
|
{ "dz", 1, NULL, 0 }, |
937 |
|
{ "length", 1, NULL, 0 }, |
938 |
|
{ "zlength", 1, NULL, 0 }, |
943 |
|
{ "refsele", 1, NULL, 0 }, |
944 |
|
{ "comsele", 1, NULL, 0 }, |
945 |
|
{ "seleoffset", 1, NULL, 0 }, |
946 |
+ |
{ "seleoffset2", 1, NULL, 0 }, |
947 |
|
{ "molname", 1, NULL, 0 }, |
948 |
|
{ "begin", 1, NULL, 0 }, |
949 |
|
{ "end", 1, NULL, 0 }, |
950 |
|
{ "radius", 1, NULL, 0 }, |
951 |
+ |
{ "voxelSize", 1, NULL, 'v' }, |
952 |
+ |
{ "gaussWidth", 1, NULL, 0 }, |
953 |
|
{ "bo", 0, NULL, 0 }, |
954 |
< |
{ "bor", 0, NULL, 0 }, |
954 |
> |
{ "ior", 0, NULL, 0 }, |
955 |
> |
{ "for", 0, NULL, 0 }, |
956 |
|
{ "bad", 0, NULL, 0 }, |
957 |
|
{ "count", 0, NULL, 0 }, |
958 |
|
{ "gofr", 0, NULL, 'g' }, |
976 |
|
{ "rodlength", 0, NULL, 0 }, |
977 |
|
{ "tet_param", 0, NULL, 'Q' }, |
978 |
|
{ "tet_param_z", 0, NULL, 0 }, |
979 |
+ |
{ "tet_param_xyz", 0, NULL, 0 }, |
980 |
+ |
{ "rnemdz", 0, NULL, 0 }, |
981 |
+ |
{ "rnemdr", 0, NULL, 0 }, |
982 |
+ |
{ "rnemdrt", 0, NULL, 0 }, |
983 |
+ |
{ "nitrile", 0, NULL, 0 }, |
984 |
+ |
{ "multipole", 0, NULL, 'm' }, |
985 |
+ |
{ "surfDiffusion", 0, NULL, 0 }, |
986 |
+ |
{ "hbond", 0, NULL, 0 }, |
987 |
|
{ 0, 0, 0, 0 } |
988 |
|
}; |
989 |
|
|
990 |
< |
c = getopt_long (argc, argv, "hVi:o:n:b:x:y:a:c:z:gpsdQ", long_options, &option_index); |
990 |
> |
c = getopt_long (argc, argv, "hVi:o:n:b:x:y:a:c:z:v:gpsdQm", long_options, &option_index); |
991 |
|
|
992 |
|
if (c == -1) break; /* Exit from `while (1)' loop. */ |
993 |
|
|
1111 |
|
goto failure; |
1112 |
|
|
1113 |
|
break; |
1114 |
+ |
case 'v': /* voxel size (angstroms). */ |
1115 |
+ |
|
1116 |
+ |
|
1117 |
+ |
if (update_arg( (void *)&(args_info->voxelSize_arg), |
1118 |
+ |
&(args_info->voxelSize_orig), &(args_info->voxelSize_given), |
1119 |
+ |
&(local_args_info.voxelSize_given), optarg, 0, 0, ARG_DOUBLE, |
1120 |
+ |
check_ambiguity, override, 0, 0, |
1121 |
+ |
"voxelSize", 'v', |
1122 |
+ |
additional_error)) |
1123 |
+ |
goto failure; |
1124 |
+ |
|
1125 |
+ |
break; |
1126 |
|
case 'g': /* g(r). */ |
1127 |
|
|
1128 |
|
if (args_info->staticProps_group_counter && override) |
1183 |
|
goto failure; |
1184 |
|
|
1185 |
|
break; |
1186 |
< |
case 'Q': /* tetrahedrality order parameter. */ |
1186 |
> |
case 'Q': /* tetrahedrality order parameter (Qk). */ |
1187 |
|
|
1188 |
|
if (args_info->staticProps_group_counter && override) |
1189 |
|
reset_group_staticProps (args_info); |
1198 |
|
goto failure; |
1199 |
|
|
1200 |
|
break; |
1201 |
+ |
case 'm': /* average multipole moments contained within cutoff spheres as a function of radius. */ |
1202 |
+ |
|
1203 |
+ |
if (args_info->staticProps_group_counter && override) |
1204 |
+ |
reset_group_staticProps (args_info); |
1205 |
+ |
args_info->staticProps_group_counter += 1; |
1206 |
+ |
|
1207 |
+ |
if (update_arg( 0 , |
1208 |
+ |
0 , &(args_info->multipole_given), |
1209 |
+ |
&(local_args_info.multipole_given), optarg, 0, 0, ARG_NO, |
1210 |
+ |
check_ambiguity, override, 0, 0, |
1211 |
+ |
"multipole", 'm', |
1212 |
+ |
additional_error)) |
1213 |
+ |
goto failure; |
1214 |
+ |
|
1215 |
+ |
break; |
1216 |
|
|
1217 |
|
case 0: /* Long option with no short option */ |
1218 |
|
/* number of bins in z axis. */ |
1229 |
|
goto failure; |
1230 |
|
|
1231 |
|
} |
1232 |
+ |
/* cutoff angle (thetacut). */ |
1233 |
+ |
else if (strcmp (long_options[option_index].name, "thetacut") == 0) |
1234 |
+ |
{ |
1235 |
+ |
|
1236 |
+ |
|
1237 |
+ |
if (update_arg( (void *)&(args_info->thetacut_arg), |
1238 |
+ |
&(args_info->thetacut_orig), &(args_info->thetacut_given), |
1239 |
+ |
&(local_args_info.thetacut_given), optarg, 0, 0, ARG_DOUBLE, |
1240 |
+ |
check_ambiguity, override, 0, 0, |
1241 |
+ |
"thetacut", '-', |
1242 |
+ |
additional_error)) |
1243 |
+ |
goto failure; |
1244 |
+ |
|
1245 |
+ |
} |
1246 |
|
/* slab width (dz). */ |
1247 |
|
else if (strcmp (long_options[option_index].name, "dz") == 0) |
1248 |
|
{ |
1369 |
|
goto failure; |
1370 |
|
|
1371 |
|
} |
1372 |
+ |
/* global index offset for a third object (used to define a vector between sites in molecule). */ |
1373 |
+ |
else if (strcmp (long_options[option_index].name, "seleoffset2") == 0) |
1374 |
+ |
{ |
1375 |
+ |
|
1376 |
+ |
|
1377 |
+ |
if (update_arg( (void *)&(args_info->seleoffset2_arg), |
1378 |
+ |
&(args_info->seleoffset2_orig), &(args_info->seleoffset2_given), |
1379 |
+ |
&(local_args_info.seleoffset2_given), optarg, 0, 0, ARG_INT, |
1380 |
+ |
check_ambiguity, override, 0, 0, |
1381 |
+ |
"seleoffset2", '-', |
1382 |
+ |
additional_error)) |
1383 |
+ |
goto failure; |
1384 |
+ |
|
1385 |
+ |
} |
1386 |
|
/* molecule name. */ |
1387 |
|
else if (strcmp (long_options[option_index].name, "molname") == 0) |
1388 |
|
{ |
1439 |
|
goto failure; |
1440 |
|
|
1441 |
|
} |
1442 |
+ |
/* Gaussian width (angstroms). */ |
1443 |
+ |
else if (strcmp (long_options[option_index].name, "gaussWidth") == 0) |
1444 |
+ |
{ |
1445 |
+ |
|
1446 |
+ |
|
1447 |
+ |
if (update_arg( (void *)&(args_info->gaussWidth_arg), |
1448 |
+ |
&(args_info->gaussWidth_orig), &(args_info->gaussWidth_given), |
1449 |
+ |
&(local_args_info.gaussWidth_given), optarg, 0, 0, ARG_DOUBLE, |
1450 |
+ |
check_ambiguity, override, 0, 0, |
1451 |
+ |
"gaussWidth", '-', |
1452 |
+ |
additional_error)) |
1453 |
+ |
goto failure; |
1454 |
+ |
|
1455 |
+ |
} |
1456 |
|
/* bond order parameter (--rcut must be specified). */ |
1457 |
|
else if (strcmp (long_options[option_index].name, "bo") == 0) |
1458 |
|
{ |
1470 |
|
goto failure; |
1471 |
|
|
1472 |
|
} |
1473 |
< |
/* bond order parameter as a function of radius (--rcut must be specified). */ |
1474 |
< |
else if (strcmp (long_options[option_index].name, "bor") == 0) |
1473 |
> |
/* icosahedral bond order parameter as a function of radius (--rcut must be specified). */ |
1474 |
> |
else if (strcmp (long_options[option_index].name, "ior") == 0) |
1475 |
|
{ |
1476 |
|
|
1477 |
|
if (args_info->staticProps_group_counter && override) |
1479 |
|
args_info->staticProps_group_counter += 1; |
1480 |
|
|
1481 |
|
if (update_arg( 0 , |
1482 |
< |
0 , &(args_info->bor_given), |
1483 |
< |
&(local_args_info.bor_given), optarg, 0, 0, ARG_NO, |
1482 |
> |
0 , &(args_info->ior_given), |
1483 |
> |
&(local_args_info.ior_given), optarg, 0, 0, ARG_NO, |
1484 |
|
check_ambiguity, override, 0, 0, |
1485 |
< |
"bor", '-', |
1485 |
> |
"ior", '-', |
1486 |
> |
additional_error)) |
1487 |
> |
goto failure; |
1488 |
> |
|
1489 |
> |
} |
1490 |
> |
/* FCC bond order parameter as a function of radius (--rcut must be specified). */ |
1491 |
> |
else if (strcmp (long_options[option_index].name, "for") == 0) |
1492 |
> |
{ |
1493 |
> |
|
1494 |
> |
if (args_info->staticProps_group_counter && override) |
1495 |
> |
reset_group_staticProps (args_info); |
1496 |
> |
args_info->staticProps_group_counter += 1; |
1497 |
> |
|
1498 |
> |
if (update_arg( 0 , |
1499 |
> |
0 , &(args_info->for_given), |
1500 |
> |
&(local_args_info.for_given), optarg, 0, 0, ARG_NO, |
1501 |
> |
check_ambiguity, override, 0, 0, |
1502 |
> |
"for", '-', |
1503 |
|
additional_error)) |
1504 |
|
goto failure; |
1505 |
|
|
1691 |
|
goto failure; |
1692 |
|
|
1693 |
|
} |
1694 |
< |
/* p(cos(theta)). */ |
1694 |
> |
/* p(cos(theta)) (--sele1 must be specified, --sele2 is optional). */ |
1695 |
|
else if (strcmp (long_options[option_index].name, "p_angle") == 0) |
1696 |
|
{ |
1697 |
|
|
1793 |
|
goto failure; |
1794 |
|
|
1795 |
|
} |
1796 |
< |
/* tetrahedrality order parameter by zbin(--sele1 must be specified). */ |
1796 |
> |
/* spatially-resolved tetrahedrality order parameter Qk(z). */ |
1797 |
|
else if (strcmp (long_options[option_index].name, "tet_param_z") == 0) |
1798 |
|
{ |
1799 |
|
|
1810 |
|
goto failure; |
1811 |
|
|
1812 |
|
} |
1813 |
+ |
/* volume-resolved tetrahedrality order parameter Qk(x,y,z). (voxelSize, rcut, and gaussWidth must be specified). */ |
1814 |
+ |
else if (strcmp (long_options[option_index].name, "tet_param_xyz") == 0) |
1815 |
+ |
{ |
1816 |
+ |
|
1817 |
+ |
if (args_info->staticProps_group_counter && override) |
1818 |
+ |
reset_group_staticProps (args_info); |
1819 |
+ |
args_info->staticProps_group_counter += 1; |
1820 |
|
|
1821 |
+ |
if (update_arg( 0 , |
1822 |
+ |
0 , &(args_info->tet_param_xyz_given), |
1823 |
+ |
&(local_args_info.tet_param_xyz_given), optarg, 0, 0, ARG_NO, |
1824 |
+ |
check_ambiguity, override, 0, 0, |
1825 |
+ |
"tet_param_xyz", '-', |
1826 |
+ |
additional_error)) |
1827 |
+ |
goto failure; |
1828 |
+ |
|
1829 |
+ |
} |
1830 |
+ |
/* slab-resolved RNEMD statistics (temperature, density, velocity). */ |
1831 |
+ |
else if (strcmp (long_options[option_index].name, "rnemdz") == 0) |
1832 |
+ |
{ |
1833 |
+ |
|
1834 |
+ |
if (args_info->staticProps_group_counter && override) |
1835 |
+ |
reset_group_staticProps (args_info); |
1836 |
+ |
args_info->staticProps_group_counter += 1; |
1837 |
+ |
|
1838 |
+ |
if (update_arg( 0 , |
1839 |
+ |
0 , &(args_info->rnemdz_given), |
1840 |
+ |
&(local_args_info.rnemdz_given), optarg, 0, 0, ARG_NO, |
1841 |
+ |
check_ambiguity, override, 0, 0, |
1842 |
+ |
"rnemdz", '-', |
1843 |
+ |
additional_error)) |
1844 |
+ |
goto failure; |
1845 |
+ |
|
1846 |
+ |
} |
1847 |
+ |
/* shell-resolved RNEMD statistics (temperature, density, angular velocity). */ |
1848 |
+ |
else if (strcmp (long_options[option_index].name, "rnemdr") == 0) |
1849 |
+ |
{ |
1850 |
+ |
|
1851 |
+ |
if (args_info->staticProps_group_counter && override) |
1852 |
+ |
reset_group_staticProps (args_info); |
1853 |
+ |
args_info->staticProps_group_counter += 1; |
1854 |
+ |
|
1855 |
+ |
if (update_arg( 0 , |
1856 |
+ |
0 , &(args_info->rnemdr_given), |
1857 |
+ |
&(local_args_info.rnemdr_given), optarg, 0, 0, ARG_NO, |
1858 |
+ |
check_ambiguity, override, 0, 0, |
1859 |
+ |
"rnemdr", '-', |
1860 |
+ |
additional_error)) |
1861 |
+ |
goto failure; |
1862 |
+ |
|
1863 |
+ |
} |
1864 |
+ |
/* shell and angle-resolved RNEMD statistics (temperature, density, angular velocity). */ |
1865 |
+ |
else if (strcmp (long_options[option_index].name, "rnemdrt") == 0) |
1866 |
+ |
{ |
1867 |
+ |
|
1868 |
+ |
if (args_info->staticProps_group_counter && override) |
1869 |
+ |
reset_group_staticProps (args_info); |
1870 |
+ |
args_info->staticProps_group_counter += 1; |
1871 |
+ |
|
1872 |
+ |
if (update_arg( 0 , |
1873 |
+ |
0 , &(args_info->rnemdrt_given), |
1874 |
+ |
&(local_args_info.rnemdrt_given), optarg, 0, 0, ARG_NO, |
1875 |
+ |
check_ambiguity, override, 0, 0, |
1876 |
+ |
"rnemdrt", '-', |
1877 |
+ |
additional_error)) |
1878 |
+ |
goto failure; |
1879 |
+ |
|
1880 |
+ |
} |
1881 |
+ |
/* electrostatic potential to frequency map based on the Cho nitrile fits. */ |
1882 |
+ |
else if (strcmp (long_options[option_index].name, "nitrile") == 0) |
1883 |
+ |
{ |
1884 |
+ |
|
1885 |
+ |
if (args_info->staticProps_group_counter && override) |
1886 |
+ |
reset_group_staticProps (args_info); |
1887 |
+ |
args_info->staticProps_group_counter += 1; |
1888 |
+ |
|
1889 |
+ |
if (update_arg( 0 , |
1890 |
+ |
0 , &(args_info->nitrile_given), |
1891 |
+ |
&(local_args_info.nitrile_given), optarg, 0, 0, ARG_NO, |
1892 |
+ |
check_ambiguity, override, 0, 0, |
1893 |
+ |
"nitrile", '-', |
1894 |
+ |
additional_error)) |
1895 |
+ |
goto failure; |
1896 |
+ |
|
1897 |
+ |
} |
1898 |
+ |
/* X, Y, and R (surface diffusion if Z exposed and bulk immobile) diffusion. */ |
1899 |
+ |
else if (strcmp (long_options[option_index].name, "surfDiffusion") == 0) |
1900 |
+ |
{ |
1901 |
+ |
|
1902 |
+ |
if (args_info->staticProps_group_counter && override) |
1903 |
+ |
reset_group_staticProps (args_info); |
1904 |
+ |
args_info->staticProps_group_counter += 1; |
1905 |
+ |
|
1906 |
+ |
if (update_arg( 0 , |
1907 |
+ |
0 , &(args_info->surfDiffusion_given), |
1908 |
+ |
&(local_args_info.surfDiffusion_given), optarg, 0, 0, ARG_NO, |
1909 |
+ |
check_ambiguity, override, 0, 0, |
1910 |
+ |
"surfDiffusion", '-', |
1911 |
+ |
additional_error)) |
1912 |
+ |
goto failure; |
1913 |
+ |
|
1914 |
+ |
} |
1915 |
+ |
/* Hydrogen Bonding statistics using geometric criteria (rcut and thetacut must be specified). */ |
1916 |
+ |
else if (strcmp (long_options[option_index].name, "hbond") == 0) |
1917 |
+ |
{ |
1918 |
+ |
|
1919 |
+ |
if (args_info->staticProps_group_counter && override) |
1920 |
+ |
reset_group_staticProps (args_info); |
1921 |
+ |
args_info->staticProps_group_counter += 1; |
1922 |
+ |
|
1923 |
+ |
if (update_arg( 0 , |
1924 |
+ |
0 , &(args_info->hbond_given), |
1925 |
+ |
&(local_args_info.hbond_given), optarg, 0, 0, ARG_NO, |
1926 |
+ |
check_ambiguity, override, 0, 0, |
1927 |
+ |
"hbond", '-', |
1928 |
+ |
additional_error)) |
1929 |
+ |
goto failure; |
1930 |
+ |
|
1931 |
+ |
} |
1932 |
+ |
|
1933 |
|
break; |
1934 |
|
case '?': /* Invalid option. */ |
1935 |
|
/* `getopt_long' already printed an error message. */ |