To show the average of a and b, use a fraction with the whole sum above the line. In Ulet choose Insert → Formula → Insert New Equation (LaTeX).

Check both groups in the preview

\frac{a+b}{2}

The first braces hold the numerator, the second the denominator. Check for missing braces if the preview errors. Use inline placement for a short expression in a sentence, or give the example its own line.

Both a and b are grouped in the numerator above 2.

Illustrated fraction structure.

Verify the math and the saved layout

Substitute 6 and 10. The expected result is (6 + 10) ÷ 2 = 8. Reopen the DOCX and check that the entire sum remains above the bar. Read the same equation in the output PDF if readers will get one.

Using a = 6 and b = 10 gives an average of 8.

Illustrated numeric check on grouping.