From e42eace5c9e70f9c17f05831856ff671a19bf81a Mon Sep 17 00:00:00 2001
From: "sonia.bilbao@tecnalia.com" <sonia.bilbao@tecnalia.com>
Date: Thu, 2 Dec 2021 09:49:12 +0100
Subject: [PATCH] added OD matrix

---
 datamodels/ODMatrix-ngsi.jsonld    | 36 +++++++++++++++++++++++++
 datamodels/ODMatrix_example.jsonld | 43 ++++++++++++++++++++++++++++++
 datamodels/event_example.jsonld    |  2 +-
 3 files changed, 80 insertions(+), 1 deletion(-)
 create mode 100644 datamodels/ODMatrix-ngsi.jsonld
 create mode 100644 datamodels/ODMatrix_example.jsonld

diff --git a/datamodels/ODMatrix-ngsi.jsonld b/datamodels/ODMatrix-ngsi.jsonld
new file mode 100644
index 0000000..84532a9
--- /dev/null
+++ b/datamodels/ODMatrix-ngsi.jsonld
@@ -0,0 +1,36 @@
+{
+	"@context": [
+		{
+			"OriginDestinationMatrix": "https://urbanite-project.eu/ontology/OriginDestinationMatrix",
+			"zones": {
+				"@id": "https://urbanite-project.eu/ontology/zones",
+				"@type": "https://schema.org/Text",
+			},
+			"travelMode": {
+				"@id": "https://urbanite-project.eu/ontology/travelMode",
+				"@type": "https://schema.org/Text"
+			},
+			"departsFrom": {
+				"@id": "https://urbanite-project.eu/ontology/departsFrom",
+				"@type": "https://schema.org/Text"
+			},
+			"arrivesTo": {
+				"@id": "https://urbanite-project.eu/ontology/arrivesTo",
+				"@type": "https://schema.org/Text"
+			},
+			"aggregationType": {
+				"@id": "https://urbanite-project.eu/ontology/aggregationType",
+				"@type": "https://schema.org/Text"
+			},
+			"startPeriod": {
+				"@id": "https://urbanite-project.eu/ontology/startPeriod",
+				"@type": "https://schema.org/Text"
+			},
+			"endPeriod": {
+				"@id": "https://urbanite-project.eu/ontology/endPeriod",
+				"@type": "https://schema.org/Text"
+			},
+		},
+		"https://uri.etsi.org/ngsi-ld/v1/ngsi-ld-core-context.jsonld"
+	]
+}
diff --git a/datamodels/ODMatrix_example.jsonld b/datamodels/ODMatrix_example.jsonld
new file mode 100644
index 0000000..e5658f2
--- /dev/null
+++ b/datamodels/ODMatrix_example.jsonld
@@ -0,0 +1,43 @@
+{
+  "id": "urn:ngsi-ld:odm:bilbao:wifi:daily:270720212355",
+  "type": "OriginDestinationMatrix",
+  "category": "wifi",
+  "startDate": "2021-09-01",
+  "endDate": "2021-09-30",
+  "createdAt": "2021-12-01T13:39:10.00Z",
+  "modifiedAt": "2021-12-01T13:39:10.00Z",
+  "travelMode": "all",
+  "aggregationType": "daily",
+  "startPeriod": "00:00",
+  "endPeriod": "23:59",  
+  "zones": "Bilbao_zones",  
+  "matrixData": [
+      {
+        "departsFrom": "ACCESOS V (ACCESOS VIARIOS)",
+        "arrivesTo": "ACCESOS V (ACCESOS VIARIOS)",
+        "volume": 1246,
+	"volumePercentage": 3.15,
+	"time": 38,
+      },
+      {
+        "departsFrom": "ACCESOS V (ACCESOS VIARIOS)",
+        "arrivesTo": "BASURTO",
+        "volume": 3581,
+	"volumePercentage": 9.05,
+	"time": 33,
+      },
+      {
+        "departsFrom": "ACCESOS V (ACCESOS VIARIOS)",
+        "arrivesTo": "CASCO VIEJO",
+        "volume": 899,
+	"volumePercentage": 2.27,
+	"time": 66,
+      }
+    ],
+  "@context": [
+    "https://smartdatamodels.org//context.jsonld",
+    "https://git.code.tecnalia.com/urbanite/public/-/raw/main/datamodels/ODMatrix-ngsi.jsonld"
+  ]
+}
+
+
diff --git a/datamodels/event_example.jsonld b/datamodels/event_example.jsonld
index 151e893..c492241 100644
--- a/datamodels/event_example.jsonld
+++ b/datamodels/event_example.jsonld
@@ -2,7 +2,7 @@
   "id": "urn:ngsi-ld:event:bilbao:football:270720212355",
   "type": "Event",
   "startDate": "2021-10-15T16:30:00",
-  "endDate": "2021-10-15T18:15:00"
+  "endDate": "2021-10-15T18:15:00",
   "location": {
     "coordinates": [
           43.264205, -2.949369,
-- 
GitLab