|
Home | XTAL | BT1 | Instruments | Search | SiteMap |
LOGIC a program for searching the JCPDS/ICDD database for entries matching constrants such as: chemistry, element count, peaks in particular locations. It requires the Tcl/Tk package. It has been tested on SGI, LINUX, and HP UNIX computers and under Windows-95. It should run on any platform where Tcl/Tk runs, but may require minor tweaking. (Click here to volunteer.) The Portable LOGIC program
To use this program in any useful manner, you will need to license a copy of the ICDD-JCPDS database from the International Centre for Diffraction Data. So that you can get an idea of how the program works, a small amount of [ficticious] sample database entries have been included in the distribution so that people who have not purchased the database can get a feel for how this software works. The ICDD-JCPDS database is required in PDF-2 (also known as NIST*AIDS-83) format. This is normally provided as a file on CDROM, but the file can exist on any device. Note that is a "80 character fixed-record-length" file, which means it has no new-line characters. Thus it is a somewhat non-standard ASCII file. However, if the ICDD CDROM is mounted as a standard ISO9660 device, the file can be read using direct-access read statements.
Some out-of-date instructions can be found in file ftp://ftp.ncnr.nist.gov/pub/cryst/powdersuite/INSTWin95. Windows-95 Installation Instructions
UNIX Installation Instructions
- Install the Tcl/Tk package (Click here for instructions.)
- To install the files you will need to uncompress the distribution file using the GNU gunzip program.
- Create a directory for LOGIC:
mkdir logic cd logic- Download the distribution file, by Shift-clicking on the following link ftp://ftp.ncnr.nist.gov/pub/cryst/powdersuite/powder_suite.tar.gz.
or latest version: ftp://ftp.ncnr.nist.gov/pub/cryst/powdersuite/powder_suite_alpha.tar.gz.
- Uncompress and retrieve the files using command
gunzip < powder_suite.tar.gz | tar xvf -- For SGI, LINUX and HP computers, you can compile the code using command
make sgiormake linuxormake hpCheck to see that make does not stop due to compiler or linker errors.If you have problems, you may need to edit file Make.inc. and then use make all. See below for more information.
- Install the PDF database.
- To build the full database from CDROM:
Change file "files.loc" The three lines in this file are:
the location for output files the location of file pdf2.dat (on the CDROM) (for future use) the location of a local database fileBuild the PDF database. Use command:make installNote that this starts a script in background (encode.unix) that may take several hours to complete.Review file "encode/encode.out" to see that the three programs ran correctly. See file encode-testdata.out for a sample of how the file should appear.
- or Install the test PDF database
If you want to test the software but do not have a copy of the JCPDS database you can use command
make testdataNote that this starts a script that will take at most a few minutes to complete.Review file "encode/encode.out" to see that the three programs ran correctly. See file encode-output-testdata for a sample of how the file should appear.
Note: file encode/encode.in determines how "deleted" patterns are treated. By default the patterns are used, but their d-spaces are not included in the PDF-1 database and thus will not be found in d-space searches. This can be changed by editing this file.- Create a link to file logic in a location where it will be convenient to use and will appear in your path or for a multiuser system, in everyone's path (for example /usr/local/bin/)
- At this point it should be possible to run rehash the path and then access the database using command:
logicNote: you may want to edit the contents of file copynotice to customize any details of licensing for your site. Users will see the contents of this file only once. (The message will appear whenever file ~/icdd.not is not present).
If you have problems, you may need to edit file Make.inc. and then use make all. Below are the symbols used in this file.
Makefile Symbols
FC FORTRAN compiler CC C compiler F2CLIB libraries needed by FORTRAN programs FFLAGS FORTRAN compiler command-line options CFLAGS C compiler command-line options TCLLIBS defines libraries needed for linking the Tcl shell TKLIBS defines libraries needed for linking the Tk shell SHARECMD command used to build shared (loadable) libraries SHARELIB extra libraries needed to build shared libraries SHSUFFIX suffix assigned for shared libraries LIB name of logic subroutine library TCL_CFLAGS defines locations for TCL include files TK_CFLAGS defines a command line option needed to compile the Tk shell NAMEOPTION Compiler flags that determine the naming conventions used in C for FORTRAN subroutines. (See below) COMPILATION SYMBOLS
There are differences the naming conventions by different FORTRAN and C compilers. To allow the code to be used on different platforms, two C macros must be defined account for this a header file (encode/logicmap.h) defines three different methods for remapping preprocessor options. These options are normally controlled by setting the NAMEOPTION variable.
ONESCORE where one _ is appended The SGI f77 compilier adds an underscore (_) to the names of FORTRAN subroutines.
TWOSCORE where one or two _ are appended The GNU g77 compilier adds an underscore to the names of FORTRAN subroutines except in the case of names that already contain an underscore, g77 adds two.
NOSCORE where no _ are appended The HP fort77 compilier does not add any underscores.
BIT16 used for 16 bit operating systems (are there any?) BIT32 used for 32 bit operating systems BIT64 used for 64 bit operating systems (none have been tested) -D is assumed as command line option used by the C compiliers to set preprocessor options from the command line.
In file encode/logicmap.h one of three preprocessor options is used to determine how to remap the names of subroutines.
If you see error messages of with undefined references to subroutines named ps_* or psl_* you have likely selected the wrong option here.
Neither the author nor the U.S. Government makes any warranty, expressed or implied, or assumes any liability or responsibility for the use of this information or the software described here. Brand names cited here are used for identification purposes and do not consitute an endorsement by NIST.Comments, corrections or questions: crystal@NIST.gov
Last modified 12-April-2002