Add Matern support in C++