added density method