Warn when a value is unused
[gromacs.git] / include / sfactor.h
blobaa8fe9d96766604b559a1e734534f9dfc5a3d129
1 /*
2 *
3 * This source code is part of
4 *
5 * G R O M A C S
6 *
7 * GROningen MAchine for Chemical Simulations
8 *
9 * VERSION 3.2.0
10 * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others.
11 * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
12 * Copyright (c) 2001-2004, The GROMACS development team,
13 * check out http://www.gromacs.org for more information.
15 * This program is free software; you can redistribute it and/or
16 * modify it under the terms of the GNU General Public License
17 * as published by the Free Software Foundation; either version 2
18 * of the License, or (at your option) any later version.
20 * If you want to redistribute modifications, please consider that
21 * scientific software is very special. Version control is crucial -
22 * bugs must be traceable. We will be happy to consider code for
23 * inclusion in the official distribution, but derived work must not
24 * be called official GROMACS. Details are found in the README & COPYING
25 * files - if they are missing, get the official version at www.gromacs.org.
27 * To help us fund GROMACS development, we humbly ask that you cite
28 * the papers on the package - you can find them in the top README file.
30 * For more info, check our website at http://www.gromacs.org
32 * And Hey:
33 * Gromacs Runs On Most of All Computer Systems
36 #ifndef _sfactor_h
37 #define _sfactor_h
40 #include "index.h"
41 #include "types/simple.h"
42 #include "gmxcomplex.h"
43 #include "oenv.h"
47 #ifdef __cplusplus
48 extern "C" {
49 #endif
52 typedef struct gmx_structurefactors gmx_structurefactors_t;
54 typedef struct structure_factor structure_factor_t;
56 typedef struct reduced_atom reduced_atom_t;
58 int * create_indexed_atom_type (reduced_atom_t * atm, int size);
60 void compute_structure_factor (structure_factor_t * sft, matrix box,
61 reduced_atom_t * red, int isize, real start_q,
62 real end_q, int group,real **sf_table);
64 gmx_structurefactors_t *gmx_structurefactors_init(const char *datfn);
66 void gmx_structurefactors_done(gmx_structurefactors_t *gsf);
68 int gmx_structurefactors_get_sf(gmx_structurefactors_t *gsf, int elem, real a[4], real b[4], real *c);
70 real **gmx_structurefactors_table(gmx_structurefactors_t *gsf,real momentum, real ref_k,
71 real lambda, int n_angles);
73 void save_data (structure_factor_t * sft, const char *file, int ngrps,
74 real start_q, real end_q, const output_env_t oenv);
76 double CMSF (gmx_structurefactors_t *gsf,int type,int nh,double lambda, double sin_theta);
78 int return_atom_type (const char *name,gmx_structurefactors_t *gsf);
80 void rearrange_atoms (reduced_atom_t * positions, t_trxframe *fr, atom_id * index,
81 int isize, t_topology * top, gmx_bool flag,gmx_structurefactors_t *gsf);
83 int do_scattering_intensity (const char* fnTPS, const char* fnNDX,
84 const char* fnXVG, const char *fnTRX,
85 const char* fnDAT,
86 real start_q,real end_q,
87 real energy,int ng,const output_env_t oenv);
89 t_complex *** rc_tensor_allocation(int x, int y, int z);
91 real **compute_scattering_factor_table (gmx_structurefactors_t *gsf,structure_factor_t * sft,int *nsftable);
93 #ifdef __cplusplus
95 #endif
96 #endif