Made novel CMC function backwards compatible to older numpy versions.