Using Fuzzy Logic to Analyze Superscript and Subscript Relations in Handwritten Mathematical Expressions