Skip to content

priyankmodiPM/GasSimulator

 
 

Repository files navigation

GasSimulator

The aim of this repo is to build a tool and a semi-automated algorithm, to convert FORTRAN code to python

RECENT

broken into rough modules:
Structure :

  • degrad1.py + Mipcalc.py + CsstfbN.py + CalcbN.py + csstfNe.py + csstfN.py + Calcn.py + cgasn.py + gasn.py

Added f2py interface example code in testing directory. Code file -> ftype . Terminal Screenshot -> Screenshot

magboltz.py is the lastest conversion

Features of change.py currently :

1.map arithematical operators from FORTRAN to corresponding in python
2.map logical operators from FORTRAN to corresponsing operators in python
3.retain comments as comments
4.map dabs,dsqrt,dlog,dexp functions correctly
5.replace FORTRAN do to Python for-loop
6.replace irrelevant conditions like endif
7.add : after function definition
8.remove datatype declarations

Installing F2Py

cd testing/F2PY-2.45.241_1926<br>
sudo python setup.py install<br>
cd ../scipy_distutils-0.3.3_34.586<br>
sudo python setup.py install<br>

Using input interface of degrad

Installation

sudo pip3 install --user pyqt5  
sudo apt-get install python3-pyqt5  
sudo apt-get install pyqt5-dev-tools
sudo apt-get install qttools5-dev-tools

Tutorial PyQt5

Notes

WRITE FORMAT

A - text string
D - double precision numbers, exponent notation
E - real numbers, exponent notation
F - real numbers, fixed point format
I - integer
X - horizontal skip (space)
/ - vertical skip (newline)

About

The aim of this repo is to build a tool and a semi-automated algorithm, to convert FORTRAN code to python

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 65.6%
  • Fortran 33.8%
  • Other 0.6%