-
-///////////////////////////////////////////////////////////////////////////
-// This program is free software: you can redistribute it and/or modify //
-// it under the terms of the version 3 of the GNU General Public License //
-// as published by the Free Software Foundation. //
-// //
-// This program is distributed in the hope that it will be useful, but //
-// WITHOUT ANY WARRANTY; without even the implied warranty of //
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU //
-// General Public License for more details. //
-// //
-// You should have received a copy of the GNU General Public License //
-// along with this program. If not, see <http://www.gnu.org/licenses/>. //
-// //
-// Written by and Copyright (C) Francois Fleuret //
-// Contact <francois.fleuret@idiap.ch> for comments & bug reports //
-///////////////////////////////////////////////////////////////////////////
-
-#include <iostream>
-#include <fstream>
-#include <cmath>
-#include <stdio.h>
-#include <stdlib.h>
-
-using namespace std;
-
-int main(int argc, char **argv) {
- int nb_locations = 20;
- int nb_time_steps = 20;
-
- int nb_vertices = nb_time_steps * nb_locations + 2;
- int nb_edges = 2 * nb_locations + (nb_time_steps - 1) * (nb_locations * nb_locations);
- int source = 0;
- int sink = nb_vertices - 1;
-
- cout << nb_vertices << " " << nb_edges << endl;
- cout << source << " " << sink << endl;
- cout << endl;
-
- for(int l = 0; l < nb_locations; l++) {
- cout << source
- << " "
- << l + 1
- << " "
- << drand48() * 2 - 1
- << endl;
- }
-
- for(int t = 0; t < nb_time_steps - 1; t++) {
- for(int l = 0; l < nb_locations; l++) {
- for(int m = 0; m < nb_locations; m++) {
- cout << 1 + (t * nb_locations + l)
- << " "
- << 1 + ((t+1) * nb_locations + m)
- << " "
- << drand48() * 2 - 1
- << endl;
- }
- }
- }
-
- for(int l = 0; l < nb_locations; l++) {
- cout << 1 + ((nb_time_steps-1) * nb_locations + l)
- << " "
- << sink
- << " "
- << drand48() * 2 - 1
- << endl;
- }
-}