20. Fortran 90 highlights
And there are many more features, too numerous to mention here.
Fortran 90 is very different from earlier versions of Fortran.
But for backwards compability, Fortran 77 has been included as a subset
of Fortran 90.
- Free format on source code.
- In Fortran 90, you can use either the Fortran 77 input format
or free format. If you use free format, the file extension .90
should be used for the file name.
- Dynamic allocation and pointers.
- It is now possible to allocate storage dynamically.
This enables us to finally get rid of all the "work" arrays!
- User defined data types.
- You can now define your own composite data types, similar to
struct in C or record in Pascal.
- Modules enables you to program in an object oriented style,
similar to C++. Modules can also be used to hide global
variables, thereby making the Fortran 77 common construct outdated.
- Recursive functions.
- Now a part of the language.
- Built-in array operations.
- Statements like A=0 and C=A+B are now valid when A and B are arrays.
There is also a built-in function for matrix multiplication (matmul).
- Operator overloading.
- You can define your own meaning of operators like + and = for your
own data types (objects).
[AMS Home Page]
[Fortran Tutorial Home]