LogoopenSUSE Build Service > Projects
Sign Up | Log In

Python interface generator for Fortran based codes

Forthon generates links between Fortran95 and Python. Python is a high level, object oriented, interactive and scripting language that allows a flexible and versatile interface to computational tools. The Forthon package generates the necessary wrapping code which allows access to the Fortran database and to the Fortran subroutines and functions. This provides a development package where the computationally intensive parts of a code can be written in efficient Fortran, and the high level controlling code can be written in the much more versatile Python language.

The developer creates an interface file that describes what part of the fortran is to be accessible from Python. Variables defined in Fortran modules can be made accessible, including scalars, arrays, and variables of derived type. A subset of the Fortran subroutines, as specified in the interface file, can be called from Python, with argument lists including scalars, arrays, and variables of derived type. Arrays can be statically dimensioned or dynamically dimensioned, in which case Fortran95 style pointers are used. Variables of derived type can be pointers, and derived types can have elements which are themselves derived types or pointers to derived types. A tool is included which will automatically compile the user's source code and the generated wrapping code into a Python module.

Source Files

Filename Size Changed Actions
Forthon-0.8.15.tgz 88.5 KB Download File
buildfixes.patch 518 Bytes Download File
python-Forthon.spec 2.38 KB Download File

Comments for home:zhonghuaren (0)

Login required, please login or signup in order to comment