CFPRIME PHEAD                                                           PHEAD       1
C***********************************************************************RIGHTE      1
C*                                                                     *RIGHTE      2
C*        Extended Transient-Midterm Stability Program (ETMSP)         *RIGHTE      3
C*        ====================================================         *RIGHTE      4
C*                                                                     *RIGHTE      5
C*       Copyright (C) (1993) Electric Power Research Institute        *RIGHTE      6
C*                                                                     *RIGHTE      7
C* EPRI reserves all rights in the software and associated             *RIGHTE      8
C* documentation as delivered. The software and its associated         *RIGHTE      9
C* documention or any portion thereof may not be reproduced in any form*RIGHTE     10
C* whatsoever without the consent of EPRI, except as explicity provided*RIGHTE     11
C* for by license. Licensee shall submit a detailed description to EPRI*RIGHTE     12
C* of any changes or modifications to the software within two (2)      *RIGHTE     13
C* months after such changes or modifications are made. At EPRI's sole *RIGHTE     14
C* discretion, the software, as changed or modified, shall be given a  *RIGHTE     15
C* new designation sufficiently different from its then current        *RIGHTE     16
C* designation as to prevent mistake,confusion, or deception as between*RIGHTE     17
C* the current software as changed or modified.                        *RIGHTE     18
C*                                                                     *RIGHTE     19
C* A license under EPRI's rights in the software can be obtained       *RIGHTE     20
C* directly from EPRI.                                                 *RIGHTE     21
C*                                                                     *RIGHTE     22
C* This program and supporting materials may be independently available*RIGHTE     23
C* from Electric Power Software centre (EPSC) for an appropriate       *RIGHTE     24
C* distribution fee. The EPSC is a service of                          *RIGHTE     25
C*                                                                     *RIGHTE     26
C*                    Power Computing Company                          *RIGHTE     27
C*                    1930 Hi Line                                     *RIGHTE     28
C*                    Dallas, Tx 75207                                 *RIGHTE     29
C*                                                                     *RIGHTE     30
C* NEITHER EPRI, ANY MEMBER OF EPRI, NOR ANY PERSON OR  ORGANIZATION   *RIGHTE     31
C* ACTING ON BEHAVE OF THEM:                                           *RIGHTE     32
C*                                                                     *RIGHTE     33
C* 1. MAKE ANY WARRANTY OR REPRESENTATION WHATSOEVER, EXPRESS OR       *RIGHTE     34
C*    IMPLIED, INCLUDING ANY WARRANTY OF MERCHANTABILITY OR FITNESS OR *RIGHTE     35
C*    ANY PURPOSE WITH RESPECT TO THE SOFTWARE OR ITS ASSOCIATED       *RIGHTE     36
C*    DOCUMENTATION; OR                                                *RIGHTE     37
C*                                                                     *RIGHTE     38
C* 2. ASSUMES ANY LIABILITY WHATSOEVER WITH RESPECT TO ANY USE OF THE  *RIGHTE     39
C*    SOFTWARE OR ITS ASSOCIATED DOCUMENTATION OR ANY PORTION THEREOF  *RIGHTE     40
C*    OR WITH RESPECT TO ANY DAMAGES WHICH MAY RESULT FROM SUCH USE.   *RIGHTE     41
C*                                                                     *RIGHTE     42
C* THIS NOTICE MAY NOT BE REMOVED FROM THE SOFTWARE BY ANY USER        *RIGHTE     43
C* THEREOF.                                                            *RIGHTE     44
C*                                                                     *RIGHTE     45
C***********************************************************************RIGHTE     46
      SUBROUTINE PHEAD(IUX,LMSG,MSG)                                    PHEAD       3
CD                                                                      PHEAD       4
CD    THIS IS THE ROUTINE PRINTS THE HEAD PAGE OF ALL PROGRAM OUTPUT    PHEAD       5
CD    FILES.                                                            PHEAD       6
CD                                                                      PHEAD       7
      INCLUDE 'CNB0.INS'                                                PHEAD       8
      INCLUDE 'CNB19.INS'                                               PHEAD       9
      INCLUDE 'CNREC1.INS'                                              PHEAD      10
      INCLUDE 'CNLSTA.INS'                                              PHEAD      11
      INCLUDE 'CNUNIT.INS'                                              PHEAD      12
C                                                                       PHEAD      13
      CHARACTER*80 MSG,EQUAL,SPACE                                      PHEAD      14
      CHARACTER*9 JDATE                                                 PHEAD      15
      CHARACTER*7 MODSET                                                PHEAD      16
      EQUIVALENCE (JDATE,LDATE(1))                                      PHEAD      17
      DATA EQUAL(1:20)/'===================='/                          PHEAD      18
      DATA EQUAL(21:40)/'===================='/                         PHEAD      19
      DATA EQUAL(41:60)/'===================='/                         PHEAD      20
      DATA EQUAL(61:80)/'===================='/                         PHEAD      21
C                                                                       PHEAD      22
      LSPC = (133 - LMSG)/2                                             PHEAD      23
      MODSET='OHV3-0 '                                                  PHEAD      24
      SPACE = ' '                                                       PHEAD      25
      CALL DATEXX (JDATE)                                               PHEAD      26
      WRITE(IUX,1) VERNUM,VSDATE,MODSET                                 PHEAD      27
      WRITE(IUX,2) SPACE(1:LSPC),MSG(1:LMSG),SPACE(1:LSPC)              PHEAD      28
     *,EQUAL(1:LMSG),JDATE                                              PHEAD      29
C                                                                       PHEAD      30
      RETURN                                                            PHEAD      31
C                                                                       PHEAD      32
*IF -LTSP                                                               PHEAD      33
 1    FORMAT(12(/)                                                      PHEAD      34
     1,T40,'*******************************************************',/  PHEAD      35
     2,T40,'*                                                     *',/  PHEAD      36
     3,T40,'*                                                     *',/  PHEAD      37
     4,T40,'*     EXTENDED TRANSIENT-MIDTERM STABILITY PROGRAM    *',/  PHEAD      38
     5,T40,'*     ============================================    *',/  PHEAD      39
     7,T40,'*                                                     *',/  PHEAD      40
     8,T40,'*                      (ETMSP)                        *',/  PHEAD      41
     9,T40,'*                                                     *',/  PHEAD      42
     A,T40,'*                                                     *',/  PHEAD      43
     1,T40,'*            VERSION ', A5,' RELEASE ',A8,'           *',/  PHEAD      44
     B,T40,'*                     LEVEL ', A7,'                   *',/  PHEAD      45
     3,T40,'*                                                     *',/  PHEAD      46
     5,T40,'*                JOINTLY DEVELOPED BY                 *',/  PHEAD      47
     6,T40,'*                                                     *',/  PHEAD      48
     7,T40,'*                    ONTARIO HYDRO                    *',/  PHEAD      49
     8,T40,'*                700 UNIVERSITY AVENUE                *')   PHEAD      50
*ENDIF                                                                  PHEAD      51
*IF LTSP                                                                PHEAD      52
*ENDIF                                                                  PHEAD      70
 2    FORMAT(T40,'*              TORONTO, ONTARIO,  CANADA',T94, '*',/  PHEAD      71
     B,T40,'*                                                     *',/  PHEAD      72
     1,T40,'*                         AND                         *',/  PHEAD      73
     2,T40,'*                                                     *',/  PHEAD      74
     3,T40,'*          ELECTRIC POWER RESEARCH INSTITUTE          *',/  PHEAD      75
     4,T40,'*                3412  HILLVIEW AVENUE                *',/  PHEAD      76
     5,T40,'*                PALO ALTO, CALIFORNIA                *',/  PHEAD      77
     6,T40,'*                                                     *',/  PHEAD      78
     7,T40,'*                                                     *',/  PHEAD      79
     7,T40,'*                                                     *',/  PHEAD      80
     7,2A,T40,'*',T94,'*',/                                             PHEAD      81
     7,2A,T40,'*',T94,'*',/                                             PHEAD      82
     7,T40,'*                                                     *',/  PHEAD      83
     7,T40,'*               DATE OF RUN:  ',A9,T94,'*',/                PHEAD      84
     7,T40,'*                                                     *',/  PHEAD      85
     B,T40,'* COPYRIGHT @(1993) ELECTRIC POWER RESEARCH INSTITUTE *',/  PHEAD      86
     C,T40,'*                 ALL RIGHTS RESERVED                 *',/  PHEAD      87
     D,T40,'*******************************************************',/) PHEAD      88
      END                                                               PHEAD      89
C                                                                       PHEAD      90
      SUBROUTINE PRTMSG(ILINE)                                          PHEAD      91
CD                                                                      PHEAD      92
CD    THIS IS THE SUBROUTINE THAT ETMSP USES WIDELY TO PRINT ERROR AND  PHEAD      93
CD    WARNING MESSAGES ON BOTH SCREEN AND THE ERROR AND WARNING FILE.   PHEAD      94
CD                                                                      PHEAD      95
      INCLUDE 'CNLSTA.INS'                                              PHEAD      96
      INCLUDE 'CNUNIT.INS'                                              PHEAD      97
      INCLUDE 'CNMSG.INS'                                               PHEAD      98
C                                                                       PHEAD      99
      WRITE(LOUT,'(A)')                                                 PHEAD     100
      WRITE(IU16,'(A)')                                                 PHEAD     101
      IL=IL+1                                                           PHEAD     102
      DO 100 I=1,ILINE                                                  PHEAD     103
         IF(IL.GE.59)THEN                                               PHEAD     104
            IPAGE=IPAGE+1                                               PHEAD     105
            IL=4                                                        PHEAD     106
            WRITE(IU16,1010) IPAGE                                      PHEAD     107
         ENDIF                                                          PHEAD     108
         WRITE(LOUT,1000) MSG(I)                                        PHEAD     109
         WRITE(IU16,1000) MSG(I)                                        PHEAD     110
         IL=IL+1                                                        PHEAD     111
  100 CONTINUE                                                          PHEAD     112
      RETURN                                                            PHEAD     113
C                                                                       PHEAD     114
 1000 FORMAT(1X,A)                                                      PHEAD     115
 1010 FORMAT('1  WARNING AND ERROR MESSAGES REPORT',T68,'PAGE:',I4,//)  PHEAD     116
      END                                                               PHEAD     117
      SUBROUTINE PAGE6                                                  PHEAD     118
CD                                                                      PHEAD     119
CD    THIS IS THE ROUTINE THAT PRINTS PAGE NO. IN PROGRAM PROGRESS      PHEAD     120
CD    REPORT.                                                           PHEAD     121
CD                                                                      PHEAD     122
      INCLUDE 'CNUNIT.INS'                                              PHEAD     123
      SAVE IPAG6                                                        PHEAD     124
      DATA IPAG6/0/                                                     PHEAD     125
      IPAG6=IPAG6+1                                                     PHEAD     126
      WRITE(IU6,1000) IPAG6                                             PHEAD     127
      RETURN                                                            PHEAD     128
 1000 FORMAT('1  PROGRAM PROGRESS REPORT',T122,'PAGE:',I4,//)           PHEAD     129
      END                                                               PHEAD     130
      SUBROUTINE PAGE17                                                 PHEAD     131
CD                                                                      PHEAD     132
CD    THIS IS THE ROUTINE THAT PRINTS THE PAGE NO. IN SIMULATION        PHEAD     133
CD    REPORT.                                                           PHEAD     134
CD                                                                      PHEAD     135
      INCLUDE 'CNUNIT.INS'                                              PHEAD     136
      SAVE IPAG17                                                       PHEAD     137
      DATA IPAG17/0/                                                    PHEAD     138
      IPAG17=IPAG17+1                                                   PHEAD     139
      WRITE(IU17,1000) IPAG17                                           PHEAD     140
      RETURN                                                            PHEAD     141
 1000 FORMAT('1  SIMULATION RESULT REPORT',T122,'PAGE:',I4,//)          PHEAD     142
      END                                                               PHEAD     143
