APBS 3.0.0
Loading...
Searching...
No Matches
nosh.h
Go to the documentation of this file.
1
4
61
62#ifndef _NOSH_H_
63#define _NOSH_H_
64
65#include "apbscfg.h"
66
67#include "maloc/maloc.h"
68
69#include "generic/vhal.h"
70#include "generic/vstring.h"
71#include "generic/pbeparm.h"
72#include "generic/mgparm.h"
73#include "generic/apolparm.h"
74#include "generic/femparm.h"
75#include "generic/valist.h"
76#include "generic/bemparm.h"
77#include "generic/geoflowparm.h"
78#include "generic/pbamparm.h"
79#include "generic/pbsamparm.h" //path might change
80
83#define NOSH_MAXMOL 20
84
87#define NOSH_MAXCALC 20
88
91#define NOSH_MAXPRINT 20
92
95#define NOSH_MAXPOP 20
96
106
112
126
132
141
147
160
166
183
188typedef struct sNOsh_calc NOsh_calc;
189
272
277typedef struct sNOsh NOsh;
278
279/* ///////////////////////////////////////////////////////////////////////////
280 // Class NOsh: Inlineable methods (mcsh.c)
282#if !defined(VINLINE_NOSH)
290VEXTERNC char* NOsh_getMolpath(NOsh *thee, int imol);
291
299VEXTERNC char* NOsh_getDielXpath(NOsh *thee, int imap);
300
308VEXTERNC char* NOsh_getDielYpath(NOsh *thee, int imap);
309
317VEXTERNC char* NOsh_getDielZpath(NOsh *thee, int imap);
318
326VEXTERNC char* NOsh_getKappapath(NOsh *thee, int imap);
327
335VEXTERNC char* NOsh_getPotpath(NOsh *thee, int imap);
336
344VEXTERNC char* NOsh_getChargepath(NOsh *thee, int imap);
345
353VEXTERNC NOsh_calc* NOsh_getCalc(NOsh *thee, int icalc);
354
362VEXTERNC int NOsh_getDielfmt(NOsh *thee, int imap);
363
371VEXTERNC int NOsh_getKappafmt(NOsh *thee, int imap);
372
380VEXTERNC int NOsh_getPotfmt(NOsh *thee, int imap);
381
389VEXTERNC int NOsh_getChargefmt(NOsh *thee, int imap);
390
391#else
392
393# define NOsh_getMolpath(thee, imol) ((thee)->molpath[(imol)])
394# define NOsh_getDielXpath(thee, imol) ((thee)->dielXpath[(imol)])
395# define NOsh_getDielYpath(thee, imol) ((thee)->dielYpath[(imol)])
396# define NOsh_getDielZpath(thee, imol) ((thee)->dielZpath[(imol)])
397# define NOsh_getKappapath(thee, imol) ((thee)->kappapath[(imol)])
398# define NOsh_getPotpath(thee, imol) ((thee)->potpath[(imol)])
399# define NOsh_getChargepath(thee, imol) ((thee)->chargepath[(imol)])
400# define NOsh_getCalc(thee, icalc) ((thee)->calc[(icalc)])
401# define NOsh_getDielfmt(thee, imap) ((thee)->dielfmt[(imap)])
402# define NOsh_getKappafmt(thee, imap) ((thee)->kappafmt[(imap)])
403# define NOsh_getPotfmt(thee, imap) ((thee)->potfmt[(imap)])
404# define NOsh_getChargefmt(thee, imap) ((thee)->chargefmt[(imap)])
405
406#endif
407
408
409/* ///////////////////////////////////////////////////////////////////////////
410 // Class NOsh: Non-inlineable methods (mcsh.c)
412
420VEXTERNC NOsh_PrintType NOsh_printWhat(NOsh *thee, int iprint);
421
431VEXTERNC char* NOsh_elecname(NOsh *thee, int ielec);
432
440VEXTERNC int NOsh_elec2calc(NOsh *thee, int icalc);
441
449VEXTERNC int NOsh_apol2calc(NOsh *thee, int icalc);
450
458VEXTERNC int NOsh_printNarg(NOsh *thee, int iprint);
459
468VEXTERNC int NOsh_printOp(NOsh *thee, int iprint, int iarg);
469
480VEXTERNC int NOsh_printCalc(NOsh *thee, int iprint, int iarg);
481
491VEXTERNC NOsh* NOsh_ctor(int rank, int size);
492
499VEXTERNC NOsh_calc* NOsh_calc_ctor(
500 NOsh_CalcType calcType
501 );
502
509VEXTERNC int NOsh_calc_copy(
510 NOsh_calc *thee,
511 NOsh_calc *source
512 );
513
519VEXTERNC void NOsh_calc_dtor(NOsh_calc **thee);
520
531VEXTERNC int NOsh_ctor2(NOsh *thee, int rank, int size);
532
538VEXTERNC void NOsh_dtor(NOsh **thee);
539
545VEXTERNC void NOsh_dtor2(NOsh *thee);
546
555VEXTERNC int NOsh_parseInput(NOsh *thee, Vio *sock);
556
566VEXTERNC int NOsh_parseInputFile(NOsh *thee, char *filename);
567
577VEXTERNC int NOsh_setupElecCalc(
578 NOsh *thee,
580 );
581
591VEXTERNC int NOsh_setupApolCalc(
592 NOsh *thee,
594 );
595
596#endif
597
Contains declarations for class APOLparm.
Contains declarations for class GEOFLOWparm.
struct sAPOLparm APOLparm
Declaration of the APOLparm class as the APOLparm structure.
Definition apolparm.h:188
struct sBEMparm BEMparm
Parameter structure for BEM-specific variables from input files.
struct sFEMparm FEMparm
Declaration of the FEMparm class as the FEMparm structure.
Definition femparm.h:182
struct sGEOFLOWparm GEOFLOWparm
Parameter structure for GEOFLOW-specific variables from input files.
struct sMGparm MGparm
Declaration of the MGparm class as the MGparm structure.
Definition mgparm.h:203
VEXTERNC char * NOsh_getDielZpath(NOsh *thee, int imap)
Returns path to specified z-shifted dielectric map.
Definition nosh.c:215
#define NOSH_MAXCALC
Maximum number of calculations in a run.
Definition nosh.h:87
enum eNOsh_MolFormat NOsh_MolFormat
Declare NOsh_MolFormat type.
Definition nosh.h:111
VEXTERNC void NOsh_dtor(NOsh **thee)
Object destructor.
Definition nosh.c:354
#define NOSH_MAXMOL
Maximum number of molecules in a run.
Definition nosh.h:83
VEXTERNC int NOsh_calc_copy(NOsh_calc *thee, NOsh_calc *source)
Copy NOsh_calc object into thee.
Definition nosh.c:467
VEXTERNC NOsh_calc * NOsh_getCalc(NOsh *thee, int icalc)
Returns specified calculation object.
Definition nosh.c:235
struct sNOsh NOsh
Declaration of the NOsh class as the NOsh structure.
Definition nosh.h:277
VEXTERNC void NOsh_dtor2(NOsh *thee)
FORTRAN stub for object destructor.
Definition nosh.c:362
#define NOSH_MAXPRINT
Maximum number of PRINT statements in a run.
Definition nosh.h:91
VEXTERNC int NOsh_elec2calc(NOsh *thee, int icalc)
Return the name of an elec statement.
Definition nosh.c:276
eNOsh_MolFormat
Molecule file format types.
Definition nosh.h:101
VEXTERNC char * NOsh_getPotpath(NOsh *thee, int imap)
Returns path to specified potential map.
Definition nosh.c:225
VEXTERNC int NOsh_setupElecCalc(NOsh *thee, Valist *alist[NOSH_MAXMOL])
Setup the series of electrostatics calculations.
Definition nosh.c:1374
VEXTERNC int NOsh_printOp(NOsh *thee, int iprint, int iarg)
Return integer ID for specified operation (.
Definition nosh.c:294
VEXTERNC char * NOsh_getDielXpath(NOsh *thee, int imap)
Returns path to specified x-shifted dielectric map.
Definition nosh.c:205
VEXTERNC int NOsh_parseInput(NOsh *thee, Vio *sock)
Parse an input file from a socket.
Definition nosh.c:513
VEXTERNC int NOsh_parseInputFile(NOsh *thee, char *filename)
Parse an input file only from a file.
Definition nosh.c:498
VEXTERNC char * NOsh_getDielYpath(NOsh *thee, int imap)
Returns path to specified y-shifted dielectric map.
Definition nosh.c:210
VEXTERNC void NOsh_calc_dtor(NOsh_calc **thee)
Object destructor.
Definition nosh.c:423
VEXTERNC char * NOsh_elecname(NOsh *thee, int ielec)
Return an integer mapping of an ELEC statement to a calculation ID (.
Definition nosh.c:288
VEXTERNC int NOsh_getChargefmt(NOsh *thee, int imap)
Returns format of specified charge map.
Definition nosh.c:255
VEXTERNC int NOsh_getKappafmt(NOsh *thee, int imap)
Returns format of specified kappa map.
Definition nosh.c:245
VEXTERNC int NOsh_getDielfmt(NOsh *thee, int imap)
Returns format of specified dielectric map.
Definition nosh.c:240
VEXTERNC NOsh_PrintType NOsh_printWhat(NOsh *thee, int iprint)
Return an integer ID of the observable to print (.
Definition nosh.c:264
VEXTERNC int NOsh_apol2calc(NOsh *thee, int icalc)
Return the name of an apol statement.
Definition nosh.c:282
#define NOSH_MAXPOP
Maximum number of operations in a PRINT statement.
Definition nosh.h:95
VEXTERNC int NOsh_getPotfmt(NOsh *thee, int imap)
Returns format of specified potential map.
Definition nosh.c:250
struct sNOsh_calc NOsh_calc
Declaration of the NOsh_calc class as the NOsh_calc structure.
Definition nosh.h:188
enum eNOsh_PrintType NOsh_PrintType
Declare NOsh_PrintType type.
Definition nosh.h:165
VEXTERNC char * NOsh_getKappapath(NOsh *thee, int imap)
Returns path to specified kappa map.
Definition nosh.c:220
VEXTERNC int NOsh_printCalc(NOsh *thee, int iprint, int iarg)
Return calculation ID for specified PRINT statement (.
Definition nosh.c:301
eNOsh_CalcType
NOsh calculation types.
Definition nosh.h:117
VEXTERNC NOsh * NOsh_ctor(int rank, int size)
Construct NOsh.
Definition nosh.c:308
VEXTERNC NOsh_calc * NOsh_calc_ctor(NOsh_CalcType calcType)
Construct NOsh_calc.
Definition nosh.c:374
VEXTERNC char * NOsh_getMolpath(NOsh *thee, int imol)
Returns path to specified molecule.
Definition nosh.c:200
eNOsh_ParmFormat
Parameter file format types.
Definition nosh.h:137
VEXTERNC int NOsh_ctor2(NOsh *thee, int rank, int size)
FORTRAN stub to construct NOsh.
Definition nosh.c:319
VEXTERNC int NOsh_printNarg(NOsh *thee, int iprint)
Return number of arguments to PRINT statement (.
Definition nosh.c:270
enum eNOsh_CalcType NOsh_CalcType
Declare NOsh_CalcType type.
Definition nosh.h:131
VEXTERNC char * NOsh_getChargepath(NOsh *thee, int imap)
Returns path to specified charge distribution map.
Definition nosh.c:230
VEXTERNC int NOsh_setupApolCalc(NOsh *thee, Valist *alist[NOSH_MAXMOL])
Setup the series of non-polar calculations.
Definition nosh.c:1469
enum eNOsh_ParmFormat NOsh_ParmFormat
Declare NOsh_ParmFormat type.
Definition nosh.h:146
eNOsh_PrintType
NOsh print types.
Definition nosh.h:152
@ NMF_XML
Definition nosh.h:104
@ NMF_PDB
Definition nosh.h:103
@ NMF_PQR
Definition nosh.h:102
@ NCT_BEM
Definition nosh.h:121
@ NCT_APOL
Definition nosh.h:120
@ NCT_PBSAM
Definition nosh.h:124
@ NCT_MG
Definition nosh.h:118
@ NCT_PBAM
Definition nosh.h:123
@ NCT_FEM
Definition nosh.h:119
@ NCT_GEOFLOW
Definition nosh.h:122
@ NPF_FLAT
Definition nosh.h:138
@ NPF_XML
Definition nosh.h:139
@ NPT_ELECFORCE
Definition nosh.h:156
@ NPT_FORCE
Definition nosh.h:154
@ NPT_APOLENERGY
Definition nosh.h:157
@ NPT_ELECENERGY
Definition nosh.h:155
@ NPT_ENERGY
Definition nosh.h:153
@ NPT_APOLFORCE
Definition nosh.h:158
struct sPBAMparm PBAMparm
Parameter structure for PBAM-specific variables from input files.
struct sPBEparm PBEparm
Declaration of the PBEparm class as the PBEparm structure.
Definition pbeparm.h:213
struct sPBSAMparm PBSAMparm
Parameter structure for PBSAM-specific variables from input files.
struct sValist Valist
Declaration of the Valist class as the Valist structure.
Definition valist.h:95
enum eVdata_Format Vdata_Format
Declaration of the Vdata_Format type as the Vdata_Format enum.
Definition vhal.h:323
Contains declarations for class MGparm.
Contains declarations for class PBAMparm.
Contains declarations for class PBEparm.
Contains declarations for class PBSAMparm.
Calculation class for use when parsing fixed format input files.
Definition nosh.h:172
FEMparm * femparm
Definition nosh.h:174
BEMparm * bemparm
Definition nosh.h:175
GEOFLOWparm * geoflowparm
Definition nosh.h:176
NOsh_CalcType calctype
Definition nosh.h:181
MGparm * mgparm
Definition nosh.h:173
APOLparm * apolparm
Definition nosh.h:180
PBSAMparm * pbsamparm
Definition nosh.h:178
PBAMparm * pbamparm
Definition nosh.h:177
PBEparm * pbeparm
Definition nosh.h:179
Class for parsing fixed format input files.
Definition nosh.h:195
char apolname[NOSH_MAXCALC][VMAX_ARGLEN]
Definition nosh.h:269
char chargepath[NOSH_MAXMOL][VMAX_ARGLEN]
Definition nosh.h:254
int proc_rank
Definition nosh.h:215
int ncharge
Definition nosh.h:253
Valist * alist[NOSH_MAXMOL]
Definition nosh.h:234
int nelec
Definition nosh.h:205
int parsed
Definition nosh.h:266
int gotparm
Definition nosh.h:236
int proc_size
Definition nosh.h:216
char elecname[NOSH_MAXCALC][VMAX_ARGLEN]
Definition nosh.h:267
char dielZpath[NOSH_MAXMOL][VMAX_ARGLEN]
Definition nosh.h:244
NOsh_calc * elec[NOSH_MAXCALC]
Definition nosh.h:202
Vdata_Format meshfmt[NOSH_MAXMOL]
Definition nosh.h:258
int npot
Definition nosh.h:250
NOsh_calc * apol[NOSH_MAXCALC]
Definition nosh.h:208
NOsh_ParmFormat parmfmt
Definition nosh.h:238
int ncalc
Definition nosh.h:200
char kappapath[NOSH_MAXMOL][VMAX_ARGLEN]
Definition nosh.h:248
int ndiel
Definition nosh.h:239
int ispara
Definition nosh.h:214
char dielXpath[NOSH_MAXMOL][VMAX_ARGLEN]
Definition nosh.h:240
int printnarg[NOSH_MAXPRINT]
Definition nosh.h:262
int nmol
Definition nosh.h:231
NOsh_calc * calc[NOSH_MAXCALC]
Definition nosh.h:197
char meshpath[NOSH_MAXMOL][VMAX_ARGLEN]
Definition nosh.h:257
char potpath[NOSH_MAXMOL][VMAX_ARGLEN]
Definition nosh.h:251
Vdata_Format potfmt[NOSH_MAXMOL]
Definition nosh.h:252
int printcalc[NOSH_MAXPRINT][NOSH_MAXPOP]
Definition nosh.h:263
int nkappa
Definition nosh.h:247
char molpath[NOSH_MAXMOL][VMAX_ARGLEN]
Definition nosh.h:232
Vdata_Format kappafmt[NOSH_MAXMOL]
Definition nosh.h:249
NOsh_MolFormat molfmt[NOSH_MAXMOL]
Definition nosh.h:233
char parmpath[VMAX_ARGLEN]
Definition nosh.h:237
int napol
Definition nosh.h:211
int apol2calc[NOSH_MAXCALC]
Definition nosh.h:229
Vdata_Format chargefmt[NOSH_MAXMOL]
Definition nosh.h:255
NOsh_PrintType printwhat[NOSH_MAXPRINT]
Definition nosh.h:260
int elec2calc[NOSH_MAXCALC]
Definition nosh.h:221
Vdata_Format dielfmt[NOSH_MAXMOL]
Definition nosh.h:246
int nprint
Definition nosh.h:259
char dielYpath[NOSH_MAXMOL][VMAX_ARGLEN]
Definition nosh.h:242
int nmesh
Definition nosh.h:256
int printop[NOSH_MAXPRINT][NOSH_MAXPOP]
Definition nosh.h:264
int bogus
Definition nosh.h:217
Contains declarations for class Valist.
Contains generic macro definitions for APBS.
Contains declarations for class Vstring.