What is the chemical composition of agar agar?

Agar is a sulfated polymer composed mainly of D-glucuronic acid. It is usually extracted from red algae.