This paper proposes an algorithm called MACH for coding a hierarchical category structure to enable prefix matching between a publication and a subscription. Compared to fixed-length coding, the MACH algorithm generates shorter code lengths without losing the efficiency of matching.
In addition, the MACH algorithm automatically identifies the bits that are not necessary for prefix matching. These bits are saved to allow growth of categories. The bit saving is prioritized according to a configurable criterion. Experiments with real world data and synthetic data are conducted to evaluate the benefit of the proposed algorithm.