<!-- hamlet
<!-- copytar
examples/                                                                                              755    1107     770            0  5477466235   5727                                                                                                                                                                                                                                                                                                                                                                      examples/sroot.f                                                                                       644    1107     770          660  5477466234   7312                                                                                                                                                                                                                                                                                                                                                                            PROGRAM ROOT
C
C Computes and prints the square root of a REAL
C
      IMPLICIT NONE
      REAL X, Y

      PRINT *, 'Please enter a positive real number: '
      READ *, X
      Y = SQRT(X)
      PRINT *, 'The square root of ', X, ' is ', Y

      Y = SQRT(X)*SQRT(X)
      PRINT *, 'The square of the square root of ', X, ' is ', Y

      PRINT *, 'Once again, the square root of ', X, ' is ', SQRT(X)

      STOP
      END
                                                                                examples/max.f                                                                                         644    1107     770          602  5477466234   6725                                                                                                                                                                                                                                                                                                                                                                            PROGRAM MAXPRG
C
C Demonstrates the use of MAX
C
      IMPLICIT NONE
      REAL X,Y
      INTEGER I,J

      PRINT *, 'Please enter two real numbers: '
      READ *, X, Y
      PRINT *, 'The larger of the two numbers is ', MAX(X,Y)

      PRINT *, 'Please enter two integers: '
      READ *, I, J
      PRINT *, 'The larger of the two numbers is ', MAX(I,J)

      STOP
      END
f ', X, ' is ', SQRT(X)

      STOP
      END
                                                                                examples/user1.f                                                                                       644    1107     770         1041  5477466234   7215                                                                                                                                                                                                                                                                                                                                                                            PROGRAM USRDEF
C
C This program motivates the utility of user-defined functions
C
      IMPLICIT NONE
      REAL X, Y, Z
      
      PRINT *, 'Please enter a real number'
      READ *, X
      PRINT *, 'The base two logarithm is ', LOG10(X)/LOG10(2.0)

      PRINT *, 'Please enter another real number'
      READ *, Y
      PRINT *, 'The base two logarithm is ', LOG10(Y)/LOG10(2.0)

      PRINT *, 'Please enter a third real number'
      READ *, Z
      PRINT *, 'The base two logarithm is ', LOG10(Z)/LOG10(2.0)

      STOP
      END
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               examples/user2.f                                                                                       644    1107     770         1307  5477466235   7224                                                                                                                                                                                                                                                                                                                                                                            REAL FUNCTION LOG2 (A)
C
C This function computes the base two logarithm of A
C
      IMPLICIT NONE
      REAL A
      
      LOG2 = LOG10(A)/LOG10(2.0)

      RETURN
      END



      PROGRAM USRDEF
C
C This program motivates the utility of user-defined functions
C
      IMPLICIT NONE
      REAL LOG2
      REAL X, Y, Z
      
      PRINT *, 'Please enter a real number'
      READ *, X
      PRINT *, 'The base two logarithm is ', LOG2(X)

      PRINT *, 'Please enter another real number'
      READ *, Y
      PRINT *, 'The base two logarithm is ', LOG2(Y)

      PRINT *, 'Please enter a third real number'
      READ *, Z
      PRINT *, 'The base two logarithm is ', LOG2(Z)

      STOP
      END
                                                                                                                                                                                                                                                                                                                         examples/escape.f                                                                                      644    1107     770         1114  5477466235   7420                                                                                                                                                                                                                                                                                                                                                                      C Calculates and displays escape velocities
C
C Created: Joe Zachary, September 27, 1992
C Modified:



      PROGRAM VELOCITY

      IMPLICIT NONE
      REAL ESCAPE
      REAL EMASS, MMASS, JMASS, ERADIUS, MRADIUS, JRADIUS

      PARAMETER (EMASS=6.0E24, MMASS=7.4E22, JMASS=1.9E27)
      PARAMETER (ERADIUS=6.4E6, MRADIUS=1.7E6, JRADIUS=7.1E7)

      PRINT *, 'Here are three escape velocities in meters/sec:'

      PRINT *, 'Earth:  ', ESCAPE(EMASS, ERADIUS)

      PRINT *, 'Moon:  ', ESCAPE(MMASS, MRADIUS)

      PRINT *, 'Jupiter: ', ESCAPE(JMASS, JRADIUS)

      STOP
      END

ease enter a third real number'
      READ *, Z
      PRINT *, 'The base two logarithm is ', LOG2(Z)

      STOP
      END
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         examples/                                                                                              755    1107     770            0  5477466235   5727                                                                                                                                                                                                                                                                                                                                                                      examples/sroot.f                                                                                       644    1107     770          660  5477466234   7312                                                                                                                                                                                                                                                                                                                                                                            PROGRAM ROOT
C
C Computes and prints the square root of a REAL
C
      IMPLICIT NONE
      REAL X, Y

      PRINT *, 'Please enter a positive real number: '
      READ *, X
      Y = SQRT(X)
      PRINT *, 'The square root of ', X, ' is ', Y

      Y = SQRT(X)*SQRT(X)
      PRINT *, 'The square of the square root of ', X, ' is ', Y

      PRINT *, 'Once again, the square root of ', X, ' is ', SQRT(X)

      STOP
      END
                                                                                examples/max.f                                                                                         644    1107     770          602  5477466234   6725                                                                                                                                                                                                                                                                                                                                                                            PROGRAM MAXPRG
C
C Demonstrates the use of MAX
C
      IMPLICIT NONE
      REAL X,Y
      INTEGER I,J

      PRINT *, 'Please enter two real numbers: '
      READ *, X, Y
      PRINT *, 'The larger of the two numbers is ', MAX(X,Y)

      PRINT *, 'Please enter two integers: '
      READ *, I, J
      PRINT *, 'The larger of the two numbers is ', MAX(I,J)

      STOP
      END
f ', X, ' is ', SQRT(X)

      STOP
      END
                                                                                examples/user1.f                                                                                       644    1107     770         1041  5477466234   7215                                                                                                                                                                                                                                                                                                                                                                            PROGRAM USRDEF
C
C This program motivates the utility of user-defined functions
C
      IMPLICIT NONE
      REAL X, Y, Z
      
      PRINT *, 'Please enter a real number'
      READ *, X
      PRINT *, 'The base two logarithm is ', LOG10(X)/LOG10(2.0)

      PRINT *, 'Please enter another real number'
      READ *, Y
      PRINT *, 'The base two logarithm is ', LOG10(Y)/LOG10(2.0)

      PRINT *, 'Please enter a third real number'
      READ *, Z
      PRINT *, 'The base two logarithm is ', LOG10(Z)/LOG10(2.0)

      STOP
      END
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               examples/user2.f                                                                                       644    1107     770         1307  5477466235   7224                                                                                                                                                                                                                                                                                                                                                                            REAL FUNCTION LOG2 (A)
C
C This function computes the base two logarithm of A
C
      IMPLICIT NONE
      REAL A
      
      LOG2 = LOG10(A)/LOG10(2.0)

      RETURN
      END



      PROGRAM USRDEF
C
C This program motivates the utility of user-defined functions
C
      IMPLICIT NONE
      REAL LOG2
      REAL X, Y, Z
      
      PRINT *, 'Please enter a real number'
      READ *, X
      PRINT *, 'The base two logarithm is ', LOG2(X)

      PRINT *, 'Please enter another real number'
      READ *, Y
      PRINT *, 'The base two logarithm is ', LOG2(Y)

      PRINT *, 'Please enter a third real number'
      READ *, Z
      PRINT *, 'The base two logarithm is ', LOG2(Z)

      STOP
      END
                                                                                                                                                                                                                                                                                                                         examples/escape.f                                                                                      644    1107     770         1114  5477466235   7420                                                                                                                                                                                                                                                                                                                                                                      C Calculates and displays escape velocities
C
C Created: Joe Zachary, September 27, 1992
C Modified:



      PROGRAM VELOCITY

      IMPLICIT NONE
      REAL ESCAPE
      REAL EMASS, MMASS, JMASS, ERADIUS, MRADIUS, JRADIUS

      PARAMETER (EMASS=6.0E24, MMASS=7.4E22, JMASS=1.9E27)
      PARAMETER (ERADIUS=6.4E6, MRADIUS=1.7E6, JRADIUS=7.1E7)

      PRINT *, 'Here are three escape velocities in meters/sec:'

      PRINT *, 'Earth:  ', ESCAPE(EMASS, ERADIUS)

      PRINT *, 'Moon:  ', ESCAPE(MMASS, MRADIUS)

      PRINT *, 'Jupiter: ', ESCAPE(JMASS, JRADIUS)

      STOP
      END

ease enter a third real number'
      READ *, Z
      PRINT *, 'The base two logarithm is ', LOG2(Z)

      STOP
      END
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         