public static Automaton randomAutomaton(Random random){
  Automaton a1=randomSingleAutomaton(random);
  Automaton a2=randomSingleAutomaton(random);
switch (random.nextInt(4)) {
case 0:
    return Operations.concatenate(a1,a2);
case 1:
  return Operations.union(a1,a2);
case 2:
return Operations.intersection(a1,a2);
default :
return Operations.minus(a1,a2,DEFAULT_MAX_DETERMINIZED_STATES);
}
}

public static Automaton randomAutomaton ( Random random ) { Automaton a1 = randomSingleAutomaton ( random ) ; Automaton a2 = randomSingleAutomaton ( random ) ; switch ( random . nextInt ( 4 ) ) { case 0 : return Operations . concatenate ( a1 , a2 ) ; case 1 : return Operations . union ( a1 , a2 ) ; case 2 : return Operations . intersection ( a1 , a2 ) ; default : return Operations . minus ( a1 , a2 , DEFAULT_MAX_DETERMINIZED_STATES ) ; } }
return a random nfa / dfa for testing
