chrpak
chrpak,
a FORTRAN77 code which
can handle characters and strings of characters.
The code began when I simply wanted to be able to capitalize
a string. Now it has expanded to a number of interesting uses.
Many unusual situations are provided for, including
-
string '31.2' <=> numeric value 31.2;
-
uppercase <=> lowercase;
-
removal of control characters or blanks;
-
sorting, merging, searching.
Many of the routine names begin with the name of the data type they
operate on:
-
B4 - a 4 byte word;
-
CH - a character;
-
CHVEC - a vector of characters;
-
DEC - a decimal fraction;
-
DIGIT - a character representing a numeric digit;
-
I4 - an integer ( kind = 4 );
-
R4 - a real ( kind = 4 );
-
R8 - a real ( kind = 8 );
-
RAT - a ratio I/J;
-
S - a string;
-
SVEC - a vector of strings;
-
SVECI - a vector of strings, implicitly capitalized;
Licensing:
The computer code and data files described and made available on this web page
are distributed under
the GNU LGPL license.
Languages:
chrpak is available in
a C version and
a C++ version and
a FORTRAN77 version and
a FORTRAN90 version and
a MATLAB version and
a Python version.
Related Programs:
chrpak_test
Reference:
-
Carl Branden, John Tooze,
Introduction to Protein Structure,
Second Edition,
Garland Publishing, 1999,
ISBN: 0815323050,
LC: QP551.B7635.
-
Paul Bratley, Bennett Fox, Linus Schrage,
A Guide to Simulation,
Second Edition,
Springer, 1987,
ISBN: 0387964673,
LC: QA76.9.C65.B73.
-
IEEE Standards Committee 754,
IEEE Standard for Binary Floating Point Arithmetic,
ANSI/IEEE Standard 754-1985,
SIGPLAN Notices,
Volume 22, Number 2, 1987, pages 9-25.
-
Donald Knuth,
The Art of Computer Programming,
Volume 3, Sorting and Searching,
Second Edition,
Addison Wesley, 1998,
ISBN: 0201896850,
LC: QA76.6.K64.
-
Albert Nijenhuis, Herbert Wilf,
Combinatorial Algorithms for Computers and Calculators,
Academic Press, 1978,
ISBN: 0-12-519260-6,
LC: QA164.N54.
Source Code:
Last revised on 23 September 2023.