Porting Code for Orbital Mechanics
I'm currently engrossed/engaged in a personal project in which I'm porting various useful programs that currently exist in Basic(IBM, Quick and GW) and Turbo Pascal to Python. My goal is to make said programs available to all, (with proper credit to the orginal authors, who have made the source code available to the public) in a format that is cross platform. It is a secondary goal to have these programs in a Python source format to serve as a useful teaching tool for those who wish to study the subject matter or the programming language.
Some thoughts arise: Some programs are small and easier to analyze, thus having the benefit of being easy to port, test and improve. One is complex, both in construction and in the math, making it easier to port modules and functions piecemeal. The hope is that after "re-assembling" and testing, that improvements and chances to recast the code (or refactor) will be obvious.
Some background: The small Basic programs are used for calculating antenna and circuit characteristics. The large Pascal program is used for calculating positions and such of earth-orbiting objects, like weather satellites. Other folks have built sucessful Delphi and C++ programs from the existing Pascal code, it is well documented and structured.
Any helpful hints for porting old Pascal code? (Note, I can read and understand the code, but don't currently have a copy of Turbo Pascal 7 for Dos in which to test and compare results with.)
q
I'm currently engrossed/engaged in a personal project in which I'm porting various useful programs that currently exist in Basic(IBM, Quick and GW) and Turbo Pascal to Python. My goal is to make said programs available to all, (with proper credit to the orginal authors, who have made the source code available to the public) in a format that is cross platform. It is a secondary goal to have these programs in a Python source format to serve as a useful teaching tool for those who wish to study the subject matter or the programming language.
Some thoughts arise: Some programs are small and easier to analyze, thus having the benefit of being easy to port, test and improve. One is complex, both in construction and in the math, making it easier to port modules and functions piecemeal. The hope is that after "re-assembling" and testing, that improvements and chances to recast the code (or refactor) will be obvious.
Some background: The small Basic programs are used for calculating antenna and circuit characteristics. The large Pascal program is used for calculating positions and such of earth-orbiting objects, like weather satellites. Other folks have built sucessful Delphi and C++ programs from the existing Pascal code, it is well documented and structured.
Any helpful hints for porting old Pascal code? (Note, I can read and understand the code, but don't currently have a copy of Turbo Pascal 7 for Dos in which to test and compare results with.)
q