Discussions‎ > ‎MTS Today ?‎ > ‎

#4: CSMP running under D6.0 MTS under Hercules in January 2012

posted Jan 7, 2012, 11:54 AM by Jeff Ogden   [ updated Jan 13, 2012, 5:30 PM ]
photograph of a 3270 display showing CSMP running under MTS under Hercules
            CSMP under MTS under Hercules, c. January 2012

From: "Dave"
Subject: [H390-MTS] CSMP on MTS
Date: January 7, 2012 10:24:34 AM EST
To: "H390 MTS Group" <H390-MTS@yahoogroups.com>

Folks,
 
Well I am very happy with this. I now have my sample CSMP program from “Applied Numerical Methods for Digital Computation with Fortran and CSMP” 2nd Edition by James, Smith & Wolford working after one minor typo. In case any one wants to try the source is below :-
 
INITIAL
CONSTANT W=10.0,C=0.00259,A=-0.6,B=1.0,K1=.255,K2=1.025
INCON X0=0.0,XDOT0=8.0
     M=W/386.
     COEF=C/M
DYNAMIC
NOSORT
      IF(X.GT.0)GOTO 2
      F0FX=K1*DEADSP(A,0.,X)
      GOTO 3
  2   F0FX=K2*DEADSP(0.,B,X)
  3   CONTINUE
SORT
      XDDOT=-COEF*XDOT-F0FX/M
      XDOT=INTGRL(XDOT0,XDDOT)
      X=INTGRL(X0,XDOT)
TERMINAL
      KE=0.5*M*XDOT**2
      WRITE(6,4)KE
  4   FORMAT(' ',E16.7)
TIMER DELT=0.05,OUTDEL=0.2,FINTIM=60.
METHOD RKSFX
LABEL SPRINT MASS VISCOUSLY DAMPED WITH DEAD SPACE
PRTPLOT XDOT,X,F0FX
END
STOP
ENDJOB
 
Giving the first few lines of print out :-
 
SPRINT MASS VISCOUSLY DAMPED WITH DEAD SPACE                       PAGE   1
 
                        MINIMUM             XDOT   VERSUS TIME           MAXIMUM
                      -7.6828E+00                                      8.0000E+00
TIME          XDOT        I                                                I
0.0           8.0000E+00   -------------------------------------------------+
2.0000E-01    7.0260E+00   ----------------------------------------------+
4.0000E-01   -1.2600E+00   --------------------+
6.0000E-01   -7.6546E+00   +
8.0000E-01   -7.5684E+00   +
1.0000E+00   -6.4429E+00   ---+
1.2000E+00   -2.9557E+00   ---------------+
1.4000E+00    1.5774E+00   -----------------------------+
1.6000E+00    5.4257E+00   -----------------------------------------+
1.8000E+00    7.1513E+00   -----------------------------------------------+
2.0000E+00    7.0579E+00   ----------------------------------------------+
2.2000E+00    4.4652E+00   --------------------------------------+
2.4000E+00   -3.6665E+00   ------------+
2.6000E+00   -6.8152E+00   --+
2.8000E+00   -6.6794E+00   ---+
3.0000E+00   -5.2724E+00   -------+
3.2000E+00   -1.9047E+00   ------------------+
3.4000E+00    2.1148E+00   -------------------------------+
3.6000E+00    5.2571E+00   -----------------------------------------+
3.8000E+00    6.3542E+00   --------------------------------------------+
4.0000E+00    6.2285E+00   --------------------------------------------+
4.2000E+00    3.7196E+00   ------------------------------------+
4.4000E+00   -3.4711E+00   -------------+
4.6000E+00   -6.0134E+00   -----+
4.8000E+00   -5.8943E+00   -----+
5.0000E+00   -4.9065E+00   --------+
 
Thanks to every one from the MTS team for making this possible. Now I need to start updating my CSMP web pages....
 
Dave
G4UGM

Comments