{-|
Configurations might work for @PetriGraphToMath@ and @PetriMathToGraph@ tasks
-}
module Modelling.PetriNet.PetriGraphToMath.Config where

import Modelling.PetriNet.MatchToMath (
  MathConfig (..),
  )
import Modelling.PetriNet.Types (
  AdvConfig (..),
  AlloyConfig (..),
  BasicConfig (..),
  ChangeConfig (..),
  GraphConfig (..),
  )
import Data.GraphViz.Commands           (GraphvizCommand(..))

{-|
points: 0.15
average generation time per instance: 4:00min
CPU usage: 110%
-}
task2023_17 :: MathConfig
task2023_17 :: MathConfig
task2023_17 = MathConfig {
  $sel:basicConfig:MathConfig :: BasicConfig
basicConfig = BasicConfig {
    $sel:places:BasicConfig :: Int
places = Int
5,
    $sel:transitions:BasicConfig :: Int
transitions = Int
7,
    $sel:atLeastActive:BasicConfig :: Int
atLeastActive = Int
3,
    $sel:flowOverall:BasicConfig :: (Int, Int)
flowOverall = (Int
13, Int
15),
    $sel:maxTokensPerPlace:BasicConfig :: Int
maxTokensPerPlace = Int
2,
    $sel:maxFlowPerEdge:BasicConfig :: Int
maxFlowPerEdge = Int
1,
    $sel:tokensOverall:BasicConfig :: (Int, Int)
tokensOverall = (Int
10, Int
10),
    $sel:isConnected:BasicConfig :: Maybe Bool
isConnected = Bool -> Maybe Bool
forall a. a -> Maybe a
Just Bool
True
    },
  $sel:advConfig:MathConfig :: AdvConfig
advConfig = AdvConfig {
    $sel:presenceOfSelfLoops:AdvConfig :: Maybe Bool
presenceOfSelfLoops = Bool -> Maybe Bool
forall a. a -> Maybe a
Just Bool
False,
    $sel:presenceOfSinkTransitions:AdvConfig :: Maybe Bool
presenceOfSinkTransitions = Bool -> Maybe Bool
forall a. a -> Maybe a
Just Bool
False,
    $sel:presenceOfSourceTransitions:AdvConfig :: Maybe Bool
presenceOfSourceTransitions = Bool -> Maybe Bool
forall a. a -> Maybe a
Just Bool
True
    },
  $sel:changeConfig:MathConfig :: ChangeConfig
changeConfig = ChangeConfig {
    $sel:tokenChangeOverall:ChangeConfig :: Int
tokenChangeOverall = Int
0,
    $sel:maxTokenChangePerPlace:ChangeConfig :: Int
maxTokenChangePerPlace = Int
0,
    $sel:flowChangeOverall:ChangeConfig :: Int
flowChangeOverall = Int
2,
    $sel:maxFlowChangePerEdge:ChangeConfig :: Int
maxFlowChangePerEdge = Int
1
    },
  $sel:generatedWrongInstances:MathConfig :: Int
generatedWrongInstances = Int
300,
  $sel:graphConfig:MathConfig :: GraphConfig
graphConfig = GraphConfig {
    $sel:graphLayouts:GraphConfig :: [GraphvizCommand]
graphLayouts = [GraphvizCommand
Sfdp],
    $sel:hidePlaceNames:GraphConfig :: Bool
hidePlaceNames = Bool
False,
    $sel:hideTransitionNames:GraphConfig :: Bool
hideTransitionNames = Bool
False,
    $sel:hideWeight1:GraphConfig :: Bool
hideWeight1 = Bool
True
    },
  $sel:printSolution:MathConfig :: Bool
printSolution = Bool
True,
  $sel:useDifferentGraphLayouts:MathConfig :: Bool
useDifferentGraphLayouts = Bool
False,
  $sel:wrongInstances:MathConfig :: Int
wrongInstances = Int
3,
  $sel:alloyConfig:MathConfig :: AlloyConfig
alloyConfig = AlloyConfig {
    $sel:maxInstances:AlloyConfig :: Maybe Integer
maxInstances = Integer -> Maybe Integer
forall a. a -> Maybe a
Just Integer
2000,
    $sel:timeout:AlloyConfig :: Maybe Int
timeout = Maybe Int
forall a. Maybe a
Nothing
    },
  $sel:extraText:MathConfig :: Maybe (Map Language String)
extraText = Maybe (Map Language String)
forall a. Maybe a
Nothing
  }

{-|
points: 0.15
average generation time per instance: 6:00min
CPU usage: 110%
-}
task2023_18 :: MathConfig
task2023_18 :: MathConfig
task2023_18 = MathConfig {
  $sel:basicConfig:MathConfig :: BasicConfig
basicConfig = BasicConfig {
    $sel:places:BasicConfig :: Int
places = Int
6,
    $sel:transitions:BasicConfig :: Int
transitions = Int
5,
    $sel:atLeastActive:BasicConfig :: Int
atLeastActive = Int
2,
    $sel:flowOverall:BasicConfig :: (Int, Int)
flowOverall = (Int
15, Int
17),
    $sel:maxTokensPerPlace:BasicConfig :: Int
maxTokensPerPlace = Int
1,
    $sel:maxFlowPerEdge:BasicConfig :: Int
maxFlowPerEdge = Int
1,
    $sel:tokensOverall:BasicConfig :: (Int, Int)
tokensOverall = (Int
5, Int
5),
    $sel:isConnected:BasicConfig :: Maybe Bool
isConnected = Bool -> Maybe Bool
forall a. a -> Maybe a
Just Bool
True
    },
  $sel:advConfig:MathConfig :: AdvConfig
advConfig = AdvConfig {
    $sel:presenceOfSelfLoops:AdvConfig :: Maybe Bool
presenceOfSelfLoops = Bool -> Maybe Bool
forall a. a -> Maybe a
Just Bool
True,
    $sel:presenceOfSinkTransitions:AdvConfig :: Maybe Bool
presenceOfSinkTransitions = Bool -> Maybe Bool
forall a. a -> Maybe a
Just Bool
False,
    $sel:presenceOfSourceTransitions:AdvConfig :: Maybe Bool
presenceOfSourceTransitions = Bool -> Maybe Bool
forall a. a -> Maybe a
Just Bool
False
    },
  $sel:changeConfig:MathConfig :: ChangeConfig
changeConfig = ChangeConfig {
    $sel:tokenChangeOverall:ChangeConfig :: Int
tokenChangeOverall = Int
0,
    $sel:maxTokenChangePerPlace:ChangeConfig :: Int
maxTokenChangePerPlace = Int
0,
    $sel:flowChangeOverall:ChangeConfig :: Int
flowChangeOverall = Int
2,
    $sel:maxFlowChangePerEdge:ChangeConfig :: Int
maxFlowChangePerEdge = Int
1
    },
  $sel:generatedWrongInstances:MathConfig :: Int
generatedWrongInstances = Int
300,
  $sel:graphConfig:MathConfig :: GraphConfig
graphConfig = GraphConfig {
    $sel:graphLayouts:GraphConfig :: [GraphvizCommand]
graphLayouts = [GraphvizCommand
Fdp],
    $sel:hidePlaceNames:GraphConfig :: Bool
hidePlaceNames = Bool
False,
    $sel:hideTransitionNames:GraphConfig :: Bool
hideTransitionNames = Bool
False,
    $sel:hideWeight1:GraphConfig :: Bool
hideWeight1 = Bool
True
    },
  $sel:printSolution:MathConfig :: Bool
printSolution = Bool
True,
  $sel:useDifferentGraphLayouts:MathConfig :: Bool
useDifferentGraphLayouts = Bool
False,
  $sel:wrongInstances:MathConfig :: Int
wrongInstances = Int
3 ,
  $sel:alloyConfig:MathConfig :: AlloyConfig
alloyConfig = AlloyConfig {
    $sel:maxInstances:AlloyConfig :: Maybe Integer
maxInstances = Integer -> Maybe Integer
forall a. a -> Maybe a
Just Integer
2000,
    $sel:timeout:AlloyConfig :: Maybe Int
timeout = Maybe Int
forall a. Maybe a
Nothing
    },
  $sel:extraText:MathConfig :: Maybe (Map Language String)
extraText = Maybe (Map Language String)
forall a. Maybe a
Nothing
  }

{-|
points: 0.1
average generation time per instance: 5:16min
CPU usage: 105%
-}
task2024_21 :: MathConfig
task2024_21 :: MathConfig
task2024_21 = MathConfig
task2023_17

{-|
points: 0.1
average generation time per instance: 10:28min
CPU usage: 103%
-}
task2024_22 :: MathConfig
task2024_22 :: MathConfig
task2024_22 = MathConfig
task2023_18