Hi,
I am trying to create a simulator wherein i wish to use the tersoff potential. I am doing so by taking hint from the ex_test_Ar_fcc_cluster_cpp example given in the documentation. I am facing the issue right at the start. Here the snippet of my code:
string modelname;
int error;
printf("please enter valid KIM model name: \n");
std::cin >> modelname;
KIM::Model * kim_cluster_model;
int requestedUnitsAccepted;
error = KIM::Model::Create(KIM::NUMBERING::zeroBased,
KIM::LENGTH_UNIT::A,
KIM::ENERGY_UNIT::eV,
KIM::CHARGE_UNIT::e,
KIM::TEMPERATURE_UNIT::K,
KIM::TIME_UNIT::ps,
modelname,
&requestedUnitsAccepted,
&kim_cluster_model);
if (error) { MY_ERROR("KIM::Model::Create()"); }
// Check for compatibility with the model
if (!requestedUnitsAccepted) { MY_ERROR("Must Adapt to model units"); }
// print model units
KIM::LengthUnit lengthUnit;
KIM::EnergyUnit energyUnit;
KIM::ChargeUnit chargeUnit;
KIM::TemperatureUnit temperatureUnit;
KIM::TimeUnit timeUnit;
kim_cluster_model->GetUnits(
&lengthUnit, &energyUnit, &chargeUnit, &temperatureUnit, &timeUnit);
std::cout << "LengthUnit is \"" << lengthUnit.ToString() << "\"" << std::endl
<< "EnergyUnit is \"" << energyUnit.ToString() << "\"" << std::endl
<< "ChargeUnit is \"" << chargeUnit.ToString() << "\"" << std::endl
<< "TemperatureUnit is \"" << temperatureUnit.ToString() << "\""
<< std::endl
<< "TimeUnit is \"" << timeUnit.ToString() << "\"" << std::endl;
It works fine when i enter the KIM model name: LJ_Shifted_Bernardes_1958MedCutoff_Ar__MO_126566794224_004. But I get the error: * Error : “KIM::Model::Create()” when i enter the KIM model name as : Tersoff_LAMMPS_Tersoff_1988_C__MO_579868029681_004.
What is it that i am missing here?