Initial version from parMERASA repository