Wodel applied to finite automata. [Finite Automata Ecore]

Mutations that change the language.

Create transition [ctr]:

     create Transition with {symbol = one Symbol}

Create final state [cfs]:

     s = create State with {isFinal = true}
     create Transition with {tar = s, symbol = one Symbol}

Create connected state [ccs]:

     s = create State with {name = random-string(1, 4)}
     t = create Transition with {tar = s, symbol = one Symbol}

Delete transition [dtr]:

     remove one Transition

Delete state and adjacent transitions [dst]:

     remove one State where {isInitial = false}
     remove all Transition where {src = null}
     remove all Transition where {tar = null}

Change symbol in transition [mst]:

     modify target symbol from one Transition to other Symbol

Change final state to non-final [mfs]:

     modify one State where {isFinal = true} with {reverse(isFinal)}

Change initial state to a different one [mis]:

     s0 = modify one State where {isInitial = true} with {isInitial = false}
     s1 = modify one State where {self <> s0} with {isInitial = true}

Swap direction of transition [sdt]:

     modify one Transition with {swapref(src, tar)}

Swap symbol of two sibling transitions [sst]:

     t = select one Transition
     modify one Transition where {self <> t and src = t->src} with {swapref(symbol, t->symbol)}

Redirect transition to a new final state [rts]:

     s = create State with {name = 'f', isFinal = true}
     modify target tar from one Transition to s

Combination of adding a new transition and changing the initial state [ctr_mis]:

     s0 = modify one State where {isInitial = true} with {reverse(isInitial)}
     s1 = modify one State where {self <> s0} with {isInitial = true}
     create Transition with {src = s1, tar = s0, symbol = one Symbol}

Mutations that produce a non-deterministic automaton.

Create lambda-transition [clt]:

     create Transition

Create transition with same symbol from a state to a different one [cst]:

     t = select one Transition where {symbol <> null}
     create Transition with {src = t->src, symbol = t->symbol, tar = one State where {self <> t->tar}}

Here you can download all these examples of Wodel applied to finite automata.
DFA samples .zip
DFA samples .tar.gz

Acknowledgements

This work has been funded by the Spanish Ministry of Science (RTI2018-095255-B-I00, project "MASSIVE") and the R&D programme of Madrid (P2018/TCS-4314, project "FORTE").