Recognition of handwritten mathematical expressions has been an important topic for many researchers for decades. It remains one of the most challenging and exciting areas in pattern recognition. In the recognition process of offline handwritten mathematical expressions, segmentation is the most important process. Problems in ambiguities of identifying superscript and subscript in complex offline mathematical expressions remain one of the most important problem. To the best of our knowledge little work has been done in the segmentation of offline handwritten mathematical expressions with respect to superscript and subscript. In this paper an efficient segmentation technique for superscript, subscript and main characters within offline handwritten mathematical expressions has been proposed. This technique is based on the generation of predictions for superscript, subscript and main characters within handwritten mathematical expressions, which helps for the reconstruction of mathematical expressions during the recognition process with their spatial interrelationship. The proposed system was conducted as an experiment with a database of 300 samples of scanned mathematical expressions that comprised 2,000 symbols out of which there were 31 different types of Mathematical Symbols. The classification of the elements was carried out by the K-NN-classifier based on density features. This experiment shows remarkable results.