1 / 15

Introduction to IMSL and VNI

Introduction to IMSL and VNI. Welcome to OIT’s seminar on IMSL Numerical Libraries Sam Gordji, ccsam@olemiss.edu Weir 107. List of VNI Packages. IMSL IMSL for Fortran is a comprehensive package containing Math, stat., and special functions

sonora
Télécharger la présentation

Introduction to IMSL and VNI

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Introduction to IMSL and VNI Welcome to OIT’s seminar on IMSL Numerical Libraries Sam Gordji, ccsam@olemiss.edu Weir 107

  2. List of VNI Packages IMSL • IMSL for Fortran is a comprehensive package containing Math, stat., and special functions • IMSL for C++ is a comprehensive package containing Math, stat., and special functions • IMSL is available only on sweetgum • IMSL is a set of subroutines called by a Fortran, Python, or C program

  3. Accessing Fortran on sweetgum • sweetgum is a Unix server housed in the data center building • sweetgum is primarily used by researchers that have large number crunching programs • Limited knowledge of Unix system is needed to run Fortran and IMSL

  4. Fortran and IMSL may be accessed from the network. Steps to access sweetgum from a Windows PC Request a sweetgum account from assist@mcsr.olemiss.edu Download/Install SSH Secure Shell Client from http://www.mcsr.olemiss.edu/appssubpage.php?pagename=ssh2.inc Click “Secure Shell Client” Accessing Fortran on sweetgum

  5. sweetgum is ready to execute Fortran jobs Accessing Fortran on sweetgum

  6. A Few Useful Unix Commands • cat --- for displaying a file • cd --- change directory • cd 1--- to move to sub-directory 1 & so on • cp --- for copying files • rm --- remove a file • pico --- a Unix editor

  7. A Few Useful Unix Commands • “pwd” to print working directory • “ls” to list files in working directory • To view a program, enter “cat file-name.f” • To launch a Fortran program, enter “f90 file-name.f” • To attend a Unix seminar, please contact assist@mcsr.olemiss.edu

  8. Running IMSL on a PC • IMSL PC version is available for C • Users need to have their own copy of C

  9. Topics of the Day • Creating a simple Fortran Program • Running a few Fortran Program w/ and w/o IMSL (nonlin.f, mcsr.f, and test.f) • Looking at some aspects of Fortran & IMSL • Download Fortran programs from sweetgum: /usr/local/appl/examples

  10. Importing a Fortran Program into sweetgum • Download your Fortran program to your desktop • In sweetgum enter “ vi mcsr.f ” • Press “ enter ” • Enter “ i ” • Copy and paste your Fortran program from your desktop • Enter “ : ” • Enter “ wq ” and press enter to save your program which you named “ mcsr.f ”

  11. Text copy of mcsr.f • PARAMETER (IPATH=1, LDA=3, N=3) • REAL A(LDA,LDA), B(N), X(N) • c This is a comment line. Above 2 lines define the parameters needed for matrix inversion • c Set values for A and B • c • c A = ( 33.0 16.0 72.0) • c (-24.0 -10.0 -57.0) • c ( 18.0 -11.0 7.0) • c Above is the Matrix A and below is the vector B • c B = (129.0 -96.0 8.5) • c • DATA A/33.0, -24.0, 18.0, 16.0, -10.0, -11.0, 72.0, -57.0, 7.0/ • DATA B/129.0, -96.0, 8.5/ • c Below subroutine LSLRG is called to solve the 3 by 3 equation • CALL LSLRG (N, A, LDA, B, IPATH, X) • c Print results • CALL WRRRN ('X', 1, N, X, 1, 0) • END

  12. Running Fortran on sweetgum • To create an executable on sweetgum enter f90 $F90FLAGS –o mcsr mcsr.f $LINK_F90 • To run a script called “mcsr", simply enter mcsr • Please note that the executable in this case is called “mcsr"

  13. Output of mcsr.f • The solution for the 3 by 3 system of equations is: • X • 1 2 3 • 1.000 1.500 1.000

  14. General Information • IT staff will assist users to access these packages. We also assist users to find the proper procedure to analyze their data. If you need assistance please send an email to Sam Gordji at ccsam@olemiss.edu, assist@mcsr.olemiss.edu , or mathadm@olemiss.edu

  15. General Information • Email contact • assist@mcsr.olemiss.edu • To download this and other materials visit: http://www.mcsr.olemiss.edu/educationsubpage.php?pagename=febcamp09.inc • Please fill out the performance report and leave your email address so we may contact you for follow up questions

More Related