How are sectors and industry categories determined?

Avatar

For example, why are AMR and ARCH in completely different sectors? Don't they do basically the same thing?