Evgenii B. Rudnyi

Home Teaching Programming Publications

Content:

Overview

Code Name Description Language Compiles with gcc 3.3 Required libraries (not included)
ruscga Converting Cyrillic letters on CGA Assembler n/a
msd Second and Third Law treatment of mass spectrometry data Fortran yes
eqconst Simultaneous treatment of equilibrium constants Fortran yes Lapack or old Fortran IMSL
kcl Vaporization thermodynamics of KCl (variance component analysis) Fortran yes old Fortran IMSL
plasma Computing equilibrium composition in air plasma Fortran yes VCS from Smith's book
task Generating problem sets for students C++ no
varcomp Variance component analysis under linear error model C++ yes old Fortran IMSL
bacuy_eq Computing phase diagram of Ba-Cu-Y C++ yes DONLP2
sid2user, user2sid Usefull NT utilities for a hacker C++ no Win32 API
species A class of chemical species C++ no
tdlib Computational chemical thermodynamics C++ yes
mor4ansys Model order reduction for ANSYS models C++ yes
Post4MOR Postprocessing model reduction results Mathematica, Python n/a
quadpack Mathematica quadpack interface C++, Mathematica yes for C++ part
ANSYSRecords, ANSYSEmat Reading ANSYS binary files from Mathematica C++, Mathematica yes for C++ part ANSYS bin
slicot Mathematica Slicot interface C++, Mathematica yes for C++ part SLICOT
webbook Web book about NT VBScript, ASP n/a text by itself
pyros Micropyros software webMathematica n/a ANSYS scripts
R-Cite Bibliography software under Paradox PAL: Paradox Application Language n/a

Top

Short History

I started programming when I was a student. I was in the 13th group at Chemistry Department of Moscow State University. Traditionally this group specialized in computing in chemistry. Many thanks to M. G. Anashkin who was responsible for our group. He has made a lot to give us the best access to computational resources that have been available at that time.

I started with MIR-2 and then from 1979 to 1988 was working on BESM-6. A cool thing. I worked from a terminal although occasionally I even used punch cards. I had about 6 Kb of space on my student account and hence needed to keep my program at the tape. In order to edit a program on the tape it was necessary to write a special editing job. ed-like editing, not speaking of vi, was a dream.

In 80th, we also had Elektronika D3-28 (at the middle of the linked page) at the lab. It was possible to enter assembler from a keyboard and then to save the code to the tape. Since the middle of 80th, there were SM-4 minicomputers as well.

I switched to PC since 1989 and then since 2001 was back to the real thing: Sun Ultra (4 processors with 4 Gb of RAM).

FORTRAN-IV was a natural choice for the first programming language. The slogan of that time was "Real Programmers Don't Use Pascal". During PC time I switched to Fortran 77. Yet, after I had written kcl, I understood that it is time to search for another programming language and switched to C++. I still like it.

At IMTEK, I used Mathematica for rapid prototyping. Well, I worked with Reduce during 90th but only at IMTEK I have learned the beauty of Lisp. I would say that Mathematica is Lisp with a human face.

At present, I am using Python with SciPy for rapid development.

Codes presented at this page are from my archives. They are available under the GNU public license.

Top

Assembler

I do not like programming in assembler. Yet, in the case described below there was no choice. I used Borland Turbo Assembler at that time.

ruscga: Converting Cyrillic Letters on CGA

Download

In 1990-1993, I used to have a Toshiba laptop with a CGA-like card without a Russian font. This meant that when I opened a file in Russian, I saw some strange characters instead of Cyrillic letters and there was no way to change it at the software level.

Finally, I have written in assembler a small resident program (ruscga) that converted Cyrillic letters to English equivalent. Not really nice but at least I was able to read the text.

Top

Fortran

I do not remember the names of Fortran compilers for BESM-6 and SM-4. During PC time, I have used Lahey. I liked it a lot. I get used to some Lahey extenstions, like "PRINT,something" or "OPEN (1,'filename')" and I needed to fix it to compile the code under g77. I have switched to g77 in 1998.

My thoughts about Fortran, "Let Fortran die naturally".

msd: Second and Third Law Treatment of Mass Spectrometry Data

Download

msd is a small interactive program that I have written to process ion currents measured by high temperature mass-spectormetry. The goal was to make a simple statistical treatment and then determine enthalpies and entropies of a reaction by so called Second and Third Law (widely accepted slang in high temperature mass spectrometry).

The program was written in Fortran-IV for soviet SM-4 minicomputer, I guess, in 1984. Then in 1993 I have compiled it for PC with Lahey compiler. At that time, Cyrillic characters in help have been converted to English letters as many people had a PC with a CGA card without a Russian font.

From a modern viewpoint, it is rather primitive but at that time many students used it.

Top

eqconst: Simultaneous Treatment of Equilibrium Constants

Download

eqconst is a program that I have written in 1992 for my papers on the simultaneous treatment of equilibrium constants. Mathematically speaking, this is multivariant regression. The goal was to apply it for my special case. Basically, this is rather straightforward linear algebra.

The archive also contains the data files with the experimental equilibirum constants from the papers. In my view, the file format was not that bad as compared with conventional Fortran datafiles.

It is necessary to have either LIN3VP from IMSL or Lapack.

kcl: Vaporization Thermodynamics of KCl (Variance Component Analysis)

Download

This is the code that I wrote to make computations for papers on KCl. I have made it in 1992 for Lahey compiler at my PC. The archive also contains the original datafile with experimental results from many papers.

Mathematically speaking, this the maximum likelihood for a special case. Requirements: IMSL subroutines ZXSSQ and LINV3P.

The code is inflexible: using it for another case means almost a complete re-write. Yet, there were no way to make it flexible in Fortran 77 and since then I switched to C++. Technically speaking, I needed an array of pointers to functions not speaking of memory managment. The next step in this direction was varcomp.

Top

plasma: Computing Equilibrium Composition in Air Plasma

Download

The archive contains a sample code that I have written in 1993-1998 to compute equilibrium composition for my papers. The code is rather simple: this is a loop to run VCS several times to produce a file with results for plotting. The archive also contains the Gibbs energies required for computations.

Requirements: VCS subroutine from Smith and Missen's book.

Top

C++

I used Borland C++ from version 2.0 to 5.01. Since 1999 I use gcc.

task: Generating Problem Sets for Students

Download

task is pretty a simple code written in 1993 to make a random list of questions for a student from the database. At that time, I was using CHIWRITER, so the program reads a CHIWRITER file and them make another CHIWRITER file for a printout. I was learning C++ at that time, and task.cpp is a wild mixture of C and C++. What I like most now is the manual (in Russian).

Top

varcomp: Variance Component Analysis under Linear Error Models

Download

varcomp is a library to perform the maximum likelihood method under the linear error model. First version was in 1994. I have used it extensively for many papers from 1994 to 1998. This was a huge improvement after kcl. It simplified the development of the code to make a paper significantly.

The archive contains the library, the code specific for each paper and the datafiles.

My next development in this direction was tdlib where I tried to reduce the programming to minimum in order to solve an application problem.

Top

bacuy_eq: Computing Phase Diagram of Ba-Cu-Y

Download

Computation of equilibrium composition in the multi-phase, multi-component system is a challenge. Mathematically speaking, this is a search for global minimum. The main problem is to find the global minimum indeed. The difference with other global minimization problems is that a good physical background and a criterion to check whether the minimum is global are available.

The code was my try to couple DONLP2 (Do NonLinear Programming) with an initial guess found from the physical background based on linear programming. It worked nicely for a three-component system in question. The question whether this approach can be generalized to four- and more- component systems is to be researched.

Top

sid2user and user2sid: Usefull NT Utilities for a Hacker

Download

I have written this in 1998 during the work on the book. These are simple codes with a pretty straightforward calls to Win32 functions LookupAccountName and LookupAccountSid. The most interesting was their creative use (see my message to NTBugtraq in the archive with the code).

Many, many people, working with Windows, used these utilities. For example, they were included in Hacking Exposed (as result, I got a book for free). You can browse Google results for sid2user.

Top

tdlib: Computational Chemical Thermodynamics

tdlib manual, Download (manual included)

tdlib was my major programming project from 1995 to 2000. Its feature was XML-like external representation for the developed classes. This was an effort to make a uniform computational framework for computational chemical thermodynamics. On one side, there were several iterations after species, on another, a new version of varcomp. The main drawback is that there is still no good solver to compute equilibrium in a multiphase system. Currently, this is possible only when co-existing phases are given. Originally to this end, I planned to generalize bacuy_eq, but I did not have time to accomplish it. It happened that for inverse tasks this was not the the major problem as one usually knows co-existing phases in this case.

Top

MOR for ANSYS (former mor4ansys): Model Order Reduction for ANSYS Models

MOR for ANSYS site

I have started working on model reduction in 2001 and on mor4ansys in 2003. From a programming viewpoint, this is much simpler than tdlib. The main problem here is in software integration. In order not to re-invent the wheel, one should use libraries. Yet, it also takes time to learn, hack, compile and link. I guess that it will take at least a few days for someone to make a mor4ansys binary if he is not familiar with the background libraries. Well, it is necessary to compile them first. And then linking. It is another song. By the way, a nice book in this respect is Linkers and Loaders.

Top

Mathematica

I started using Mathematica in 2001. I should say that I like its clean language.

Post4MOR: Postprocessing Model Reduction Results

Download the code

mor4ansys produces a compact model in the Matrix Market format. I use Mathematica to make transient and harmonic simulation for compact models produced by mor4ansys.

Top

Interface for quadpack

Download the code

This was an example for Mathematica Developer Conference on how to create a Mathlink application in order to interface an external code when a user function is defined within Mathematica. I have used a numerical integration with quadpack to demonstrate this. Alternatively, download the paper:

O. Ruebenkoenig, E. B. Rudnyi, J. G. Korvink.
MathLink + Netlib = MathLib.
2003 Mathematica Developer Conference.
Paper at library.wolfram.com.

Top

AnsysRecords and AnsysEmat: Reading ANSYS Binary Files

Download the code

Before I have written mor4ansys, I developed a Mathlink interface in order to play with ANSYS binary files from within Mathematica. I made a Mathlink interface to the ANSYS bin library.

Top

Interface for SLICOT

Download the code

Yet another Mathlink interface to SLICOT routines on model reduction. It supports Balance & Truncate model reduction (BTA) AB09AD; Singular perturbation approximation based model reduction (SPA) AB09BD; Hankel norm approximation based model reduction(HNA) AB09CD.

Interface for DOT

Download the code

An experimental version of a Mathlink interface for Design Optimization Tools (DOT).

Top

Web Applications

I started writing in HTML in 1993. Mostly these were static pages. Two dynamic applicatiions are below.

webbook: NT Web Book

Download

This is a Web-application written in VBScript for IIS 4 in 1999. The goal was to make an interactive book about NT Server. The book by itself is not included (pages listed in global.asa). The idea was from Vasilii Lutsarev. It used to work under IIS 4.

Top

pyros: Micropyros Software

Micropyros Software web page, Download

The application has been created during the Micropyros project in 2002-2003. It is written under webMathematica. The code consists from normal Mathematica scripts defining useful functions and Web pages that call these functions on the server side.

Top

Databases

I learnt Paradox during my stay at NIST.

R-Cite: Bibliography Software under Paradox

Download

This is my application R-Cite written in Paradox Application Language (PAL ) in 1992 under Paradox 3.5. I have written it to handle my literature references. I have used it a lot for myself in 90s but nowadays I would recommend you Endnote.

Top