Copyright © 2004–2016 by A. Miyoshi
BEx1D reference manual - bx1VIBsol
BEx1D reference manual - bx1VIBsol
Synopsis
bx1VIBsol basefilename
Description
The bx1VIBsol
program solves one-dimensional
time-independent
Schrödinger equation with the infinite-zero boundary condition,
which is a typical boundary for most of the intramolecular vibrational
motions. For a potential energy curve given by a power series,
the eigen states are calculated by expanding a wavefunction with a
Hermite-Gaussian basis function set.
A base file name must be specified as a command-line argument.
Inputs are read from a file 'basefilename.inp'.
The eigen-state energies and partition function values are stored in
files 'basefilename_eigen_values.csv' and
'basefilename_part_funcs.csv', respectively.
Optionally, eigen vectors and eigen functions can also be stored in CSV
format files.
Input
The following parameters are allowed in an input file
'
basefilename.inp' for
bx1VIBsol
.
1) | * title, |
2) | solver control, |
3) | * nuclear spin statistics, |
4) | * output option, |
5) | * temperatures for partition-function calculation, and |
6) | potential function |
The parts marked by asterisks (*) are optional. These can appear
in any order and may be duplicated. When duplicated,
the one-value parameter (parameters in solver control part)
is overwritten, while duplicated
part is combined to the existing part for multi-value parameters such as
title or temperature input.
[Title] Any input line beginning with '#'
followed by at least one white-space character is a title line and
is ignored.
[Comment] Any text from an exclamation mark, '!'
, to the end of the
line is regarded as comments and ignored.
[Blank line] Any blank line, which consists of white-space
characters and comment part only, is skipped by the input parser.
The following parameters are essential, that is, they must
be present in the input.
numBasis
The
'numBasis'
keyword is used to specify the number of
basis function used in the eigen function expansion.
numBasis number_of_basis_functions
It should be noted that the basis functions used in
bx1VIBsol
are the harmonic-oscillator wave functions (or Hermite-Gaussian functions),
ψv =
NvHv(y)exp(−y2 / 2)
where
y =
x /
α and
α =
(
2 /
mkf)
1/4.
Nv is a normalization constant and
Hv(
y)
is a Hermite polynomial. The quantum number
v starts from zero (0).
The following line tells the program to use 501 basis functions,
that is,
v = 0 to 500.
numBasis 501
hbar2/2m (or rotConst)
The keyword
'hbar2/2m'
or its synonym
'rotConst'
specifies the value of coefficient
2 / 2
m in the one-dimensional
Hamiltonian,
H = −(
2 / 2
m)(d
2 / d
x2)
+
V(
x)
hbar2/2m hbar-square_over_2m
— or —
rotConst hbar-square_over_2I
The synonym
'rotConst'
may be intuitive because, when
an angle (in radian unit) is chosen as coordinate
x of the
motion, the coefficient becomes
2 / 2
I
which is exactly the rotational constant of the motion.
UNIT: Unit of hbar2/2m
(or rotConst
)
must be in cm−1 Ux2, where
cm−1 is used as the unit of energy, and Ux
is the unit of coordinate assumed in the potential energy function input.
hoFreq
This keyword tells the program of harmonic oscillator frequency
or, exactly speaking, the energy of the vibrational quantum of
the basis-set functions.
hoFreq harmonic_oscillator_quantum
This parameter is used to determine the exponent,
α, of the
Hermite-Gaussian basis set from the relation,
α = [ 2 · (hbar2/2m
) / (hoFreq
) ]1/2
Note that the value of this parameter is not deterministic, but it affects
the convergence of the expansion calculation. In other words,
the program, in principle, can give enough accurate solution
regardless of the choice of this parameter if sufficiently large number
of basis functions are used for expansion. In many cases,
the use of the harmonic frequency calculated by quantum chemistry
programs such as Gaussian is sufficient.
UNIT: Unit of hoFreq
must be in cm−1.
Bending vibrations, like the umbrella inversion of ammonia
(NH3), sometimes involve motion between two minima
which correspond to the exchange of equivalent nuclei.
In this case, symmetric vibrational state is allowed only for
asymmetric or symmetric nuclear spin state, depending on whether
the equivalent nuclei are fermions or bosons.
Vibrational partition functions must be properly calculated for
this case, in most cases, by dividing the partition function by the
symmetry number, two. Though seldom at around ambient
temperature, difference of the nuclear spin weight need to be
properly accounted at low temperatures. For example,
for the umbrella inversion vibration of NH2D, the
nuclear spin weights are 1, 3, 1, 3, 1, ... for v =
0, 1, 2, 3, 4, ...
In the input of bx1VIBsol
, the nuclear spin
statistics can be incorporated in either way, using one of the
following two keywords. These are optional input, and
no weight nor symmetry number is used in the partition-function
calculations.
symNumbr
A keyword to set a symmetry number for partition-function
calculations.
symNumbr symmetry_number
nuSpinSt
This keyword is used to specify the periodic change of
nuclear spin weights for vibrational states.
nuSpinSt length_of_period w-1 w-2 ...
The first parameter,
length_of_period
, specifies
the length of the period and this is two for the NH
2D
example shown above.
w
-i's list the
nuclear spin weights, and the number of weights in the list must
be equal to
length_of_period
. Below
is an example for NH
2D.
nuSpinSt 2 1 3 ! period = 2, alternation is 1,3,1,3,...
A keyword,
'output'
, can be used to control the
bx1VIBsol
outputs. By default, the program creates
output files containing eigen values and partition functions only.
The other output files for eigen vectors and eigen functions can
be generated when specified in this input.
output name_of_output-1 [name_of_output-2]
Valid names for
name_of_output-i
are,
'vector'
,
'function'
, and
'all'
.
The following three input examples are equivalent.
output all
output vector function
output function vector
The output of eigen vectors and eigen functions are optional
because the calculation of these output needs some more computation
time, especially for the calculation of eigen functions, which requires
much longer computation time than that for the essential calculation,
the diagonalization of the Hamiltonian matrix.
Temperatures for partition-function calculation
Temperatures at which the partition functions are calculated
can be specified by one of, or by any combination of, the following
three types of input.
tempRange T_start T_end T_step
tempRecipRange numer start end step
tempList T1 T2 T3 ...
The first keyword
'tempRange'
sets an equally spaced
temperature list from
T_start
to
T_end
, with the interval
T_step
.
Next type of input beginning with a keyword
'tempRecipRange'
sets a list of temperatures
equally spaced in its reciprocal numbers, that is, they are equally
spaced in Arrhenius plots.
Like a convention used the abscissa of Arrhenius plots, the
reciprocal temperature may be specified in the form like 1000 /
T,
10000 /
T, or
etc. by setting the
numer
(numerator) to 1000, 10000, or
etc.
For example,
tempRecipRange 10000 5 40 1
sets a list of temperatures corresponding to 10000 /
T
= 5, 6, 7, ..., 40. The last type of temperature specification
starts with
'tempList'
. This input sets a list of
temperatures as they listed after the keyword.
The temperature input line may appear in the input as many time as
requested, for example, the follwing input is allowed.
tempList 298.15
tempRange 300 900 100
tempRecipRange 10000 5 10 1
DEFAULT: When no temperature specification is found in the input,
the program uses its default which is equivalent to the following input.
tempRang 300. 1500. 100.
The program
bx1VIBsol
assumes a power series
potential function and an input in the following format.
potPars{
order-1 coefficient-1
order-2 coefficient-2
order-3 coefficient-3
...
}
The
order-i
must be a nonnegative integer.
It should be noted that the potential function must satisfy the following
condition.
limx→±∞ V(x) = +∞
That is, the highest order must be an even number and the coefficient
for the highest-order term must be positive.
bx1VIBsol
does proceed calculation even if this condition was not satisfied
since, in some occasion, the calculation may succeed with small number
of basis functions and the result may be useful, though it would
certainly fail when a larger number of basis functions was used to
increase the accuracy.
Output
The program can create the following four types of files when a
calculation is done successfully. (See 'Output option' in the
Input section above for the control of optional output.)
| Output | File name |
1) | eigen values |
(basefilename_eigen_values.csv) |
2) | partition functions |
(basefilename_part_funcs.csv) |
3) | * eigen vectors |
(basefilename_eigen_vectorsNN.csv) | NN = 00, 01, 02, ... |
4) | * eigen functions |
(basefilename_eigen_funcsNN.csv) | NN = 00, 01, 02, ... |
Some diagnostic messages like below may be printed to the console
(standard output).
estimated eigenvalue error is 1% at quantum number = 220.
estimated partition function error is 6.2394e-046 at 2000 K.
The fist line tells the error estimation of eigen values, and the second
tells the estimated error in the partition function calculation.
Table r2-1. Eigenvalues
number | eigenValue | w | |
0 | 50.340893 | (1/1) | |
1 | 156.5024 | (1/1) | |
2 | 268.75298 | (1/1) | |
3 | 385.86919 | (1/1) | |
... | ... | ... | |
220 | 144689.77 | (1/1) | (maximum ...) |
... | ... | ... | |
Eigen value output
Table r2-1 shows a part of an example eigen value output,
as viewed by a spread sheet software like Microsoft® Excel.
The first column shows the (quantum) numbers of the eigenstates,
second shows the eigen values (or eigenstate energies) in
cm−1 unit, and the last shows the nuclear-spin
statistical weights.
The program prints the all eigen values calculated, that is,
the number of eigen values are exactly the same as the
numBasis
input. However, except for the case
that the potential function is harmonic and the basis functions are
exact solutions, the calculated eigen values for large quantum numbers
are unreliable. The program does error analysis and it determines
the maximum reliable quantum number, at the threshold of 1% relative
error in energy. This threshold quantum number is printed to the
console (as shown above) and in the eigen value output file
as '(maximum reliable qntNbr)'
which is found at the
quantum number = 220 in the example shown in Table r2-1.
Table r2-2. Partition function
10000/T | T | Q |
33.333333 | 300 | 1.882205 |
30.30303 | 330 | 2.0603718 |
27.777778 | 360 | 2.2366488 |
... | ... | ... |
Partition function output
First few lines of an example partition function output is
shown in Table r2-2. The first and the second column show
reciprocal number of temperatures and temperatures in K unit,
respectively. The last column shows the calculated values of
the partition function.
If the estimated error in the partition function exceed the
predefined threshold (1% relative error), the temperature list
is truncated by removing higher temperatures so that the estimate
error does not exceed the threshold at all the temperatures in the
list. When the program removed some temperatures from list,
it print a warning message to the console. The estimated error
at the maximum temperature calculated is printed to the console.
Table r2-3. Eigen vectors
eigen_values | 50.340893 | 156.5024 | 268.75298 | ... |
eigen_vectors | vec0 | vec1 | vec2 |
c0 | 0.9914 | 0 | 0.1267 |
c1 | 0 | 0.9688 | 0 |
c2 | -0.1303 | 0 | 0.9207 |
c3 | 0 | -0.2433 | 0 |
c4 | 0.01567 | 0 | -0.3563 |
c5 | 0 | 0.04631 | 0 |
... |
Eigen vector output
Table r2-3 shows a part of eigen vector output. The first row
shows the eigen values exactly same as in eigen value output.
From second row, each column shows an eigen vector, a vector of
coefficients for basis functions. c
i
denotes a coefficients for i'th basis function.
For low eigenstates, for which the harmonic oscillator approximation
is fairy good, the dominant coefficients are corresponding basis
functions.
The eigen vectors are printed in the output up to the
'maximum reliable quantum number' described above in
'Eigen vector output'.
Because of the limitation of Microsoft® Excel
(maximum number of columns = 256) the output is separated in
multiple CSV files when the number of eigen vectors exceeds 250.
Table r2-4. Eigen functions
x | f0 | f1 | f2 |
-0.303426 | 0.4756 | -1.069 | 1.419 |
-0.20342 | 0.9745 | -1.489 | 0.9556 |
-0.103414 | 1.488 | -1.166 | -0.4238 |
-0.00340844 | 1.721 | -0.04459 | -1.266 |
0.00113728 | 1.722 | 0.01488 | -1.267 |
0.101143 | 1.498 | 1.148 | -0.4557 |
0.201149 | 0.9871 | 1.491 | 0.9311 |
0.301155 | 0.4851 | 1.082 | 1.422 |
... |
Eigen function output
An example output of eigen functions is shown in Table r2-4.
Only thinned-out values around x = −0.3, −0.2,
−0.1, 0, +0.1, +0.2, +0.3 are shown. The values of the
coordinate x are chosen automatically so that the major part
of the eigen function at the highest quantum number is properly shown.
Similarly to the eigen vector output, the eigen functions
up to the 'maximum reliable quantum number' are printed.
Also the output is separated in multiple files when the
number of eigen functions exceeds 250.
Program limits
Internally,
bx1VIBsol
calls DSBEV routine (eigen
problem solver for real symmetric band matrix) in
LAPACK
written by FORTRAN. Only limitations hard-wired in the source
codes are the declaration part of static arrays which are passed to
FORTRAN routines. These can be found in 'libbx1PS.h' file
at the beginning of
basisHermiteGauss
class
declaration;
class basisHermiteGauss {
public:
enum { MXNBAS = 2001, // maximum number of basis functions
SZWLPK = 6001, // size of DSBEV work array: max(1, 3*MXNBAS-2)
MXRWAB = 51 }; // max nbr rows of DSBEV ab mat: max(maxOrder+1)
that is, the maximum quantum number of basis function is 2000 and
the maximum order of the potential function polynomial is 50.
All the other working variables use dynamically allocated memory
and the system resource may limit the program execution.