return to main 1401 Restoration Page

Fortran Geezer visit

Hopefully in time sequence order
    - Initial Announcement - from Van Snyder
    - Fun - from Robert Garner
    - Run - from Marc
    - Carl and Ken are potentially available
    - Here are the two examples from the Fortran manual - from Van
    - # 2 Ran Great - from Marc

Initial Announcement - from Van Snyder

> 
> From:        Van Snyder 
> To:        Robert B Garner 
> Date:        03/20/2018 11:08 AM
> Subject:        Fortran Geezer visit
> 
> 
> Robert:
> 
> The Fortran Geezer group (veterans of Fortran standardization) are
> visiting CHM 2:30-4:30 on Sunday 10 June.
> 
> Is it possible to open the 1401 room and run the Fortran II compiler?
> 
> Thanks,
> Van

Fun - from Robert Garner


On Tue, 2018-03-20 at 10:51 -0800, Robert B Garner wrote:
> Van,
> 
> > The Fortran Geezer group (veterans of Fortran standardization) are
> visiting CHM 2:30-4:30 on Sunday 10 June.
> > Is it possible to open the 1401 room and run the Fortran II
> compiler?
> 
> For something this fun, it seems likely.*  ;-)
> Do you know anything about the Fortran II programs they might want to
> run (size, expected runtime, etc)?
> (They'll need to send them in advance, or arrive with their punched
> decks.  ;-))

I think running the example programs from the 1401-FO-050 manual
(C24-1455) would be good enough. Example 2 is attached.  The "P" in
column 13 could be removed if a condensed deck is not desired.  Also a
SimH script to run it.  A condensed deck for it might be in the 1401
room.  I ran it there to verify there was a bug in the SimH divide
instruction.

The video was about running Example 1, so I assume you have that deck.

> I've cc'd Marc Verdiell, Carl Claunch, Ken Shirriff, and Stan Paddock,
> cc'd, for potential availability on June 10th.
> (I'm out of town then.).
> 
> If they're not available on June 10th, Katharina McAllister could
> check on the possibility of scheduling the 1401 docents for at least a
> normal system demo at that time.
> 
> - Robert
> 
> *  Technically, the 1401 room is open anytime the CHM is open.  It's
> just not necessarily turned on.  ;-))
> (Visitor demos occur on Saturday mornings and on Wednesdays, per info
> at top of our 1401 web site.)
>

Run - from Marc

Subject:  RE: Fortran Geezer visit
From:	< marc. 	 	 
Date:	Tue, Mar 20, 2018 1:25 pm
To:	...

Make sure they run their programs on the simulator first! 
Adding Michael Albaugh. Michael can prepare the cards deck 
the real run (the control card in particular). 
I will just be back from a trip so I *might* be able to help.

Marc

Here are the two examples from the Fortran manual - from Van

From:        Van Snyder 
To:        Robert B Garner 
Date:        03/20/2018 04:37 PM
Subject:        Re: Fortran Geezer visit



Robert:

Here are the two examples from the Fortran manual, together with
versions modern enough to compile and run with contemporary compilers.

I ran them both with 20-digit mantissas in SimH.

Gary's arithmetic was superb.  Compare especially the results for
Example 2.

Van
Example-1-new.out - from Van
Example-2-modern.out - from Van
Example-2.f
Example-2.run
--------- and more, from later e-mail -----------------------
Example-1.f from Van
Example-1.lpt from Van
Example-1.run from Van
Example-1-new.f from Van
Example-1-2.lpt from Van
Example-2-modern.f from Van

# 2 Ran Great - from Marc

Subject:  RE: Fortran Geezer visit
From:	"Marc Verdiell" 	 	 
Date:	Tue, Mar 20, 2018 10:40 pm
To:	...

We have example 2 somewhere or can recreate it from 
the tape emulator self punching tape. It ran great on the 1401.

Marc


Example-2.f from Van

paramI9I2020P
c     Appendix E   Sample problem 2
c     Exercise library functions and punch object deck
      print 8
8      format(48h1A=2I(SQRT(1-COS(X)**2)COS(X)SIN(X)/ABS(SIN(X))))
      print 1
1     format(97h0 I   DEGREES            A         EXPONENTIAL(A)=B     
     1LOGARITHM(B)=C        I SIN(2X)=D     C-D//)
      fi=1.0
      degree=7.5
      delta=1.57079632679489661923/12.0
      arg=delta
3     a=(fi+fi)*sqrtf(1.0-cosf(arg)**2)*cosf(arg)
      if(fi-24.)7,7,6
6     a=-a
7     b=expf(a)
      c=logf(b)
      d=fi*sinf(arg+arg)
      diff=c-d
      print 2,fi,degree,a,b,c,d,diff
2     format(1x,f3.0,f9.1,f19.10,e19.10,2f19.10,e12.1)
      fi=fi+1.0
      degree=degree+7.5
      arg=arg+delta
      if(fi-49.0)3,4,5
4     print 9
9     format(1h1)
      stop 111
5     stop 777
      end

Example-2.run from Van

at mt1 v3m4/v3m4.simh.mt1
at cdr Example-2.f
at lpt Example-2.lpt      
at cdp Example-2.cd
d ssb 1
b mt1
c
q

Example-1-new.out from Van

1HILBERT MATRIX


  0.1000000E+01 0.5000000E+00 0.3333333E+00 0.2500000E+00 0.2000000E+00 0.1666667E+00 0.1428571E+00
  0.5000000E+00 0.3333333E+00 0.2500000E+00 0.2000000E+00 0.1666667E+00 0.1428571E+00 0.1250000E+00
  0.3333333E+00 0.2500000E+00 0.2000000E+00 0.1666667E+00 0.1428571E+00 0.1250000E+00 0.1111111E+00
  0.2500000E+00 0.2000000E+00 0.1666667E+00 0.1428571E+00 0.1250000E+00 0.1111111E+00 0.1000000E+00
  0.2000000E+00 0.1666667E+00 0.1428571E+00 0.1250000E+00 0.1111111E+00 0.1000000E+00 0.9090909E-01
  0.1666667E+00 0.1428571E+00 0.1250000E+00 0.1111111E+00 0.1000000E+00 0.9090909E-01 0.8333333E-01
  0.1428571E+00 0.1250000E+00 0.1111111E+00 0.1000000E+00 0.9090909E-01 0.8333333E-01 0.7692308E-01
0INVERSE


  0.1127130E+02 0.2697477E+05-0.2552921E+07-0.1180393E+08-0.2244334E+05-0.5141136E+02 0.2419414E+01
 -0.3487756E+01 0.8314032E+06-0.3636493E+08-0.1932304E+09-0.4360831E+06-0.1005926E+04 0.4292177E+02
 -0.1398673E+02-0.2247596E+07 0.1141950E+09 0.5912305E+09 0.1294083E+07 0.2980953E+04-0.1293565E+03
  0.1480552E+02 0.2393361E+07-0.1215343E+09-0.6292726E+09-0.1377468E+07-0.3173045E+04 0.1376856E+03
  0.1151764E+02-0.6712530E+06 0.2397420E+08 0.1326595E+09 0.3130541E+06 0.7235539E+03-0.3013827E+02
 -0.8151443E+01 0.1660599E+06-0.2480938E+07-0.1775988E+08-0.5206528E+05-0.1213724E+03 0.4534373E+01
 -0.2542905E+01-0.6648345E+05 0.3034646E+07 0.1586679E+08 0.3525523E+05 0.8129078E+02-0.3498363E+01
0MATRIX PRODUCT


     9.14823582******************************************************** -217.88941028    9.41118290
     4.37473541******************************************************** -136.97023123    5.90239214
     2.8993018283693.81847030****************************************** -104.04316926    4.48584126
     2.1839238368229.82353994******************************************  -85.41712638    3.68586551
     1.7589723958025.49212912******************************************  -73.06904215    3.15542223
     1.4758298650677.93240619******************************************  -64.11789527    2.77061608
     1.2728496245083.34938041******************************************  -57.25629619    2.47538688
0TWICE INVERTED


  0.2235633E+02-0.3573966E-02-0.7761112E-08 0.2617500E-16-0.2173495E-16-0.8217723E-13-0.3820878E+00
  0.2437734E-06 0.1080515E-05-0.4880105E-12-0.9171630E-27 0.8224937E-22 0.2186027E-19 0.4890778E-14
 -0.6651171E-15-0.7156508E-17-0.2767492E-14-0.8091549E-23 0.9533273E-39-0.9826732E-28-0.1001491E-22
 -0.2395371E-24-0.2577364E-26-0.4863963E-36-0.9966922E-24-0.4016293E-31-0.1426094E-44-0.3606798E-32
 -0.4235569E-22-0.4557372E-24-0.8600603E-34-0.1426039E-44-0.1762382E-21 0.1552953E-27 0.5619774E-36
  0.1262679E-17 0.3321793E-17 0.6268837E-27 0.1039416E-37 0.5159209E-46 0.1279316E-14 0.5253888E-17
  0.3376101E-07-0.1497988E-11-0.2826980E-21-0.4687326E-32-0.2326585E-40 0.8996049E-37-0.5792866E-09
1

Example-2-modern.out from Van

1A=2I(SQRT(1-COS(X)**2)COS(X)SIN(X)/ABS(SIN(X)))
0 I   DEGREES            A         EXPONENTIAL(A)=B     LOGARITHM(B)=C        I SIN(2X)=D     C-D


  1.      7.5       0.2588190451   0.1295399375E+01       0.2588190451       0.2588190451     0.4E-15
  2.     15.0       1.0000000000   0.2718281828E+01       1.0000000000       1.0000000000    -0.6E-15
  3.     22.5       2.1213203436   0.8342144716E+01       2.1213203436       2.1213203436     0.4E-15
  4.     30.0       3.4641016151   0.3194774551E+02       3.4641016151       3.4641016151    -0.4E-15
  5.     37.5       4.8296291314   0.1251645325E+03       4.8296291314       4.8296291314     0.0E+00
  6.     45.0       6.0000000000   0.4034287935E+03       6.0000000000       6.0000000000     0.0E+00
  7.     52.5       6.7614807840   0.8639205288E+03       6.7614807840       6.7614807840    -0.9E-15
  8.     60.0       6.9282032303   0.1020658443E+04       6.9282032303       6.9282032303     0.9E-15
  9.     67.5       6.3639610307   0.5805413502E+03       6.3639610307       6.3639610307     0.9E-15
 10.     75.0       5.0000000000   0.1484131591E+03       5.0000000000       5.0000000000     0.0E+00
 11.     82.5       2.8470094961   0.1723615989E+02       2.8470094961       2.8470094961     0.0E+00
 12.     90.0      -0.0000000000   0.1000000000E+01      -0.0000000000      -0.0000000000    -0.3E-16
 13.     97.5      -3.3646475863   0.3457419839E-01      -3.3646475863      -3.3646475863    -0.9E-15
 14.    105.0      -7.0000000000   0.9118819656E-03      -7.0000000000      -7.0000000000     0.0E+00
 15.    112.5     -10.6066017178   0.2475206303E-04     -10.6066017178     -10.6066017178     0.0E+00
 16.    120.0     -13.8564064606   0.9599290509E-06     -13.8564064606     -13.8564064606     0.0E+00
 17.    127.5     -16.4207390469   0.7388625308E-07     -16.4207390469     -16.4207390469     0.0E+00
 18.    135.0     -18.0000000000   0.1522997974E-07     -18.0000000000     -18.0000000000     0.0E+00
 19.    142.5     -18.3525906995   0.1070461693E-07     -18.3525906995     -18.3525906995     0.4E-14
 20.    150.0     -17.3205080757   0.3004684793E-07     -17.3205080757     -17.3205080757     0.0E+00
 21.    157.5     -14.8492424049   0.3556771481E-06     -14.8492424049     -14.8492424049    -0.4E-14
 22.    165.0     -11.0000000000   0.1670170079E-04     -11.0000000000     -11.0000000000     0.0E+00
 23.    172.5      -5.9528380374   0.2598455530E-02      -5.9528380374      -5.9528380374    -0.8E-14
 24.    180.0       0.0000000000   0.1000000000E+01       0.0000000000      -0.0000000000     0.5E-13
 25.    187.5       6.4704761276   0.6457911327E+03       6.4704761276       6.4704761276    -0.2E-13
 26.    195.0      13.0000000000   0.4424133920E+06      13.0000000000      13.0000000000     0.2E-14
 27.    202.5      19.0918830920   0.1956588407E+09      19.0918830920      19.0918830920     0.4E-14
 28.    210.0      24.2487113060   0.3396890234E+11      24.2487113060      24.2487113060     0.0E+00
 29.    217.5      28.0118489624   0.1463495638E+13      28.0118489624      28.0118489624     0.4E-14
 30.    225.0      30.0000000000   0.1068647458E+14      30.0000000000      30.0000000000     0.0E+00
 31.    232.5      29.9437006150   0.1010145526E+14      29.9437006150      29.9437006150     0.4E-14
 32.    240.0      27.7128129211   0.1085229847E+13      27.7128129211      27.7128129211    -0.4E-14
 33.    247.5      23.3345237792   0.1361616844E+11      23.3345237792      23.3345237792     0.0E+00
 34.    255.0      17.0000000000   0.2415495275E+08      17.0000000000      17.0000000000     0.0E+00
 35.    262.5       9.0586665786   0.8592685341E+04       9.0586665786       9.0586665786     0.0E+00
 36.    270.0       0.0000000000   0.1000000000E+01       0.0000000000       0.0000000000     0.1E-15
 37.    277.5      -9.5763046688   0.6935275619E-04      -9.5763046688      -9.5763046688     0.0E+00
 38.    285.0     -19.0000000000   0.5602796438E-08     -19.0000000000     -19.0000000000     0.0E+00
 39.    292.5     -27.5771644663   0.1055333309E-11     -27.5771644663     -27.5771644663     0.0E+00
 40.    300.0     -34.6410161514   0.9028130704E-15     -34.6410161514     -34.6410161514     0.0E+00
 41.    307.5     -39.6029588779   0.6319074743E-17     -39.6029588779     -39.6029588779     0.0E+00
 42.    315.0     -42.0000000000   0.5749522264E-18     -42.0000000000     -42.0000000000    -0.7E-14
 43.    322.5     -41.5348105304   0.9155055464E-18     -41.5348105304     -41.5348105304    -0.7E-14
 44.    330.0     -38.1051177665   0.2825905416E-16     -38.1051177665     -38.1051177665     0.0E+00
 45.    337.5     -31.8198051534   0.1516471339E-13     -31.8198051534     -31.8198051534     0.7E-14
 46.    345.0     -23.0000000000   0.1026187963E-09     -23.0000000000     -23.0000000000     0.7E-14
 47.    352.5     -12.1644951198   0.5212269879E-05     -12.1644951198     -12.1644951198     0.5E-14
 48.    360.0       0.0000000000   0.1000000000E+01       0.0000000000      -0.0000000000     0.4E-12
1

Example-2.run from Van

at mt1 v3m4/v3m4.simh.mt1
at cdr Example-2.f
at lpt Example-2.lpt
set lpt fortran
d ssb 1
b mt1
c
q

Example-1.f from Van

paramI9I2020
C     APPENDIX E   SAMPLE PROBLEM 1
C     MATRIX ARITHEMTIC
      DIMENSION A(7,7),VECTOR(7),B(7,7)
      SENSE LIGHT 1
      DO 1 I=1,7
      DO 1 J=1,7
      B(I,J)=1./FLOATF(I+J-1)
1     A(I,J)=B(I,J)
      PRINT 13
13    FORMAT(15H1HILBERT MATRIX//)
      PRINT 2,A
2     FORMAT(1X,7E14.7)
      PRINT 15
15    FORMAT(8H0INVERSE//)
10    DO 6 K=1,7
      VECTOR=1.
      DO 3 I=2,7
3     VECTOR(I)=0.
      DO 4 J=2,8
4     A(I,J)=A(I,J)/A
      DO 5 I=1,55
5     A(I)  =A(I+1)
      DO 6 I=1,6
      A(56) =A(I,I)
      DO 6 J=1,7
6     A(I,J)=A(I,J+1)-A(56)*A(7,J)
      PRINT 2,A
      IF(SENSE LIGHT 1)11,12
11    PRINT 16
16    FORMAT(15H0MATRIX PRODUCT//)
      DO 9 K=1,7
      DO 8 I=1,7
      VECTOR(I)=0.
      DO 8 J=1,7
8     VECTOR(I)=VECTOR(I)+A(I,J)*B(J,K)
9     PRINT 18,VECTOR
18    FORMAT(1X,7F14.8)
      PRINT 17
17    FORMAT(15H0TWICE INVERTED//)
      GO TO 10
12    PRINT 7
7     FORMAT(1H1)
      STOP 111
      END

Example-1.lpt from Van

START OF FORTRAN COMPILATION

MACHINE SIZE SPECIFIED IS 16000
ACTUAL MACHINE SIZE IS 16000

                                                                                          PAGE    1
SEQ   STMNT      FORTRAN STATEMENT

      C          APPENDIX E   SAMPLE PROBLEM 1
      C          MATRIX ARITHEMTIC
  1              DIMENSION A(7,7),VECTOR(7),B(7,7)
  2              SENSE LIGHT 1
  3              DO 1 I=1,7
  4              DO 1 J=1,7
  5              B(I,J)=1./FLOATF(I+J-1)
  6   1          A(I,J)=B(I,J)
  7              PRINT 13
  8   13         FORMAT(15H1HILBERT MATRIX//)
  9              PRINT 2,A
 10   2          FORMAT(1X,7E14.7)
 11              PRINT 15
 12   15         FORMAT(8H0INVERSE//)
 13   10         DO 6 K=1,7
 14              VECTOR=1.
 15              DO 3 I=2,7
 16   3          VECTOR(I)=0.
 17              DO 4 J=2,8
 18   4          A(I,J)=A(I,J)/A
 19              DO 5 I=1,55
 20   5          A(I)  =A(I+1)
 21              DO 6 I=1,6
 22              A(56) =A(I,I)
 23              DO 6 J=1,7
 24   6          A(I,J)=A(I,J+1)-A(56)*A(7,J)
 25              PRINT 2,A
 26              IF(SENSE LIGHT 1)11,12
 27   11         PRINT 16
 28   16         FORMAT(15H0MATRIX PRODUCT//)
 29              DO 9 K=1,7
 30              DO 8 I=1,7
 31              VECTOR(I)=0.
 32              DO 8 J=1,7
 33   8          VECTOR(I)=VECTOR(I)+A(I,J)*B(J,K)
 34   9          PRINT 18,VECTOR
 35   18         FORMAT(1X,7F14.8)
 36              PRINT 17
 37   17         FORMAT(15H0TWICE INVERTED//)
 38              GO TO 10
 39   12         PRINT 7
 40   7          FORMAT(1H1)
 41              STOP 111
 42              END

  789 INPUT CHARACTERS

MODULUS IS 20
MANTISSA IS 20




  STORAGE ASSIGNMENT-ARRAYS + EQUATED VARIABLES

B            14920-15997   R2? I9G
VECTOR       14766-14919   P6F R1I
A            13688-14765   W8H P6E






STORAGE ASSIGNMENT - SIMPLE VARIABLES

J              4299     29Z
I              4319     31Z
K              4339     33Z



CONSTANTS LOCATED FROM 13622 TO 13687   W2B-W8G


             STARTING ADDRESS OF STATEMENTS


     SEQ                  STARTING ADDRESS       DISPLAY

     002                36U             4364         36Y
     003                36Y             4368         37S
     004                39/             4391         39V
     005                41U             4414         41Y
     006                46/             4461         46V
     006                50/             4501         50V
     007                50V             4505         50Z
     009                51W             4516         52|
     011                52X             4527         53/
     013                53Y             4538         54S
     014                56/             4561         56V
     015                57T             4573         57X
     016                59W             4596         60|
     016                61W             4616         62|
     017                62|             4620         62U
     018                64T             4643         64X
     018                68X             4687         69/
     019                69/             4691         69V
     020                71U             4714         71Y
     020                74S             4742         74W
     021                74W             4746         75|
     022                76Z             4769         77T
     023                79V             4795         79Z
     024                81Y             4818         82S
     024                87V             4875         87Z
     025                87Z             4879         88T
     026                89|             4890         89U
     027                90S             4902         90W
     029                91T             4913         91X
     030                93W             4936         94|
     031                95Z             4959         96T
     032                97Z             4979         98T
     033                |0S             5002         |0W
     033                |6W             5066         |7|
     034                |7|             5070         |7U
     034                |8/             5081         |8V
     036                |8V             5085         |8Z
     038                |9W             5096         /0|
     039                /0|             5100         /0U
     041                /1/             5111         /1V
     043                /2|             5120         /2U

END OF COMPILATION

PRESS START TO GO

HILBERT MATRIX

 0.1000000E 01 0.5000000E 00 0.3333333E 00 0.2500000E 00 0.2000000E 00 0.1666667E 00 0.1428571E 00
 0.5000000E 00 0.3333333E 00 0.2500000E 00 0.2000000E 00 0.1666667E 00 0.1428571E 00 0.1250000E 00
 0.3333333E 00 0.2500000E 00 0.2000000E 00 0.1666667E 00 0.1428571E 00 0.1250000E 00 0.1111111E 00
 0.2500000E 00 0.2000000E 00 0.1666667E 00 0.1428571E 00 0.1250000E 00 0.1111111E 00 0.1000000E 00
 0.2000000E 00 0.1666667E 00 0.1428571E 00 0.1250000E 00 0.1111111E 00 0.1000000E 00 0.9090909E-01
 0.1666667E 00 0.1428571E 00 0.1250000E 00 0.1111111E 00 0.1000000E 00 0.9090909E-01 0.8333333E-01
 0.1428571E 00 0.1250000E 00 0.1111111E 00 0.1000000E 00 0.9090909E-01 0.8333333E-01 0.7692308E-01

INVERSE

 0.1127130E 02 0.2697477E 05-0.2552921E 07-0.1180393E 08-0.2244334E 05-0.5141136E 02 0.2419414E 01
-0.3487756E 01 0.8314032E 06-0.3636493E 08-0.1932304E 09-0.4360831E 06-0.1005926E 04 0.4292177E 02
-0.1398673E 02-0.2247596E 07 0.1141950E 09 0.5912305E 09 0.1294083E 07 0.2980953E 04-0.1293565E 03
 0.1480552E 02 0.2393361E 07-0.1215343E 09-0.6292726E 09-0.1377468E 07-0.3173045E 04 0.1376856E 03
 0.1151764E 02-0.6712530E 06 0.2397420E 08 0.1326595E 09 0.3130541E 06 0.7235539E 03-0.3013827E 02
-0.8151443E 01 0.1660599E 06-0.2480938E 07-0.1775988E 08-0.5206528E 05-0.1213724E 03 0.4534373E 01
-0.2542905E 01-0.6648345E 05 0.3034646E 07 0.1586679E 08 0.3525523E 05 0.8129078E 02-0.3498363E 01

MATRIX PRODUCT

     X             X             X             X             X             X             X
    4.37473541     X             X             X        59410.86119470 -136.97023123    5.90239214
    2.8993018283693.81847030     X             X        45132.18172848 -104.04316926    4.48584126
    2.1839238368229.82353994     X             X        37055.83795887  -85.41712638    3.68586551
    1.7589723958025.49212912     X             X        31701.39701141  -73.06904215    3.15542223
    1.4758298650677.93240619     X             X        27819.62291083  -64.11789527    2.77061608
    1.2728496245083.34938041     X             X        24843.74203939  -57.25629619    2.47538688

TWICE INVERTED

 0.2235633E 02-0.3573966E-02-0.7761112E-08 0.2617500E-16-0.2173495E-16-0.8217723E-13-0.3820878E 00
 0.2437734E-06 0.1080515E-05-0.4880105E-12-0.9171630E-27 0.8224937E-22 0.2186027E-19 0.4890778E-14
-0.6651171E-15-0.7156508E-17-0.2767492E-14-0.8091549E-23 0.9533274E-39-0.9826732E-28-0.1001491E-22
-0.2395371E-24-0.2577364E-26-0.4863963E-36-0.9966922E-24-0.4016293E-31-0.1426094E-44-0.3606798E-32
-0.4235569E-22-0.4557372E-24-0.8600603E-34-0.1426039E-44-0.1762382E-21 0.1552953E-27 0.5619774E-36
 0.1262679E-17 0.3321793E-17 0.6268837E-27 0.1039416E-37 0.5159209E-46 0.1279316E-14 0.5253888E-17
 0.3376101E-07-0.1497988E-11-0.2826980E-21-0.4687326E-32-0.2326585E-40 0.8996049E-37-0.5792866E-09

Example-1.run from Van

at mt1 v3m4/v3m4.simh.mt1
at cdr Example-1.f
at lpt Example-1.lpt
set lpt fortran
d ssb 1
b mt1
c
q

Example-1-new.f from Van

C     APPENDIX E   SAMPLE PROBLEM 1
C     MATRIX ARITHEMTIC
      implicit double precision(a-h,o-z)
      DIMENSION A(7,7),VECTOR(7),B(7,7)
      dimension a1(105)
      equivalence (a,a1), (a1(50),vector), (a1(58),b)
C      SENSE LIGHT 1
      ifirst=1
      DO 1 I=1,7
      DO 1 J=1,7
c      B(I,J)=1./FLOATF(I+J-1)
      B(I,J)=1./dble(I+J-1)
1     A(I,J)=B(I,J)
      PRINT 13
13    FORMAT(15H1HILBERT MATRIX//)
      PRINT 2,A
2     FORMAT(1X,7E14.7)
      PRINT 15
15    FORMAT(8H0INVERSE//)
10    DO 6 K=1,7
c      VECTOR=1.
      vector(1)=1.
      DO 3 I=2,7
3     VECTOR(I)=0.
      DO 4 J=2,8
c4     A(I,J)=A(I,J)/A
4     A(I,J)=A(I,J)/A(1,1)
      DO 5 I=1,55
c5     A(I)  =A(I+1)
5     a1(i) =a1(i+1)
      DO 6 I=1,6
c      A(56) =A(I,I)
      a1(56) =a(i,i)
      DO 6 J=1,7
c6     A(I,J)=A(I,J+1)-A(56)*A(7,J)
6     A(I,J)=A(I,J+1)-A1(56)*A(7,J)
      PRINT 2,A
c      IF(SENSE LIGHT 1)11,12
      if(ifirst) 11,12,11
11    PRINT 16
16    FORMAT(15H0MATRIX PRODUCT//)
      ifirst=0
      DO 9 K=1,7
      DO 8 I=1,7
      VECTOR(I)=0.
      DO 8 J=1,7
8     VECTOR(I)=VECTOR(I)+A(I,J)*B(J,K)
9     PRINT 18,VECTOR
18    FORMAT(1X,7F14.8)
      PRINT 17
17    FORMAT(15H0TWICE INVERTED//)
      GO TO 10
12    PRINT 7
7     FORMAT(1H1)
      STOP 111
      END

Example-1-2.lpt from Van

START OF FORTRAN COMPILATION

MACHINE SIZE SPECIFIED IS 16000
ACTUAL MACHINE SIZE IS 16000

                                                                                          PAGE    1
SEQ   STMNT      FORTRAN STATEMENT

      C          APPENDIX E   SAMPLE PROBLEM 2
      C          EXERCISE LIBRARY FUNCTIONS AND PUNCH OBJECT DECK
  1              PRINT 8
  2   8           FORMAT(48H1A=2I(SQRT(1-COS(X)**2)COS(X)SIN(X)/ABS(SIN(X))))
  3              PRINT 1
  4   1          FORMAT(97H0 I   DEGREES            A         EXPONENTIAL(A)=B
              1  LOGARITHM(B)=C        I SIN(2X)=D     C-D//)
  5              FI=1.0
  6              DEGREE=7.5
  7              DELTA=1.57079632679489661923/12.0
  8              ARG=DELTA
  9   3          A=(FI+FI)*SQRTF(1.0-COSF(ARG)**2)*COSF(ARG)
 10              IF(FI-24.)7,7,6
 11   6          A=-A
 12   7          B=EXPF(A)
 13              C=LOGF(B)
 14              D=FI*SINF(ARG+ARG)
 15              DIFF=C-D
 16              PRINT 2,FI,DEGREE,A,B,C,D,DIFF
 17   2          FORMAT(1X,F3.0,F9.1,F19.10,E19.10,2F19.10,E12.1)
 18              FI=FI+1.0
 19              DEGREE=DEGREE+7.5
 20              ARG=ARG+DELTA
 21              IF(FI-49.0)3,4,5
 22   4          PRINT 9
 23   9          FORMAT(1H1)
 24              STOP 111
 25   5          STOP 777
 26              END

  653 INPUT CHARACTERS

MODULUS IS 20
MANTISSA IS 20




  STORAGE ASSIGNMENT-ARRAYS + EQUATED VARIABLES

NO ARRAYS






STORAGE ASSIGNMENT - SIMPLE VARIABLES

ARG            4301     30/
DEGREE         4323     32T
FI             4345     34V
DIFF           4367     36X
D              4389     38Z
C              4411     41/
B              4433     43T
A              4455     45V
DELTA          4477     47X



CONSTANTS LOCATED FROM 15909 TO 15999   I0I-I9I


             STARTING ADDRESS OF STATEMENTS


     SEQ                  STARTING ADDRESS       DISPLAY

     001                52W             4526         53|
     003                53X             4537         54/
     005                54Y             4548         55S
     006                56|             4560         56U
     007                57S             4572         57W
     008                58Y             4588         59S
     009                60|             4600         60U
     010                66|             4660         66U
     011                68Y             4688         69S
     012                70/             4701         70V
     013                71U             4714         71Y
     014                72X             4727         73/
     015                74Y             4748         75S
     016                76U             4764         76Y
     018                77V             4775         77Z
     019                79/             4791         79V
     020                80X             4807         81/
     021                82T             4823         82X
     022                85Z             4859         86T
     024                87|             4870         87U
     025                87Z             4879         88T
     027                88Y             4888         89S

END OF COMPILATION

PRESS START TO GO

A=2I(SQRT(1-COS(X)**2)COS(X)SIN(X)/ABS(SIN(X)))

 I   DEGREES            A         EXPONENTIAL(A)=B     LOGARITHM(B)=C        I SIN(2X)=D     C-D

 1.      7.5       0.2588190451   0.1295399375E 01       0.2588190451       0.2588190451     0.4E-19
 2.     15.0       1.0000000000   0.2718281828E 01       1.0000000000       1.0000000000     0.0E 00
 3.     22.5       2.1213203436   0.8342144716E 01       2.1213203436       2.1213203436     0.0E 00
 4.     30.0       3.4641016151   0.3194774551E 02       3.4641016151       3.4641016151     0.0E 00
 5.     37.5       4.8296291314   0.1251645325E 03       4.8296291314       4.8296291314     0.0E 00
 6.     45.0       6.0000000000   0.4034287935E 03       6.0000000000       6.0000000000     0.0E 00
 7.     52.5       6.7614807840   0.8639205288E 03       6.7614807840       6.7614807840     0.0E 00
 8.     60.0       6.9282032303   0.1020658443E 04       6.9282032303       6.9282032303     0.0E 00
 9.     67.5       6.3639610307   0.5805413502E 03       6.3639610307       6.3639610307     0.0E 00
10.     75.0       5.0000000000   0.1484131591E 03       5.0000000000       5.0000000000     0.0E 00
11.     82.5       2.8470094961   0.1723615989E 02       2.8470094961       2.8470094961     0.0E 00
12.     90.0       0.0000000000   1.0000000000E 00       0.0000000000       0.0000000000    -0.4E-20
13.     97.5      -3.3646475863   0.3457419839E-01      -3.3646475863      -3.3646475863     0.0E 00
14.    105.0      -7.0000000000   0.9118819656E-03      -7.0000000000      -7.0000000000     0.0E 00
15.    112.5     -10.6066017178   0.2475206303E-04     -10.6066017178     -10.6066017178     0.0E 00
16.    120.0     -13.8564064606   0.9599290509E-06     -13.8564064606     -13.8564064606     0.0E 00
17.    127.5     -16.4207390469   0.7388625308E-07     -16.4207390469     -16.4207390469     0.0E 00
18.    135.0     -18.0000000000   0.1522997974E-07     -18.0000000000     -18.0000000000     0.0E 00
19.    142.5     -18.3525906995   0.1070461693E-07     -18.3525906995     -18.3525906995     0.0E 00
20.    150.0     -17.3205080757   0.3004684793E-07     -17.3205080757     -17.3205080757     0.0E 00
21.    157.5     -14.8492424049   0.3556771481E-06     -14.8492424049     -14.8492424049     0.0E 00
22.    165.0     -11.0000000000   0.1670170079E-04     -11.0000000000     -11.0000000000     0.0E 00
23.    172.5      -5.9528380374   0.2598455530E-02      -5.9528380374      -5.9528380374     0.0E 00
24.    180.0       0.0000000000   0.1000000000E 01       0.0000000000       0.0000000000    -0.3E-16
25.    187.5       6.4704761276   0.6457911327E 03       6.4704761276       6.4704761276     0.1E-18
26.    195.0      13.0000000000   0.4424133920E 06      13.0000000000      13.0000000000     0.0E 00
27.    202.5      19.0918830920   0.1956588407E 09      19.0918830920      19.0918830920     0.0E 00
28.    210.0      24.2487113060   0.3396890234E 11      24.2487113060      24.2487113060     0.0E 00
29.    217.5      28.0118489624   0.1463495638E 13      28.0118489624      28.0118489624     0.0E 00
30.    225.0      30.0000000000   0.1068647458E 14      30.0000000000      30.0000000000     0.0E 00
31.    232.5      29.9437006150   0.1010145526E 14      29.9437006150      29.9437006150     0.0E 00
32.    240.0      27.7128129211   0.1085229847E 13      27.7128129211      27.7128129211     0.0E 00
33.    247.5      23.3345237792   0.1361616844E 11      23.3345237792      23.3345237792     0.0E 00
34.    255.0      17.0000000000   0.2415495275E 08      17.0000000000      17.0000000000     0.0E 00
35.    262.5       9.0586665786   0.8592685341E 04       9.0586665786       9.0586665786     0.0E 00
36.    270.0       0.0000000000   1.0000000000E 00       0.0000000000       0.0000000000     0.4E-20
37.    277.5      -9.5763046688   0.6935275619E-04      -9.5763046688      -9.5763046688     0.0E 00
38.    285.0     -19.0000000000   0.5602796438E-08     -19.0000000000     -19.0000000000     0.0E 00
39.    292.5     -27.5771644663   0.1055333309E-11     -27.5771644663     -27.5771644663     0.0E 00
40.    300.0     -34.6410161514   0.9028130704E-15     -34.6410161514     -34.6410161514     0.0E 00
41.    307.5     -39.6029588779   0.6319074743E-17     -39.6029588779     -39.6029588779     0.0E 00
42.    315.0     -42.0000000000   0.5749522264E-18     -42.0000000000     -42.0000000000     0.0E 00
43.    322.5     -41.5348105304   0.9155055464E-18     -41.5348105304     -41.5348105304     0.0E 00
44.    330.0     -38.1051177665   0.2825905416E-16     -38.1051177665     -38.1051177665     0.0E 00
45.    337.5     -31.8198051534   0.1516471339E-13     -31.8198051534     -31.8198051534     0.0E 00
46.    345.0     -23.0000000000   0.1026187963E-09     -23.0000000000     -23.0000000000     0.0E 00
47.    352.5     -12.1644951198   0.5212269879E-05     -12.1644951198     -12.1644951198     0.0E 00
48.    360.0       0.0000000000   0.1000000000E 01       0.0000000000       0.0000000000    -0.1E-15

Example-2-modern.f from Van

c     Appendix E   Sample problem 2
c     Exercise library functions and punch object deck
      implicit double precision ( a-z )
c Modern names for intrinsic functions
      sqrtf(x) = sqrt(x)
      cosf(x) = cos(x)
      expf(x) = exp(x)
      logf(x) = log(x)
      sinf(x) = sin(x)
      print 8
8      format(48h1A=2I(SQRT(1-COS(X)**2)COS(X)SIN(X)/ABS(SIN(X))))
      print 1
1     format(97h0 I   DEGREES            A         EXPONENTIAL(A)=B     
     1LOGARITHM(B)=C        I SIN(2X)=D     C-D//)
      fi=1.0
      degree=7.5d0
      delta=1.57079632679489661923d0/12.0
      arg=delta
3     a=(fi+fi)*sqrtf(1.0-cosf(arg)**2)*cosf(arg)
      if(fi-24.)7,7,6
6     a=-a
7     b=expf(a)
      c=logf(b)
      d=fi*sinf(arg+arg)
      diff=c-d
      print 2,fi,degree,a,b,c,d,diff
2     format(1x,f3.0,f9.1,f19.10,e19.10,2f19.10,e12.1)
      fi=fi+1.0
      degree=degree+7.5
      arg=arg+delta
      if(fi-49.0)3,4,5
4     print 9
9     format(1h1)
      stop 111
5     stop 777
      end