Main navigation

How to use the ScaLAPACK Library

These instructions will be revised for the new Intel compiler [2013Mar18].

Installation location: /u/local/apps/scalapack/current/ib

How to run ScaLAPACK from a Fortran 90 Program

To compile and link enter on a single line:

mpif90 pgm.f90 -L$SCALAPACK_HOME -lscalapack -lblacsF77init -lblacs -lblacsF77init -L$BLAS_HOME -lblas -L$LAPACK_HOME -llapack -o pgm

  • Replace pgm.f90 with the name of the file containing your source code.
  • Replace i>pgm with the name of the executable to be created.
  • Set SCALAPACK_HOME /u/local/apps/scalapack/current/ib
  • Set BLAS_HOME /u/local/apps/blas/current
  • Set LAPACK_HOME /u/local/apps/lapack/current

You can either set these as environment variables or replace the strings in the command shown above.

How to run ScaLAPACK from a Fortran 77 Program

To compile and link enter on a single line:

mpif77 pgm.f -L$SCALAPACK_HOME -lscalapack -lblacsF77init -lblacs -lblacsF77init -L$BLAS_HOME -lblas -L$LAPACK_HOME -llapack -o pgm

  • Replace pgm.f with the name of the file containing your source code
  • Replace pgm with the name of the executable to be created
  • Set SCALAPACK_HOME /u/local/apps/scalapack/current
  • Set BLAS_HOME /u/local/apps/blas/current
  • Set LAPACK_HOME /u/local/apps/lapack/current

You can either set these as environment variables or replace the strings in the command shown above.

Report Typos and Errors
UCLA OIT

© 2016 UC REGENTS TERMS OF USE & PRIVACY POLICY