Running MAKGRD
To run the Fortran program, type makgrd and respond to the prompts
(this is the Fortran version but the Python version is essentially the
same).
A typical run might be
(user responses, <CR> = Return)
makgrd
R-MAKGRD: Running MAKGRD v2.0
Fundamental resolution: 0.0005
File containing spectral points: points.txt
Output spectral range (= 800.0000: 800.8000 [cm-1]): <CR>
Output .grd file: points.grd
R-MAKGRD: Successful completion
The program should run almost instantaneously.
For the Python version, if no change in spectral range is required,
it can be performed with a single call of the make method
within the Rfm_Grd class:
from rfm_grd_class import Rfm_Grd
grd = Rfm_Grd() # instantiate
grd.make ( 'points.txt', 0.0005, 'points.grd' )
Alternatively, and if a change in spectral range is required,
use the wnolim and write methods:
from rfm_grd_class import Rfm_Grd
grd = Rfm_Grd() # instantiate
grd.make ( 'points.txt', 0.0005 )
grd.wnolim() # no arguments -> just report current range
grd.wnolim ( 800.1,800.2 ) # alter range
grd.write ( 'points.grd' ) # create .grd file
This creates terminal output
Current Range: 800.0000 800.8000 [cm-1]
New Range: 800.1000 800.2000 [cm-1]
Creating file: points.grd
Notes
- It is assumed that the user-supplied set of irregular grid points represent
a sub-sampling of some underlying regular grid (here, 0.0005)
- User's file points.txt contains the
list of spectral points (see List file, below).
- The user has the option of setting the output file to
maintain the original
spectral range of the supplied grid points (as here), or of adjusting the range.
If extended, the output file will simply be padded with '0's.
! test data
201
800.00000 800.00400 800.00800 800.01200 800.01600
800.02000 800.02400 800.02800 800.03200 800.03600
800.04000 800.04400 800.04800 800.05200 800.05600
...
800.78000 800.78400 800.78800 800.79200 800.79600
800.80000
! test data
! Created by program makgrd.f90 v2.0
lin
1601 201 800.0000 0.0005
0.0 120.0
80808080808080808080808080808080808080808080808080
80808080808080808080808080808080808080808080808080
80808080808080808080808080808080808080808080808080
80808080808080808080808080808080808080808080808080
80808080808080808080808080808080808080808080808080
80808080808080808080808080808080808080808080808080
80808080808080808080808080808080808080808080808080
80808080808080808080808080808080808080808080808080
8