Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions CITATION.cff
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@ authors:
repository-code: 'https://github.com/physycom/DynamicalSystemFramework'
url: 'https://physycom.github.io/DynamicalSystemFramework/'
license: CC-BY-NC-SA-4.0
version: 5.3.2
date-released: '2026-04-08'
version: 5.3.3
date-released: '2026-04-09'
2 changes: 1 addition & 1 deletion src/dsf/dsf.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

static constexpr uint8_t DSF_VERSION_MAJOR = 5;
static constexpr uint8_t DSF_VERSION_MINOR = 3;
static constexpr uint8_t DSF_VERSION_PATCH = 2;
static constexpr uint8_t DSF_VERSION_PATCH = 3;

static auto const DSF_VERSION =
std::format("{}.{}.{}", DSF_VERSION_MAJOR, DSF_VERSION_MINOR, DSF_VERSION_PATCH);
Expand Down
13 changes: 10 additions & 3 deletions src/dsf/mobility/FirstOrderDynamics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1020,6 +1020,7 @@ namespace dsf::mobility {
"maxspeed REAL NOT NULL, "
"name TEXT, "
"nlanes INTEGER NOT NULL, "
"coilcode TEXT, "
"geometry TEXT NOT NULL)");
// Create nodes table
this->database()->exec(
Expand All @@ -1031,8 +1032,8 @@ namespace dsf::mobility {
// Insert edges
SQLite::Statement insertEdgeStmt(*this->database(),
"INSERT INTO edges (id, source, target, length, "
"maxspeed, name, nlanes, geometry) "
"VALUES (?, ?, ?, ?, ?, ?, ?, ?);");
"maxspeed, name, nlanes, coilcode, geometry) "
"VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?);");
for (const auto& [edgeId, pEdge] : this->graph().edges()) {
insertEdgeStmt.bind(1, static_cast<std::int64_t>(edgeId));
insertEdgeStmt.bind(2, static_cast<std::int64_t>(pEdge->source()));
Expand All @@ -1041,7 +1042,13 @@ namespace dsf::mobility {
insertEdgeStmt.bind(5, pEdge->maxSpeed());
insertEdgeStmt.bind(6, pEdge->name());
insertEdgeStmt.bind(7, pEdge->nLanes());
insertEdgeStmt.bind(8, std::format("{}", pEdge->geometry()));
auto const& counterName{pEdge->counterName()};
if (counterName != "N/A") {
insertEdgeStmt.bind(8, counterName);
} else {
insertEdgeStmt.bind(8);
}
insertEdgeStmt.bind(9, std::format("{}", pEdge->geometry()));
insertEdgeStmt.exec();
insertEdgeStmt.reset();
}
Expand Down
3 changes: 2 additions & 1 deletion webapp/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -903,7 +903,7 @@ function parseGeometry(geometryStr) {

// Load edges from SQLite database
function loadEdgesFromDB() {
const result = db.exec("SELECT id, source, target, length, maxspeed, name, nlanes, geometry FROM edges");
const result = db.exec("SELECT id, source, target, length, maxspeed, name, nlanes, geometry, coilcode FROM edges");
if (result.length === 0) return [];

const columns = result[0].columns;
Expand All @@ -918,6 +918,7 @@ function loadEdgesFromDB() {
edge.maxspeed = +edge.maxspeed || 0;
edge.nlanes = +edge.nlanes || 1;
edge.length = +edge.length || 0;
edge.coilcode = edge.coilcode || null;
return edge;
});
}
Expand Down
Loading