 /* #include histogram.h --  definitions for histogram.c */

 /* This histogram mechanism was adapted from the UCLA Arpanet Control
  *   Program (ACP) facility, which accounts for a little wierdness.
  *      Bob Braden  USC-ISI
  */
  

 /*  HCB structure -- Histogram Control Block */
#define HCB struct hcb_stru
 
 HCB {
     char *hcb_link ;
     char *hcb_pta ;   /* You don't want to know */
     char  hcb_name[12];
 
     int   hcb_scale ;
     int   hcb_orig  ;
     char  hcb_size  ;
     char  hcb_flag  ;
     short hcb_mbin  ;
     /*  followed by data... */
     int   hcb_bins[1] ;	/* variable-length array of bins */
     } ; 
 
#define HCFclear  128
#define HCFactive  64
#define HCFcreate  32
#define HCFsearch  16
#define HCFhalfw   08

#define HCBdefine( handle, SCALE, ORIGIN, MAXBIN, name) \
	struct  { \
		HCB HCB_part  ; \
		int hcb_rest[MAXBIN] ; } handle \
		 = { NULL, NULL, "", SCALE, ORIGIN, 0, 0, MAXBIN, 0}  ;

#define HCBclear( handle )   \
     ( (HCB *) handle)->hcb_flag |= HCFclear 
