Wrote up automatic figure numbering