      subroutine reset(ts,fs,igr,isyst,ns,isymce,iwarn,icalc,iat,nhisto,RESE001
     &                  histo)                                          RESE002
c ----------------------------------------------------------------------RESE003
c     This program module is part of the author's X-ray Library         RESE004
c     and may not be sold or reproduced for commercial purposes.        RESE005
c     Although it has been tested carefully, there is no warranty       RESE006
c     regarding accuracy or freedom from side-effects.                  RESE007
c                   (C) 1986-1994 Bernhard Rupp                         RESE008
c ----------------------------------------------------------------------RESE009
c     RESET resets critical variables to zero (compiler independent)    RESE010
c ----------------------------------------------------------------------RESE011
                                                                        RESE012
      dimension igr(36), fs(3,3,24), ts(3,24), iwarn(iat),icalc(iat)    RESE013
      dimension histo(nhisto)                                           RESE014
      isyst=0                                                           RESE015
      ns=0                                                              RESE016
      isymce=0                                                          RESE017
c --- reset spacgrp symbols -                                           RESE018
      do 0001 i=1,36                                                    RESE019
 0001       igr(i)=' '                                                  RESE020
                                                                        RESE021
c --- reset transformation matrix -                                     RESE022
      do 0002 i=1,3                                                     RESE023
         do 0002 j=1,3                                                  RESE024
            do 0002 k=1,24                                              RESE025
               ts(i,k)=0.0                                              RESE026
               fs(i,j,k)=0.0                                            RESE027
 0002 continue                                                          RESE028
                                                                        RESE029
c --- unit transformation for trivial position k=1                      RESE030
      do 0003 i=1,3                                                     RESE031
 0003    fs(i,i,1)=1.0                                                  RESE032
                                                                        RESE033
c --- reset warning flag and icalc                                      RESE034
      do 0004 i=1,iat                                                   RESE035
         icalc(i)=0                                                     RESE036
 0004    iwarn(i)=0                                                     RESE037
                                                                        RESE038
      do 0005 i=1,nhisto                                                RESE039
         histo(i)=0.0                                                   RESE040
 0005 continue                                                          RESE041
                                                                        RESE042
      return                                                            RESE043
      end                                                               RESE044
                                                                        RESE045
                                                                        RESE046
