MathScriptor
From Wikipedia, the free encyclopedia
| This article does not cite any references or sources. (November 2007) Please help improve this article by adding citations to reliable sources. Unverifiable material may be challenged and removed. |
| MathScriptor | |
|---|---|
MathScriptor v 1.7.4 running on Mac OS X. |
|
| Developed by | Robert R. Birge |
| Latest release | 1.8.9 / November 16, 2007 |
| OS | Cross-platform for Macintosh, Windows,Linux |
| Genre | Technical computing |
| License | Freeware |
| Website | http://www.mathscriptor.org |
Contents |
[edit] Description
Scriptor is a programming compiler developed by Robert R. Birge to introduce programming to undergraduates in all disciplines (Scriptor) or students in the sciences and engineering (MathScriptor). The extended basic language provides all of the intrinsics necessary for object-oriented structured programming. Scriptor and MathScriptor coexist within the same program and the student can switch between the two environments as needed. The program is available for download free of charge at http://www.mathscriptor.org and runs on Windows (98,2000,XP,Vista), Mac OS X and Classic, and Linux operating systems. Undergraduate and graduate level courses have been developed at the University of Connecticut using these programs. Scriptor is similar to other language teaching environments in that it is object-oriented and provides all of the elements necessary to maintain structure. MathScriptor is often the first program introduced to engineering students at the University of Connecticut and students exposed to this program find it easier to learn MatLab and Mathematica because the three programs share many similar features.
| Language and Computational Capabilities | Scriptor | MathScriptor | MatLab | Mathematica |
|---|---|---|---|---|
| Full Variable Support (boolean, color, constants, string, integer, real, double) | Y | Y | Y | Y |
| Methods with ByRef, ByVal, and Overloading Support | Y | Y | Y | Y |
| Module Functions with Extension Support | Y | Y | W | W |
| Modules (Private and Public methods and properties) | Y | Y | Y | Y |
| Classes (multiple constructors,destructors,and inheritance) | Y | Y | Y | W |
| Conditionals (if then...else if...else...end if) | Y | Y | Y | Y |
| Loops (for...next, do until...loop until, while...wend, exit) | Y | Y | Y | Y |
| Case Statements (select case...case if...case is...else...end select) | Y | Y | Y | Y |
| Strings Level 1 (val,format,mid,left,right,nthfield,replace,etc.) | Y | Y | Y | Y |
| Strings Level 2 (Regular Expressions, Levenshtein, Soundex) | Y | Y | W | Y |
| Encyption and Decryption Statements (Hash, Blowfish, Swordfish) | Y | Y | W | Y |
| Music (Midi instrument control statements) | Y | Y | W | Y |
| Graphics (1D and 2D Plotting including filled/lined contours) | Y | Y | Y | Y |
| Graphics (3D Plotting) | W | Y | Y | Y |
| Fourier Transforms (1D and 2D) | Y | Y | Y | Y |
| Wavelet Transforms (1D and 2D) | W | Y | Y | Y |
| Numerical Integration (Laguerre and Lagrangian) | IN | Y | Y | Y |
| Matrix Operations Level 1 (multiply, transpose, invert, print) | IN | Y | Y | Y |
| Matrix Operations Level 2 (linear algebra, eigenvector, eigenvalue) | W | Y | Y | Y |
| Matrix Operations Level 3 (singular value decomposition) | W | Y | Y | Y |
| Symbolic Math | W | W | W | Y |
| Arbitrary Precision Numbers and Functions | W | Y | IN | Y |
| Interface Statements (serial input and output) | W | Y | Y | W |
| Interface Statements (http: open socket I/O) | W | Y | IN | W |
| Interface Statements (UDP, TCP, https: secure socket I/O) | W | V | IN | W |
| Interface Statements (USB Vernier LabPro Instrument I/O) | W | V | IN | W |
| Asynchronous User Input via Keyboard | Y | Y | IN | Y |
| Asynchronous User Input via Mouse | Y | Y | IN | Y |
| Synchronous User Input via Keyboard | Y | Y | Y | Y |
| Synchronous User Input via Mouse | Y | Y | IN | Y |
| Y | Feature fully supported as a language intrinsic |
| W | Feature weakly supported via external packages |
| IN | Feature indirectly supported via external packages |
| V | Feature to be added in version 2.0 |
[edit] History
Scriptor was originally created in 2002 by Robert R. Birge [1] at the University of Connecticut for teaching object oriented programming to undergraduates. The program is compatible with Windows(98,2000,XP,Vista), Mac OS X and Classic and the common Linux operating systems. The front end is written in RealBasic and uses the RBScript compiler provided by RealSoftware, Inc. Additional functionality is provided by using plugins written in C and C++. The program evolved to include advanced numerical features relevant to teaching numerical methods to graduate students, and MathScriptor was created as an enhanced scientific and engineering version of Scriptor. As time evolved, contributions from over 20 other programmers enhanced the power of MathScriptor to include arbitrary precision numbers, advanced string operations (including regular expressions) and a full set of matrix operations based on public versions of Linpack.
[edit] Obtaining Scriptor and MathScriptor
Scriptor and MathScriptor reside within the same program, which is designed to function inside a folder that contains templates, programs, and support files. The programs and environment are free and can be downloaded from http://www.mathscriptor.org. However, access to MathScriptor requires the user to be registered. Instructions are included in the Registration folder which is included with the environment download. As of November 2007, the current version is 1.8.9.
[edit] Programming using Scriptor and MathScriptor
Scriptor is designed to make programming intuitive and enjoyable while providing a rich object-oriented structured environment. Because all of the features of Scriptor are present in MathScriptor, we will make reference to Scriptor in most of this discussion. Scriptor is intended primarily as an OOP learning platform while MathScriptor is intended primarily for scientific and engineering OO programming. Both platforms reside within the same program and a registered user can switch between the two environments at will by using a single menu item. Only a registered user can access MathScriptor, which provides additional math functions (expanded integration, wavelet transformations, additional matrix operations), access to external objects, web access under program control and the ability to save compiled code instead of just source code. (The Scriptor environment can run programs compiled by MathScriptor.) The advantage of working in Scriptor during the learning process is that MathScriptor's additional features and complexity can create problems for the beginning programmer that are difficult to diagnose.
Both Scriptor and MathScriptor compile the program when the Run button is pressed and then the compiled code is executed. Compilation usually takes less than one second (a 2000 line program requires about 3 seconds on a PC or Mac with a 1GHz CPU). However, in Scriptor the source code is always kept in the programming editfield, and the compiled program is discarded after the program stops or is interrupted by the user using the stop button. The only additional compiler feature provided by the MathScriptor environment is that one can save the compiled version for distribution to others when one does not want the recipient to have access to the source code.
Scriptor is a cross-platform Tabbed Integrated Development Environment (TIDE) created by Robert R. Birge using RealBasic, an extended basic language developed by Real Software Inc. Additional functionality is provided by using plugins that have been written in Fortran and C++. RealBasic is a high-level object oriented language that shares more similarities to Fortran 90, Pascal, and C++ than to the original versions of BASIC. There is no perfect choice for a first language, but for science students, extended basic is the best. Because Scriptor supports method overloading, classes with constructors and destructors, modules, functions, and subroutines, all of the key principles of object-oriented programming can be taught within a simple, user-friendly environment.
Scriptor provides access to all of the statements within RealBasic necessary to learn object-oriented and structure programming. (RealBasic is too expensive and has too steap an initial learning curve to use in a first semester course for the average student.) All applications developed using Scriptor must be run either within the Scriptor TIDE or as part of an autostart package, which allows a user to create a complete application package that runs with a double click. This limitation is an advantage during the learning process because the student is freed from having to learn the intricacies of writing code associated with a graphics user interface (GUI). Because Scriptor is cross-platform, source and compiled code generated on a PC can be run without problems on an Apple Macintosh computer under Mac OS X or Mac OS 9 and on most Linux environments. Furthermore, the Scriptor source code can be copied and pasted into Microsoft Word while retaining the colored styled-text formatting. The latter capability is invaluable to both faculty and students preparing discussions of program logic and function.
[edit] Using Scriptor and MathScriptor in Teaching
The following two course outlines describe the topics covered by two courses taught at the University of Connecticut. The undergraduate course, INTD-291, is an honors course in programming and provides an introduction to students who have no prior programming experience. The upper-division undergraduate and first year graduate course, CHEM-393, is designed primarily for science majors. This course relies more heavily on the mathematical capabilities inherent in MathScriptor.
| Introduction to Programming (INTD291) | |
| *Introduction to Scientific Programming (CHEM-393) | |
| 1.Programming using Scriptor and MathScriptor | |
| 2.Introduction to objects and structure (biological/behavioral analysis) | |
| 3.Expressions,assignments,and simple data types | |
| 4.Arrays,strings,and regular expressions | |
| 5.Conditionals(if then.. else if..else..end if, select case..case..case is..case in..else..end select) | |
| 6.Loops (for...next,do until...loop until,while...wend,exit) | |
| 7.Methods (functions, function extends, subroutines, ByVal and ByRef variables) | |
| 8.Modules [private(local) and public(global) variables and methods] | |
| 9.Classes (constructors,destructors,instantiation and initialization) | |
| 10.*External Objects and Compilation (MathScriptor) [CHEM393 Only] | |
| 11.Method Overloading (and code simplification) | |
| 12.Advanced Object-oriented methods (polymorphism, inheritance, class interfaces) | |
| 13.Optimizing structure for readability and speed | |
| 14.Events and Controls (towards more complex objects) | |
| 15.Graphics (displaying and plotting data, *contour plots, *resolution enhancement) | |
| 16.Handling files (text,data,graphics,and binary) | |
| 17.Refactoring [cleaning up code after the fact (based on Fowler's book)citation needed] | |
| 18.Exceptions (handling failures with dignity) | |
| 19.Algorithms Part 1 (sorting,least squares and simplex fitting, encryption, decryption) | |
| 20.Algorithms Part 2 (Runge-Kutta methods, 1D and 2D Fourier transforms, Fourier Self-Deconvolution, Maximum Entropy, 1D and 2D wavelet transforms) [CHEM 393 Only] | |
| 21.Algorithms Part 3 (Eigenvector-eigenvalue theory, singular value decomposition, Newton Raphson, nonlinear least squares, arbitrary precision methods) [Chem 393 Only] |

