C++ file for HMMs