make functions include as_logical.hpp instead of logical.hpp + move logical_ hierarchy to category.hpp