# Class BasisFunctionReader

java.lang.Object
org.jmol.adapter.smarter.AtomSetCollectionReader
org.jmol.adapter.readers.quantum.BasisFunctionReader

All Implemented Interfaces:
  `GenericLineReader`

Direct Known Subclasses:
  `MOReader, SpartanInputReader, SpartanReader`

public abstract class BasisFunctionReader extends AtomSetCollectionReader

Author:
  hansonr invalid input: '<'hansonr@stolaf.edu>

## Nested Class Summary

Nested Classes
Modifier and Type
Class
Description
`class`
`BasisFunctionReader.MOEnergySorter`

## Field Summary

Fields
Modifier and Type
Field
Description
`protected String`
`alphaBeta`
`protected int[][]`
`dfCoefMaps`
`protected boolean`
`haveCoefs`
`protected boolean`
`ignoreMOs`
`Map<String,Object>`
`moData`
`protected int`
`nCoef`
`protected int`
`nOrbitals`
`Lst<Map<String,Object>>`
`orbitals`
`Lst<int[]>`
`shells`
`protected SlaterData[]`
`slaterArray`
`protected Lst<SlaterData>`
`slaters`

### Fields inherited from class AtomSetCollectionReader

`addedData, addedDataKey, addVibrations, allow_a_len_1, allowPDBFilter, ANGSTROMS_PER_BOHR, applySymmetryToBonds, asc, baseAtomIndex, baseBondIndex, binaryDoc, bsFilter, bsModels, calculationType, CELL_TYPE_CONVENTIONAL, CELL_TYPE_PRIMITIVE, CELL_TYPE_SUPER, cellSlop, centroidPacked, checkNearAtoms, continuing, debugging, desiredModelNumber, desiredSpaceGroupIndex, desiredVibrationNumber, doApplySymmetry, doCentralize, doCentroidUnitCell, doCheckUnitCell, doConvertToFractional, doPackUnitCell, doProcessLines, doReadMolecularOrbitals, dssr, fileName, fileOffset, filePath, fileScaling, fillRange, filter, filterAllHetero, filterCased, filteredPrecision, filterHetero, floatifyJavaDouble, forcePacked, getHeader, haveAtomFilter, haveModel, havePartialChargeFilter, htParams, ignoreFileSpaceGroupName, ignoreFileSymmetryOperators, ignoreFileUnitCell, ignoreStructure, iHaveFractionalCoordinates, iHaveSymmetryOperators, iHaveUnitCell, is2D, isBinary, isConcatenated, isDSSP1, isFinalized, isMolecular, isPrimitive, isSequential, isSUPERCELL, isTrajectory, latticeCells, latticeScaling, latticeType, line, lowPrecision, lstNCS, matUnitCellOrientation, merging, modDim, modelNumber, ms, mustFinalizeModelSet, next, noHydrogens, noMinimize, noPack, optimize2D, out, paramsCentroid, paramsLattice, precision, prevline, primitiveToCrystal, ptLine, ptSupercell, reader, readerName, requiresBSFilter, reverseModels, rotateHexCell, sgName, slabXY, stateScriptVersionInt, strSupercell, symmetry, templateAtomCount, thisBiomolecule, trajectorySteps, ucItems, unitCellOffset, unitCellParams, useAltNames, useFileModelNumbers, validation, vibrationNumber, vibsFractional, vwr`

## Constructor Summary

Constructors
Constructor
Description
`BasisFunctionReader()`

## Method Summary

Modifier and Type
Method
Description
`protected static final String`
`canonicalizeQuantumSubshellTag(String tag)`
`protected void`
`clearOrbitals()`
`protected void`
`discardPreviousAtoms()`
`protected void`
`enableShell(int shellType)`
This flag must be explicitly set when a reader has been verified to properly sort G, H, I,...
`protected boolean`
`filterMO()`
check line for filter options
`protected int`
`fixSlaterTypes(int typeOld, int typeNew)`
Only for 5D, 10F, 15G designations.
`int[][]`
`getDfCoefMaps()`
`protected boolean`
`getDFMap(String shell, String fileList, int shellType, String jmolList, int minLength)`
finds the position in the Jmol-required list of function types.
`static String`
`getQuantumShellTag(int id)`
`static int`
`getQuantumShellTagID(String tag)`
`static int`
`getQuantumShellTagIDSpherical(String tag)`
`void`
`setMO(Map<String,Object> mo)`

### Methods inherited from class AtomSetCollectionReader

`addAtomXYZSymName, addExplicitLatticeVector, addJmolScript, addMoreUnitCellInfo, addSites, addSiteScript, appendLoadNote, applySymmetryAndSetTrajectory, applySymTrajASCR, checkAndRemoveFilterKey, checkCurrentLineForScript, checkFilterKey, checkLastModel, checkLine, checkLineForScript, clearUnitCell, cloneLastAtomSet, discardLinesUntilBlank, discardLinesUntilContains, discardLinesUntilContains2, discardLinesUntilNonBlank, discardLinesUntilStartsWith, doGetModel, doGetVibration, doPreSymmetry, fill3x3, fillDataBlock, fillDataBlockFixed, fillFloatArray, fillFrequencyData, filterAtom, filterReject, finalizeMOData, finalizeModelSet, finalizeReaderASCR, finalizeSubclassReader, finalizeSubclassSymmetry, fixDoubleA, fixFloatA, fixFloatPt, forceSymmetry, fractionalizeCoordinates, getElementSymbol, getFilter, getFilterWithCase, getFortranFormatLengths, getInterface, getPackingRangeValue, getStrings, getSymmetry, getTokens, getTokensFloat, initializeReader, initializeSymmetry, initializeSymmetryOptions, initializeTrajectoryFile, isLastModel, newAtomSet, parseFloat, parseFloatRange, parseFloatStr, parseInt, parseIntAt, parseIntRange, parseIntStr, parsePrecision, parseToken, parseTokenNext, parseTokenRange, parseTokenStr, processBinaryDocument, processDOM, rd, read3Vectors, readDataObject, readLines, readNextLine, rejectAtomName, RL, set2D, setAtomCoord, setAtomCoordScaled, setAtomCoordTokens, setAtomCoordXYZ, setChainID, setElementAndIsotope, setFilter, setFilterAtomTypeStr, setFractionalCoordinates, setIsPDB, setLoadNote, setModelPDB, setPrecision, setSpaceGroupName, setSymmetryOperator, setTransform, setUnitCell, setUnitCellItem, setup, setupASCR, warnSkippingOperation`

### Methods inherited from class Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### shells

public Lst<int[]> shells

### slaters

protected Lst<SlaterData> slaters

### slaterArray

protected SlaterData[] slaterArray

### moData

public Map<String,Object> moData

### orbitals

public Lst<Map<String,Object>> orbitals

### nOrbitals

protected int nOrbitals

### ignoreMOs

protected boolean ignoreMOs

### alphaBeta

protected String alphaBeta

### dfCoefMaps

protected int[][] dfCoefMaps

### nCoef

protected int nCoef

### haveCoefs

protected boolean haveCoefs

## Constructor Details

### BasisFunctionReader

public BasisFunctionReader()

## Method Details

### filterMO

protected boolean filterMO()
check line for filter options

Returns:
  true if a match

### setMO

public void setMO(Map<String,Object> mo)

### getDFMap

protected boolean getDFMap(String shell, String fileList, int shellType, String jmolList, int minLength)
finds the position in the Jmol-required list of function types. This list is reader-dependent.

Parameters:
  `shell` - TODO
  `fileList` -
  `shellType` -
  `jmolList` -
  `minLength` -
Returns:
  true if successful

### enableShell

protected void enableShell(int shellType)
This flag must be explicitly set when a reader has been verified to properly sort G, H, I,... orbitals.

Parameters:
  `shellType` -

### getDfCoefMaps

public int[][] getDfCoefMaps()

### canonicalizeQuantumSubshellTag

protected static final String canonicalizeQuantumSubshellTag(String tag)

### fixSlaterTypes

protected int fixSlaterTypes(int typeOld, int typeNew)
Only for 5D, 10F, 15G designations. Each time this method is run through, additional changes are made in the orbital count. So only the final reading is significant.

Parameters:
  `typeOld` -
  `typeNew` -
Returns:
  the number of coefficients overall, for all orbital types

### getQuantumShellTagIDSpherical

public static int getQuantumShellTagIDSpherical(String tag)

### getQuantumShellTagID

public static int getQuantumShellTagID(String tag)

### getQuantumShellTag

public static String getQuantumShellTag(int id)

### discardPreviousAtoms

protected void discardPreviousAtoms()

Overrides:
  `discardPreviousAtoms` in class `AtomSetCollectionReader`

### clearOrbitals

protected void clearOrbitals()