
      SUBROUTINE UPPOL(POLAR,POLAR2,UPDATE)
      IMPLICIT DOUBLE PRECISION(A-H,O-Z)
      LOGICAL UPDATE
      DIMENSION POLAR(3,3),POLAR2(3,3)

      IF (UPDATE) THEN
         OPEN(UNIT=83,FILE='POLAR',STATUS='OLD',FORM='FORMATTED')
         READ(83,3000) (POLAR2(I,1),I=1,3)
         READ(83,3000) (POLAR2(I,2),I=1,3)
         READ(83,3000) (POLAR2(I,3),I=1,3)
3000     FORMAT(3F20.10)
         CALL SAXPY(9,1.0d0,POLAR2,1,POLAR,1)
      ELSE
         OPEN(UNIT=83,FILE='POLAR',STATUS='OLD',FORM='FORMATTED')
      END IF

      REWIND(83)
      WRITE(83,3000) (POLAR(I,1),I=1,3)
      WRITE(83,3000) (POLAR(I,2),I=1,3)
      WRITE(83,3000) (POLAR(I,3),I=1,3)

      CLOSE(UNIT=83,STATUS='KEEP')

      RETURN
      END
