/// <summary>
        /// Goes through the steps of the AlphaMiner Algorithm:
        /// </summary>
        /// <param Name="field">A field from the DataSelection</param>
        /// <returns>A PetriNet as a ProcessModel</returns>
        /// <exception cref="ArgumentNullException">If the field-parameter is null.</exception>
        /// <author>Krystian Zielonka, Christopher Licht</author>
        public ProcessModel Mine()
        {
            if (_field == null)
            {
                throw new ArgumentNullException("field", "The field parameter was null");
            }

            // Get parameters from MinerSettings
            String alphaMinerSettings = MinerSettings.GetAsString("Alpha Miner");

            // Start - Statistics
            TimeSpan ProcessingTimeStart = Process.GetCurrentProcess().TotalProcessorTime;

            DetectActivitiySet();
            DetectStartAndEndActivitiesInTraces();

            DetectAllPlaces();

            switch (alphaMinerSettings)
            {
            case "AlphaMinerPlus":
                CorrectParallelPairs();
                break;

            case "AlphaMinerPlusPlus":
                Preprocessing();
                Postprocessing();
                CorrectParallelPairs();
                break;

            default:
                break;
            }

            AddsPlacesTogether();
            RemoveAllDuplicatePlaces();

            BuildTheNet();

            // End - Statistics
            TimeSpan ProcessingTimeEnd = Process.GetCurrentProcess().TotalProcessorTime;

            //Information about the generated petri net
            PetriNetInformation(_field, ref ProcessingTimeStart, ref ProcessingTimeEnd);

            //Check for errors in the field
            DoErrorHandling();

            return(_petriNet);
        }