MobilityDB 1.3
Loading...
Searching...
No Matches
Macros | Functions
tbl_tpoint_tpoint.c File Reference

A simple program that reads a CSV files containing temporal circular buffers and performs a "self join" by restricting couples of temporal circular buffers. More...

#include <stdio.h>
#include <stdlib.h>
#include <meos.h>
#include <meos_geo.h>

Macros

#define MAX_LENGTH_HEADER   1024
 
#define MAX_LENGTH_TGEO   7501
 

Functions

int main (void)
 

Detailed Description

A simple program that reads a CSV files containing temporal circular buffers and performs a "self join" by restricting couples of temporal circular buffers.

The corresponding SQL query would be

SELECT t1.k, t2.k, numInstants(tIntersects(t1.temp, t2.temp))
FROM tbl_tgeompoint t1, tbl_tgeompoint t2
WHERE tIntersects(t1.temp, t2.temp) IS NOT NULL;

The program can be tested with several functions such as spatiotemporal relationships eIntersects, eDwithin, ..., aIntersects, aDwithin, ..., tIntersects, tDwithin, ..., temporal distance ...

The program can be build as follows

gcc -Wall -g -I/usr/local/include -o tbl_tpoint_tpoint tbl_tpoint_tpoint.c -L/usr/local/lib -lmeos