Watcom Fortran - Running on the iPad!

It's possible to put "OpenWatcom Fortran" on the iPad, and compile and run your scientific Fortran programs.  Or do your own regression analysis, curve-fitting and graphics using the extensive Fortran open-source libraries.  

Currently, I have OpenWatcom running under DOSpad, and have confirmed the numbers are correct for the programs I have tested so far.  The trick is to install DOSpad, and then download and install the OpenWatcom F77 from: http://www.openwatcom.org/download.php

You want to download the "open-watcom-f77-dos-1.9.exe", and use "scp" to copy it from whereever you downloaded it, (probably putting in on your main working Windows or Linux box is easiest).  You then scp the downloaded  .exe file to the /var/mobile/Documents area on your jailbroken iPad.  You should confirm the MD5 hash matches, by running md5sum or some other utility to make sure the file is clean.  Once the install .exe is on the iPad, you start up DOSpad, and just run from a DOS session, to create the C:\Watcom directory and its various .exe's and libraries.  You will need to run the "autoexec.bat" file that the install process creates, which sets logical names for the include files and libraries.   You end up with a directory called /var/mobile/Documents/watcom, but it will be all DOS, so you have to first start DOSpad to edit and run Fortran programs.  Within DOSpad, you can compile and link and create runnable DOS .exe files, which can be run as if you were in a DOSbox or Cmd shell on a Windows box.   These .exe's make use of extenders (DOS4GW), so you have access to extended/expanded memory.   You can take a DOS-created .EXE and run it in a Windows Cmd shell, or under DOSbox on Android or DOSemu on Linux.  I've confirmed the .EXE files will run on Linux DOSemu (using CentOS 6.6, 32-bit, for example).  And with the jailbroken iPad, you can use serious files with real data, and move these between/among various platforms (Linux, Windows, Android, iPad, etc.)  

I've used this install procedure to put OpenWatcom F77 on my Huawei cellphone, (Android 5.1.1) and a Samsung Tab-A (Android 6.0.1), under GEMESYS Android version of DOSbox (gDOSbox), and the OpenWatcom Fortran works well there also.

Some examples of graphics and math routines are shown below...

OpenWatcom Fortran Example - PGDEMO.FOR

Program DEMO1.FOR, calculates sine values using Taylor series.

Results of Running DEMO1.FOR

Compile. Link and Create Executable PGDEMO.EXE - Presentation Graphics Demo.