APBS 3.0.0
Loading...
Searching...
No Matches
NOsh class

Class for parsing for fixed format input files. More...

Files

file  nosh.c
 Class NOsh methods.
 
file  nosh.h
 Contains declarations for class NOsh.
 

Data Structures

struct  sNOsh_calc
 Calculation class for use when parsing fixed format input files. More...
 
struct  sNOsh
 Class for parsing fixed format input files. More...
 

Macros

#define NOSH_MAXMOL   20
 Maximum number of molecules in a run.
 
#define NOSH_MAXCALC   20
 Maximum number of calculations in a run.
 
#define NOSH_MAXPRINT   20
 Maximum number of PRINT statements in a run.
 
#define NOSH_MAXPOP   20
 Maximum number of operations in a PRINT statement.
 

Typedefs

typedef enum eNOsh_MolFormat NOsh_MolFormat
 Declare NOsh_MolFormat type.
 
typedef enum eNOsh_CalcType NOsh_CalcType
 Declare NOsh_CalcType type.
 
typedef enum eNOsh_ParmFormat NOsh_ParmFormat
 Declare NOsh_ParmFormat type.
 
typedef enum eNOsh_PrintType NOsh_PrintType
 Declare NOsh_PrintType type.
 
typedef struct sNOsh NOsh
 Declaration of the NOsh class as the NOsh structure.
 
typedef struct sNOsh_calc NOsh_calc
 Declaration of the NOsh_calc class as the NOsh_calc structure.
 

Enumerations

enum  eNOsh_MolFormat { NMF_PQR =0 , NMF_PDB =1 , NMF_XML =2 }
 Molecule file format types. More...
 
enum  eNOsh_CalcType {
  NCT_MG =0 , NCT_FEM =1 , NCT_APOL =2 , NCT_BEM =3 ,
  NCT_GEOFLOW =4 , NCT_PBAM =5 , NCT_PBSAM =6
}
 NOsh calculation types. More...
 
enum  eNOsh_ParmFormat { NPF_FLAT =0 , NPF_XML =1 }
 Parameter file format types. More...
 
enum  eNOsh_PrintType {
  NPT_ENERGY =0 , NPT_FORCE =1 , NPT_ELECENERGY , NPT_ELECFORCE ,
  NPT_APOLENERGY , NPT_APOLFORCE
}
 NOsh print types. More...
 

Functions

VEXTERNC char * NOsh_getMolpath (NOsh *thee, int imol)
 Returns path to specified molecule.
 
VEXTERNC char * NOsh_getDielXpath (NOsh *thee, int imap)
 Returns path to specified x-shifted dielectric map.
 
VEXTERNC char * NOsh_getDielYpath (NOsh *thee, int imap)
 Returns path to specified y-shifted dielectric map.
 
VEXTERNC char * NOsh_getDielZpath (NOsh *thee, int imap)
 Returns path to specified z-shifted dielectric map.
 
VEXTERNC char * NOsh_getKappapath (NOsh *thee, int imap)
 Returns path to specified kappa map.
 
VEXTERNC char * NOsh_getPotpath (NOsh *thee, int imap)
 Returns path to specified potential map.
 
VEXTERNC char * NOsh_getChargepath (NOsh *thee, int imap)
 Returns path to specified charge distribution map.
 
VEXTERNC NOsh_calcNOsh_getCalc (NOsh *thee, int icalc)
 Returns specified calculation object.
 
VEXTERNC int NOsh_getDielfmt (NOsh *thee, int imap)
 Returns format of specified dielectric map.
 
VEXTERNC int NOsh_getKappafmt (NOsh *thee, int imap)
 Returns format of specified kappa map.
 
VEXTERNC int NOsh_getPotfmt (NOsh *thee, int imap)
 Returns format of specified potential map.
 
VEXTERNC int NOsh_getChargefmt (NOsh *thee, int imap)
 Returns format of specified charge map.
 
VEXTERNC NOsh_PrintType NOsh_printWhat (NOsh *thee, int iprint)
 Return an integer ID of the observable to print (.
 
VEXTERNC char * NOsh_elecname (NOsh *thee, int ielec)
 Return an integer mapping of an ELEC statement to a calculation ID (.
 
VEXTERNC int NOsh_elec2calc (NOsh *thee, int icalc)
 Return the name of an elec statement.
 
VEXTERNC int NOsh_apol2calc (NOsh *thee, int icalc)
 Return the name of an apol statement.
 
VEXTERNC int NOsh_printNarg (NOsh *thee, int iprint)
 Return number of arguments to PRINT statement (.
 
VEXTERNC int NOsh_printOp (NOsh *thee, int iprint, int iarg)
 Return integer ID for specified operation (.
 
VEXTERNC int NOsh_printCalc (NOsh *thee, int iprint, int iarg)
 Return calculation ID for specified PRINT statement (.
 
VEXTERNC NOshNOsh_ctor (int rank, int size)
 Construct NOsh.
 
VEXTERNC NOsh_calcNOsh_calc_ctor (NOsh_CalcType calcType)
 Construct NOsh_calc.
 
VEXTERNC int NOsh_calc_copy (NOsh_calc *thee, NOsh_calc *source)
 Copy NOsh_calc object into thee.
 
VEXTERNC void NOsh_calc_dtor (NOsh_calc **thee)
 Object destructor.
 
VEXTERNC int NOsh_ctor2 (NOsh *thee, int rank, int size)
 FORTRAN stub to construct NOsh.
 
VEXTERNC void NOsh_dtor (NOsh **thee)
 Object destructor.
 
VEXTERNC void NOsh_dtor2 (NOsh *thee)
 FORTRAN stub for object destructor.
 
VEXTERNC int NOsh_parseInput (NOsh *thee, Vio *sock)
 Parse an input file from a socket.
 
VEXTERNC int NOsh_parseInputFile (NOsh *thee, char *filename)
 Parse an input file only from a file.
 
VEXTERNC int NOsh_setupElecCalc (NOsh *thee, Valist *alist[NOSH_MAXMOL])
 Setup the series of electrostatics calculations.
 
VEXTERNC int NOsh_setupApolCalc (NOsh *thee, Valist *alist[NOSH_MAXMOL])
 Setup the series of non-polar calculations.
 

Detailed Description

Class for parsing for fixed format input files.

Macro Definition Documentation

◆ NOSH_MAXCALC

#define NOSH_MAXCALC   20

Maximum number of calculations in a run.

Definition at line 87 of file nosh.h.

◆ NOSH_MAXMOL

#define NOSH_MAXMOL   20

Maximum number of molecules in a run.

Definition at line 83 of file nosh.h.

◆ NOSH_MAXPOP

#define NOSH_MAXPOP   20

Maximum number of operations in a PRINT statement.

Definition at line 95 of file nosh.h.

◆ NOSH_MAXPRINT

#define NOSH_MAXPRINT   20

Maximum number of PRINT statements in a run.

Definition at line 91 of file nosh.h.

Typedef Documentation

◆ NOsh

typedef struct sNOsh NOsh

Declaration of the NOsh class as the NOsh structure.

Definition at line 277 of file nosh.h.

◆ NOsh_calc

typedef struct sNOsh_calc NOsh_calc

Declaration of the NOsh_calc class as the NOsh_calc structure.

Definition at line 188 of file nosh.h.

◆ NOsh_CalcType

Declare NOsh_CalcType type.

Definition at line 131 of file nosh.h.

◆ NOsh_MolFormat

Declare NOsh_MolFormat type.

Definition at line 111 of file nosh.h.

◆ NOsh_ParmFormat

Declare NOsh_ParmFormat type.

Definition at line 146 of file nosh.h.

◆ NOsh_PrintType

Declare NOsh_PrintType type.

Definition at line 165 of file nosh.h.

Enumeration Type Documentation

◆ eNOsh_CalcType

NOsh calculation types.

Enumerator
NCT_MG 

Multigrid

NCT_FEM 

Finite element

NCT_APOL 

non-polar

NCT_BEM 

Boundary element (TABI)

NCT_GEOFLOW 

Geometric flow

NCT_PBAM 

Analytical Poisson-Boltzmann Solver

NCT_PBSAM 

Semi-Analytical Poisson-Boltzmann Solver

Definition at line 117 of file nosh.h.

◆ eNOsh_MolFormat

Molecule file format types.

Enumerator
NMF_PQR 

PQR format

NMF_PDB 

PDB format

NMF_XML 

XML format

Definition at line 101 of file nosh.h.

◆ eNOsh_ParmFormat

Parameter file format types.

Enumerator
NPF_FLAT 

Flat-file format

NPF_XML 

XML format

Definition at line 137 of file nosh.h.

◆ eNOsh_PrintType

NOsh print types.

Enumerator
NPT_ENERGY 

Energy (deprecated)

NPT_FORCE 

Force (deprecated)

NPT_ELECENERGY 

Elec Energy

NPT_ELECFORCE 

Elec Force

NPT_APOLENERGY 

Apol Energy

NPT_APOLFORCE 

Apol Force

Definition at line 152 of file nosh.h.

Function Documentation

◆ NOsh_apol2calc()

VEXTERNC int NOsh_apol2calc ( NOsh * thee,
int icalc )

Return the name of an apol statement.

Author
David Gohara
Parameters
theeNOsh object to use
icalcID of CALC statement
Returns
The name (if present) of an APOL statement

Definition at line 282 of file nosh.c.

◆ NOsh_calc_copy()

VEXTERNC int NOsh_calc_copy ( NOsh_calc * thee,
NOsh_calc * source )

Copy NOsh_calc object into thee.

Author
Nathan Baker
Parameters
theeTarget object
sourceSource object

Definition at line 467 of file nosh.c.

◆ NOsh_calc_ctor()

VEXTERNC NOsh_calc * NOsh_calc_ctor ( NOsh_CalcType calcType)

Construct NOsh_calc.

Author
Nathan Baker
Parameters
calcTypeCalculation type
Returns
Newly allocated and initialized NOsh object

Definition at line 374 of file nosh.c.

◆ NOsh_calc_dtor()

VEXTERNC void NOsh_calc_dtor ( NOsh_calc ** thee)

Object destructor.

Author
Nathan Baker
Parameters
theePointer to memory location of NOsh_calc object

Definition at line 423 of file nosh.c.

◆ NOsh_ctor()

VEXTERNC NOsh * NOsh_ctor ( int rank,
int size )

Construct NOsh.

Author
Nathan Baker
Parameters
rankRank of current processor in parallel calculation (0 if not parallel)
sizeNumber of processors in parallel calculation (1 if not parallel)
Returns
Newly allocated and initialized NOsh object

Definition at line 308 of file nosh.c.

◆ NOsh_ctor2()

VEXTERNC int NOsh_ctor2 ( NOsh * thee,
int rank,
int size )

FORTRAN stub to construct NOsh.

Author
Nathan Baker
Parameters
theeSpace for NOsh objet
rankRank of current processor in parallel calculation (0 if not parallel)
sizeNumber of processors in parallel calculation (1 if not parallel)
Returns
1 if successful, 0 otherwise

Definition at line 319 of file nosh.c.

◆ NOsh_dtor()

VEXTERNC void NOsh_dtor ( NOsh ** thee)

Object destructor.

Author
Nathan Baker
Parameters
theePointer to memory location of NOsh object

Definition at line 354 of file nosh.c.

◆ NOsh_dtor2()

VEXTERNC void NOsh_dtor2 ( NOsh * thee)

FORTRAN stub for object destructor.

Author
Nathan Baker
Parameters
theePointer to NOsh object

Definition at line 362 of file nosh.c.

◆ NOsh_elec2calc()

VEXTERNC int NOsh_elec2calc ( NOsh * thee,
int icalc )

Return the name of an elec statement.

Author
Todd Dolinsky
Parameters
theeNOsh object to use
icalcID of CALC statement
Returns
The name (if present) of an ELEC statement

Definition at line 276 of file nosh.c.

◆ NOsh_elecname()

VEXTERNC char * NOsh_elecname ( NOsh * thee,
int ielec )

Return an integer mapping of an ELEC statement to a calculation ID (.

See also
elec2calc)
Author
Nathan Baker
Parameters
theeNOsh object to use
ielecID of ELEC statement
Returns
An integer mapping of an ELEC statement to a calculation ID (
See also
elec2calc)

Definition at line 288 of file nosh.c.

◆ NOsh_getCalc()

VEXTERNC NOsh_calc * NOsh_getCalc ( NOsh * thee,
int icalc )

Returns specified calculation object.

Author
Nathan Baker
Parameters
theePointer to NOsh object
icalcCalculation ID of interest
Returns
Pointer to specified calculation object

Definition at line 235 of file nosh.c.

◆ NOsh_getChargefmt()

VEXTERNC int NOsh_getChargefmt ( NOsh * thee,
int imap )

Returns format of specified charge map.

Author
Nathan Baker
Parameters
theePointer to NOsh object
imapCalculation ID of interest
Returns
Format of charge map

Definition at line 255 of file nosh.c.

◆ NOsh_getChargepath()

VEXTERNC char * NOsh_getChargepath ( NOsh * thee,
int imap )

Returns path to specified charge distribution map.

Author
Nathan Baker
Parameters
theePointer to NOsh object
imapMap ID of interest
Returns
Path string

Definition at line 230 of file nosh.c.

◆ NOsh_getDielfmt()

VEXTERNC int NOsh_getDielfmt ( NOsh * thee,
int imap )

Returns format of specified dielectric map.

Author
Nathan Baker
Parameters
theePointer to NOsh object
imapCalculation ID of interest
Returns
Format of dielectric map

Definition at line 240 of file nosh.c.

◆ NOsh_getDielXpath()

VEXTERNC char * NOsh_getDielXpath ( NOsh * thee,
int imap )

Returns path to specified x-shifted dielectric map.

Author
Nathan Baker
Parameters
theePointer to NOsh object
imapMap ID of interest
Returns
Path string

Definition at line 205 of file nosh.c.

◆ NOsh_getDielYpath()

VEXTERNC char * NOsh_getDielYpath ( NOsh * thee,
int imap )

Returns path to specified y-shifted dielectric map.

Author
Nathan Baker
Parameters
theePointer to NOsh object
imapMap ID of interest
Returns
Path string

Definition at line 210 of file nosh.c.

◆ NOsh_getDielZpath()

VEXTERNC char * NOsh_getDielZpath ( NOsh * thee,
int imap )

Returns path to specified z-shifted dielectric map.

Author
Nathan Baker
Parameters
theePointer to NOsh object
imapMap ID of interest
Returns
Path string

Definition at line 215 of file nosh.c.

◆ NOsh_getKappafmt()

VEXTERNC int NOsh_getKappafmt ( NOsh * thee,
int imap )

Returns format of specified kappa map.

Author
Nathan Baker
Parameters
theePointer to NOsh object
imapCalculation ID of interest
Returns
Format of kappa map

Definition at line 245 of file nosh.c.

◆ NOsh_getKappapath()

VEXTERNC char * NOsh_getKappapath ( NOsh * thee,
int imap )

Returns path to specified kappa map.

Author
Nathan Baker
Parameters
theePointer to NOsh object
imapMap ID of interest
Returns
Path string

Definition at line 220 of file nosh.c.

◆ NOsh_getMolpath()

VEXTERNC char * NOsh_getMolpath ( NOsh * thee,
int imol )

Returns path to specified molecule.

Author
Nathan Baker
Parameters
theePointer to NOsh object
imolMolecule ID of interest
Returns
Path string

Definition at line 200 of file nosh.c.

◆ NOsh_getPotfmt()

VEXTERNC int NOsh_getPotfmt ( NOsh * thee,
int imap )

Returns format of specified potential map.

Author
Nathan Baker
Parameters
theePointer to NOsh object
imapCalculation ID of interest
Returns
Format of potential map

Definition at line 250 of file nosh.c.

◆ NOsh_getPotpath()

VEXTERNC char * NOsh_getPotpath ( NOsh * thee,
int imap )

Returns path to specified potential map.

Author
David Gohara
Parameters
theePointer to NOsh object
imapMap ID of interest
Returns
Path string

Definition at line 225 of file nosh.c.

◆ NOsh_parseInput()

VEXTERNC int NOsh_parseInput ( NOsh * thee,
Vio * sock )

Parse an input file from a socket.

Note
Should be called before NOsh_setupCalc
Author
Nathan Baker and Todd Dolinsky
Parameters
theePointer to NOsh object
sockStream of tokens to parse
Returns
1 if successful, 0 otherwise

Definition at line 513 of file nosh.c.

◆ NOsh_parseInputFile()

VEXTERNC int NOsh_parseInputFile ( NOsh * thee,
char * filename )

Parse an input file only from a file.

Note
Included for SWIG wrapper compatibility
Should be called before NOsh_setupCalc
Author
Nathan Baker and Todd Dolinsky
Parameters
theePointer to NOsh object
filenameName/path of readable file
Returns
1 if successful, 0 otherwise

Definition at line 498 of file nosh.c.

◆ NOsh_printCalc()

VEXTERNC int NOsh_printCalc ( NOsh * thee,
int iprint,
int iarg )

Return calculation ID for specified PRINT statement (.

See also
printcalc)
Author
Nathan Baker
Parameters
theeNOsh object to use
iprintID of PRINT statement
iargID of operation in PRINT statement
Returns
Calculation ID for specified PRINT statement (
See also
printcalc)

Definition at line 301 of file nosh.c.

◆ NOsh_printNarg()

VEXTERNC int NOsh_printNarg ( NOsh * thee,
int iprint )

Return number of arguments to PRINT statement (.

See also
printnarg)
Author
Nathan Baker
Parameters
theeNOsh object to use
iprintID of PRINT statement
Returns
Number of arguments to PRINT statement (
See also
printnarg)

Definition at line 270 of file nosh.c.

◆ NOsh_printOp()

VEXTERNC int NOsh_printOp ( NOsh * thee,
int iprint,
int iarg )

Return integer ID for specified operation (.

See also
printop)
Author
Nathan Baker
Parameters
theeNOsh object to use
iprintID of PRINT statement
iargID of operation in PRINT statement
Returns
Integer ID for specified operation (
See also
printop)

Definition at line 294 of file nosh.c.

◆ NOsh_printWhat()

VEXTERNC NOsh_PrintType NOsh_printWhat ( NOsh * thee,
int iprint )

Return an integer ID of the observable to print (.

See also
printwhat)
Author
Nathan Baker
Parameters
theeNOsh object to use
iprintID of PRINT statement
Returns
An integer ID of the observable to print (
See also
printwhat)

Definition at line 264 of file nosh.c.

◆ NOsh_setupApolCalc()

VEXTERNC int NOsh_setupApolCalc ( NOsh * thee,
Valist * alist[NOSH_MAXMOL] )

Setup the series of non-polar calculations.

Note
Should be called after NOsh_parseInput*
Author
Nathan Baker and Todd Dolinsky
Parameters
theePointer to NOsh object
alistArray of pointers to Valist objects (molecules used to center mesh);
Returns
1 if successful, 0 otherwise
Parameters
theeNOsh object
alistAtom list for calculation

Definition at line 1469 of file nosh.c.

◆ NOsh_setupElecCalc()

VEXTERNC int NOsh_setupElecCalc ( NOsh * thee,
Valist * alist[NOSH_MAXMOL] )

Setup the series of electrostatics calculations.

Note
Should be called after NOsh_parseInput*
Author
Nathan Baker and Todd Dolinsky
Parameters
theePointer to NOsh object
alistArray of pointers to Valist objects (molecules used to center mesh);
Returns
1 if successful, 0 otherwise
Parameters
theeNOsh object
alistAtom list for calculation

Definition at line 1374 of file nosh.c.