Code development platform for open source projects from the European Union institutions :large_blue_circle: EU Login authentication by SMS has been phased out. To see alternatives please check here

Skip to content
Snippets Groups Projects
Select Git revision
  • 65f72134aa3f40d73082d9a7be78a6654feab6f0
  • amdm2/main default
  • doc-fixes
  • amdm3/develop
  • vehmetrics
  • feature/generic_vehicles_tests
  • trailer-stable
  • trailer
  • pubcode
  • bugfix/CodeEU-547_MaxICEOffTimespan
  • ci
  • stable protected
  • bugfix/CodeEU-235_Tyre_XML-type_VIF
  • revert-f849ae0c
  • Project_VECTO_FD_II/FMI/AMTShiftStratgy
  • Project_VECTO_FD_II/FMI/HybridController
  • feature/CodeEU-51_Extend-ADC-lossmap-declaration-mode
  • tug-dev
  • develop
  • hm_feature/vecto-40-add-nuget
  • tug-stable
  • Release/v4.1.0.3392-RC
  • Release/v4.0.3.3330
  • Release/v4.0.2.3275
  • Release/v4.0.2.3273
  • Release/v0.11.1.3228-DEV
  • Project_VECTO_FD_II/FMI/HybridController
  • Project_VECTO_FD_II/FMI/AMTShiftStrategy
  • Release/v4.0.1.3217
  • Release/v4.0.0.3211
  • Release/v0.11.0.3193-DEV
  • Release/v4.0.0.3161-RC
  • Release/v4.0.0.3106-RC
  • Release/v3.3.15.3102
  • Release/v4.0.0.3078-RC
  • Release/v3.3.15.3073-RC
  • test-tag
  • Release/v3.3.14.3011
  • Build/v0.7.10.2996
  • v0.7.5b0+2524.multistep
  • Release/v3.3.14.2981-RC
41 results

Program.cs

Blame
  • Forked from VECTO / VECTO Sim
    5750 commits behind the upstream repository.
    Code owners
    Assign users and groups as approvers for specific file changes. Learn more.
    Program.cs 2.73 KiB
    /*
    * This file is part of VECTO.
    *
    * Copyright © 2012-2019 European Union
    *
    * Developed by Graz University of Technology,
    *              Institute of Internal Combustion Engines and Thermodynamics,
    *              Institute of Technical Informatics
    *
    * VECTO is licensed under the EUPL, Version 1.1 or - as soon they will be approved
    * by the European Commission - subsequent versions of the EUPL (the "Licence");
    * You may not use VECTO except in compliance with the Licence.
    * You may obtain a copy of the Licence at:
    *
    * https://joinup.ec.europa.eu/community/eupl/og_page/eupl
    *
    * Unless required by applicable law or agreed to in writing, VECTO
    * distributed under the Licence is distributed on an "AS IS" basis,
    * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    * See the Licence for the specific language governing permissions and
    * limitations under the Licence.
    *
    * Authors:
    *   Stefan Hausberger, hausberger@ivt.tugraz.at, IVT, Graz University of Technology
    *   Christian Kreiner, christian.kreiner@tugraz.at, ITI, Graz University of Technology
    *   Michael Krisper, michael.krisper@tugraz.at, ITI, Graz University of Technology
    *   Raphael Luz, luz@ivt.tugraz.at, IVT, Graz University of Technology
    *   Markus Quaritsch, markus.quaritsch@tugraz.at, IVT, Graz University of Technology
    *   Martin Rexeis, rexeis@ivt.tugraz.at, IVT, Graz University of Technology
    */
    
    using System;
    using System.Linq;
    using TUGraz.VectoCore.Tests.Utils;
    
    namespace GraphDrawer
    {
        internal class Program
        {
            private const string HELP = @"
    Tool for plotting graphs comparing Vecto 2.2 and Vecto 3
    
    --split <leng> ... split input into parts of length <len> (in m), only distance output
    
    ";
    
            private static void Main(string[] args)
            {
    			var graphWriter = new GraphWriter();
                if (args.Contains("--split")) {
    				Console.Error.WriteLine("plotting graphs splitted by distance");
                    var idx = Array.FindIndex(args, x => x == "--split");
                    var lenght = int.Parse(args[idx + 1]);
                    var success = true;
                    var start = 0;
                    do {
    					Console.Error.WriteLine("plotting {0} - {1}", start / 1000, (start + lenght) / 1000);
    					success = graphWriter.WriteDistanceSlice(args[0], args[1], start, start + lenght);
                        start += lenght;
                    } while (success);
    				Console.Error.WriteLine("plotting full cycle");
                    graphWriter.Write(args[0], args[1]);
    				Console.Error.WriteLine("done");
                    return;
                }
    			Console.Error.WriteLine("plotting graphs...");
                graphWriter.Write(args[0], args[1]);
    			Console.Error.WriteLine("done");
            }
        }
    }