Fix initialization of transport_names in ChemistryInit and GridInit

This commit is contained in:
Max Luebke 2024-04-03 13:00:58 +00:00
parent 7655376f89
commit dd5c14aa88
2 changed files with 3 additions and 1 deletions

View File

@ -6,6 +6,8 @@
namespace poet {
void InitialList::initChemistry(const Rcpp::List &chem) {
this->pqc_sol_order = this->transport_names;
if (chem.containsElementNamed("dht_species")) {
this->dht_species = Rcpp::as<NamedVector<uint32_t>>(chem["dht_species"]);
}

View File

@ -165,7 +165,7 @@ void InitialList::prepareGrid(const Rcpp::List &grid_input) {
std::vector<std::string> colnames =
Rcpp::as<std::vector<std::string>>(this->initial_grid.names());
this->transport_names = this->pqc_sol_order = std::vector<std::string>(
this->transport_names = std::vector<std::string>(
colnames.begin() + 1,
colnames.begin() + 1 + solution_count); // skip ID