finished adding support for density as a unit type