Package fmg.fmg8.endlAutomat

Examples of fmg.fmg8.endlAutomat.EndlicherAutomat


     */
    public static void main(final String[] args) {
        Parametersatz params = new Parametersatz(args);
        Translator transNeu = Konstanten.STD_TRANSL_BE;

        EndlicherAutomat autNeu = new EndlicherAutomat();
       
        String t1Std
            = "001, 003, 004, 001, 000, 012, 001, 010, "
            + "000, 005, 000, 012, 003, 000, 012, 007, "
            + "000, 005, 000, 010, 000, 000, 002, 001, "
            + "000, 012, 001, 010, 000, 005, 000, 012, "
            + "003, 000, 012, 007, 000, 006, 000, 010, "
            + "000, 000, 003, 001, 000, 000, 000, 003, "
            + "005, 050, 001, 000, 000, 000, 002, 004, "
            + "050, 001, 000, 000, 000, 000, 000, 007, "
            + "000, 000, 000, 000, 000";
       
        String t1 = autNeu.bereinige(t1Std);
        String t2 = "";
       
        new ScriptInterpreter(
                params, SonstMeth.MODUS_VERHALTEN).generateAutomaton(
                        autNeu, transNeu.translate(t1));
        t2 = autNeu.erzeugeStringSeq();
       
        SonstMeth.unterscheide(t1Std, t2, params);
    }
View Full Code Here


     *
     * @return  Die mutierte Bedingung.
     */
    @Override
    public Condition mutiere(final Condition cond) {
        EndlicherAutomat aut = new EndlicherAutomat();
        Long[] intObj = new Long[5];
        ArrayList<Long> vert = new ArrayList<Long>(5);
       
        aut.einfuegenKnoten(1, 1, 1, 1);
        aut.einfuegKante(1, 1, cond, 1);

       
        for (int i = 0; i < intObj.length; i++) {
            intObj[i] = new Long(i);
        }
       
        vert.add(new Long(10)); // 0 : mutationBedA
        vert.add(new Long(9)); //  1 : mutationBedBeinfacher
        vert.add(new Long(3)); //  2 : mutationBedZahl
        vert.add(new Long(6)); //  3 : mutationBedkomplexer
        vert.add(new Long(1)); //  4 : mutationBedSensVar
       
        Long rnd = (Long) MathMeth.randVerteilung(intObj,
                                                  vert,
                                                  super.getRand());
       
        switch(rnd.intValue()) {
        case 0:
            this.mutationBedA(aut);
            break;
        case 1:
            this.mutationBedBeinfacher(aut);
            break;
        case 2:
            this.mutationBedZahl(aut);
            break;
        case 3:
            this.mutationBedkomplexer(aut);
            break;
        case 4:
            this.mutationBedSensVar(aut);
            break;
        default:
            break;
        }

        return aut.holeKnoten(1).getInfo().getBedingungen().get(0).getCond();
    }
View Full Code Here

     *
     * @return  Die neue Roboterliste, die nur den Eintrag 0 enth�lt.
     */
    public RobCode[] rekombEinz(final Roboter[] rob) {
        RobCode[] robC = new RobCode[1];
        EndlicherAutomat kind = new EndlicherAutomat();
        int id = rob[0].getId();
        long fitness;
        ArrayList<Long> vert = new ArrayList<Long>(rob.length);
        ArrayList<Integer> zustaende;
        boolean vorhandenAll;
        Iterator<Integer> it, it1, it2;
        Integer aktName;
        Knoten[] knotenListe = new Knoten[rob.length];
        Knoten zwischKnoten;
        Integer kn1, kn2;
        Knoten zKnoten;
        Condition zCond;
        int aktion;
        int param;      
        int alt;
        boolean istStart;
        Roboter aktRob;
        Condition[] condListe = new Condition[rob.length];
        int j = -1;
       
        /*
         * Ersetzt alle Vorkommnisse von <code>null</code> im Array rob durch
         * g�ltige im Array weiter vorne stehende Roboter. Dabei wird die
         * Liste der Roboter VOR dem ersten Vorkommnis von <code>null</code>
         * immer wieder �ber das Array gelegt und die null-Werte werden
         * �berschrieben:
         *
         * [1 3 null null null null] => [1 3 1 3 1 3].
         *
         * Wenn nach dem ersten Vorkommnis von <code>null</code> ein g�ltiger
         * Roboter vorkommt (dies ist kein erw�nschter Fall), dann wird er
         * im Array belassen.
         */
        for (int i = 0; i < rob.length; i++) {
            if (rob[i] == null) {
                if (j < 0) {
                    j = i;
                }
                rob[i] = rob[i % j];
            }
        }
       
        for (int i = 0; i < rob.length; i++) {
            if (rob[i].getFitness()[0] > 0) {
                vert.add(new Long(rob[i].getFitness()[0]));
            } else {
                vert.add(new Long(0));
            }
        }

        aktRob = (Roboter) MathMeth.randVerteilung(rob, vert, this.rand);
        zustaende = aktRob.vAuts()[0].getKnList();
        fitness = aktRob.getFitness()[0];
       
        vorhandenAll = true;
       
        it = zustaende.iterator();
        while (it.hasNext()) {
            aktName = (Integer) it.next();
            for (int i = 0; i < rob.length; i++) {
                zwischKnoten = rob[i].vAuts()[0].holeKnoten(aktName);
                if (zwischKnoten != null) {
                    knotenListe[i] = zwischKnoten;
                } else {
                    vorhandenAll = false;
                    break;
                }
            }
           
            if (vorhandenAll) {
                zKnoten = (Knoten) MathMeth.randVerteilung(knotenListe,
                                                           vert,
                                                           this.rand);
            } else {
                zKnoten = aktRob.vAuts()[0].holeKnoten(aktName);
            }
           
            aktion = ((ZInfo) zKnoten.getInfo()).getAktion();
            param = ((ZInfo) zKnoten.getInfo()).getParam();
            alt = ((ZInfo) zKnoten.getInfo()).getAlter();
            istStart = ((ZInfo) zKnoten.getInfo()).istStartZ();
           
            kind.einfuegenKnoten(aktName, aktion, param, alt);
            if (istStart) {
                kind.setStart(kind.holeKnoten(aktName));
            }
        }
       
        it1 = zustaende.iterator();
        while (it1.hasNext()) {
            kn1 = (Integer) it1.next();
            it2 = zustaende.iterator();
            while (it2.hasNext()) {
                kn2 = (Integer) it2.next();
               
                vorhandenAll = true;
                if (aktRob.vAuts()[0].kanteExistiert(kn1, kn2)) {
                    for (int i = 0; i < rob.length; i++) {
                        if (rob[i].vAuts()[0].kanteExistiert(kn1, kn2)) {
                            condListe[i] = rob[i].vAuts()[0].getCondZuTrans(kn1,
                                                                           kn2);
                        } else {
                            vorhandenAll = false;
                            break;
                        }
                    }
                   
                    if (vorhandenAll) {
                        zCond = (Condition) MathMeth.randVerteilung(condListe,
                                                                    vert,
                                                                    this.rand);
                    } else {
                        zCond = aktRob.vAuts()[0].getCondZuTrans(kn1, kn2);
                    }
                   
                    kind.einfuegKante(kn1, kn2, zCond, 1);
                }
            }
        }

        /*
         * TODO: Alter der Knoten UND Kanten.
         */
       
        int[] fits = new int[1];
        String[] codes = new String[1];
        fits[0] = (int) fitness;
        codes[0] = kind.erzeugeStringSeq();
       
        robC[0] = new RobCode(
                id,
                fits,
                codes,
View Full Code Here

           
            aktRob = (Roboter) MathMeth.randVerteilung(rob, vert, this.rand);
            zustaende = aktRob.vAuts()[i].getKnList();
            fitness[i] = aktRob.getFitness()[i];

            kind[i] = new EndlicherAutomat();
            vorhandenAll = true;
           
            // Zust�nde einf�gen.
            it = zustaende.iterator();
            while (it.hasNext()) {
View Full Code Here

     * @param seq  Liste von Zahlen.
     *
     * @return  Die bereinigte Stringsequenz.
     */
    public static String stringAusListSeq(final LinkedList<Integer> seq) {
        EndlicherAutomat ea = new EndlicherAutomat();
       
        return ea.bereinige(ea.ausgabe(seq));
    }
View Full Code Here

    @SuppressWarnings("unchecked")
    public static EndlicherAutomat gesamtAutomat(
            final EndlicherAutomat[] endAuts,
            final Condition[]        conds) {
        HashMap[] knotZuord = new HashMap[endAuts.length];
        EndlicherAutomat neu = new EndlicherAutomat();
        int lfdNr = 1;
        ArrayList<Integer> knot;
        ArrayList<Integer> knot1;
        Iterator<Integer> it, it1;
        Iterator<Transition> it3;
        Integer aktKnNum;
        Knoten aktKn;
        ZInfo info;
        Knoten zielKn;
        Integer zielKnNum;
        Condition aktBed;
        Condition neuBed = null;
        Condition zwischBed;
        int numOrig1, numOrig2;
        int idlBefehl;
        EndlicherAutomat[] eas = new EndlicherAutomat[endAuts.length];
        LinkedList<Transition> trans;
        Transition tran;
        String[] args = {"log 4"};
       
        if (endAuts == null
                || conds == null
                || endAuts.length != conds.length
                || endAuts.length == 0) {
            SonstMeth.log(SonstMeth.LOG_ERROR,
                          "Gesamtautomat konnte nicht erzeugt werden.",
                          new Parametersatz(args));
        }
       
        for (int i = 0; i < eas.length; i++) {
            eas[i] = new EndlicherAutomat();
            eas[i].erzeugeAusSequenz(
                    endAuts[i].erzeugeStringSeq(),
                    fmg.fmg8.endlAutomat.translator.Konstanten.STD_TRANSL_BE,
                    false);
           
            if (eas[i].istLeer()) {
                eas[i].einfuegenKnoten(Integer.MAX_VALUE,
                        SonstMeth.posSuch(
                                fmg.fmg8.umgebung2D.Konstanten.BEF,
                                "stp"),
                        1,
                        1);
               
                eas[i].setStart(eas[i].holeKnoten(Integer.MAX_VALUE));
            }
        }
       
        // Neue Knoten zuordnen.
        for (int i = 0; i < eas.length; i++) {
            knotZuord[i] = new HashMap<Integer, Integer>();
           
            knot = new ArrayList<Integer>(eas[i].holAdj().keySet());
            it = knot.iterator();

            while (it.hasNext()) {
                aktKnNum = it.next();
                aktKn = eas[i].holeKnoten(aktKnNum);
                info = aktKn.getInfo();
                neu.einfuegenKnoten(lfdNr,
                                    info.getAktion(),
                                    info.getParam(),
                                    info.getAlter());
               
                knotZuord[i].put(aktKnNum, lfdNr);
                lfdNr++;
            }
        }
       
        // Neue Kanten INTER Automaten zuordnen.
        for (int i = 0; i < eas.length; i++) {
            zielKn = eas[i].holeStartzustand();
           
            if (zielKn != null) {
                zielKnNum = (Integer) knotZuord[i].get(zielKn.holeName());
                neuBed = SonstMeth.ausFormatBed(conds[i].formatted());
                for (int j = 0; j < i; j++) {
                    zwischBed = SonstMeth.ausFormatBed(conds[j].formatted());
                    zwischBed.negiere();
                    neuBed = new InnerNode(neuBed,
                                           zwischBed,
                                           fmg.fmg8.endlAutomat.Konstanten.UND);
                }
               
                for (int j = 0; j < eas.length; j++) {
                    if (j != i) {
                        knot = new ArrayList<Integer>(
                                eas[j].holAdj().keySet());
                        it = knot.iterator();
                       
                        while (it.hasNext()) {
                            aktKnNum = (Integer) knotZuord[j].get(it.next());
                            neu.einfuegKante(aktKnNum, zielKnNum, neuBed, 1);
                        }
                    }
                }
            }
        }

        // Neue Kanten INTRA Automaten zuordnen.
        for (int i = 0; i < eas.length; i++) {
            knot1 = new ArrayList<Integer>(eas[i].holAdj().keySet());
            it1 = knot1.iterator();
           
            while (it1.hasNext()) {
                numOrig1 = it1.next();
                aktKnNum = (Integer) knotZuord[i].get(numOrig1);
                aktKn = eas[i].holeKnoten(numOrig1);
               
                if (aktKn.getInfo() != null
                        && aktKn.getInfo().getBedingungen() != null) {
                    trans = aktKn.getInfo().getBedingungen();
                    it3 = trans.iterator();
                   
                    while (it3.hasNext()) {
                        tran = it3.next();
                        numOrig2 = tran.getFolgezustand();
                        zielKnNum = (Integer) knotZuord[i].get(numOrig2);
                        aktBed = tran.getCond();
                       
                        if (aktBed != null) {
                            neu.einfuegKante(aktKnNum, zielKnNum, aktBed, 1);
                        }
                    }
                }
            }
        }

        // true - Kanten zu den einzelnen Startknoten einf�gen.
        for (int i = 0; i < eas.length; i++) {
            zielKn = eas[i].holeStartzustand();
           
            if (zielKn != null) {
                zielKnNum = (Integer) knotZuord[i].get(zielKn.holeName());
               
                knot = new ArrayList<Integer>(eas[i].holAdj().keySet());
                it = knot.iterator();
               
                while (it.hasNext()) {
                    aktKnNum = (Integer) knotZuord[i].get(it.next());
                    neu.einfuegKante(aktKnNum,
                                     zielKnNum,
                                     SonstMeth.ausBed("t"),
                                     1);
                }
            }
        }

        // Einen IDLE-Startknoten einf�gen.
        idlBefehl = SonstMeth.posSuch(fmg.fmg8.umgebung2D.Konstanten.BEF,
                                      "IDL");
        neu.einfuegenKnoten(lfdNr, idlBefehl, 1, 1);
        neu.setStart(neu.holeKnoten(lfdNr));
        for (int i = 0; i < conds.length; i++) {
            if (i > 0) {
                neuBed = conds[i];
            } else {
                neuBed = SonstMeth.ausFormatBed(conds[i].formatted());
                for (int j = 1; j < conds.length; j++) {
                    zwischBed = SonstMeth.ausFormatBed(conds[j].formatted());
                    zwischBed.negiere();
                    neuBed = new InnerNode(
                            neuBed,
                            zwischBed,
                            fmg.fmg8.endlAutomat.Konstanten.ODER);
                }
            }

            if (conds.length == 1) {
                neuBed = SonstMeth.ausBed("t");
            }

            if (eas[i].holeStartzustand() != null) {
                neu.einfuegKante(lfdNr,
                       (Integer)
                       knotZuord[i].get(eas[i].holeStartzustand().holeName()),
                       neuBed,
                       1);
            }
View Full Code Here

     *                 Population von neuen Robotern im Robotercode-Format.
     */
    public void uebernimmPop(final ArrayList<RobCode> semiPop) {
        Iterator<Roboter> itAkt;
        Roboter rob;
        RobCode robC;
        Iterator<RobCode> itSemi;
        Translator[] stdTrans
            = new Translator[semiPop.get(0).getVCodes().length];
       
        for (int i = 0; i < stdTrans.length; i++) {
            stdTrans[i]
                = fmg.fmg8.endlAutomat.translator.Konstanten.STD_TRANSL_TR;
        }
       
        itAkt = this.akteure.iterator();
        itSemi = semiPop.iterator();
        while (itAkt.hasNext() && itSemi.hasNext()) {
            rob = itAkt.next();
            robC = itSemi.next();
           
            rob.erzTransAusSeqs(robC.getTStdCodes(), stdTrans, false);
            rob.erzeugeAusSequenzen(
                    robC.getVCodes(),
                    rob.getConds(),
                    rob.getTranslatoren(),
                    false);
           
            rob.setTransCodes(SonstMeth.listSeqAusStrings(robC.getTCodes()));
            rob.setVerhCodes(SonstMeth.listSeqAusStrings(robC.getVCodes()));
            rob.setFitness(robC.getFitness());
           
//          rob.setConds(rob2.getConds()); TODO
        }
    }
View Full Code Here

            int koordX = this.links;
            int koordY = this.oben;
           
            int kX;
            int kY;
            Transition bed;
            int folgeZustand;
            String bedingung;
            int xAusgleich;
            int zaehler = 0;
           
            // Knoten
            it = knotenListe.iterator();
            while (it.hasNext()) {
                knot = it.next();

                if (this.gesetzteKn.containsKey(knot.holeName())) {
                    kX = (int) this.gesetzteKn.get(knot.holeName()).x;
                    kY = (int) this.gesetzteKn.get(knot.holeName()).y;
                    this.setzeKnoten(knot,
                                     darstellung,
                                     kX,
                                     kY,
                                     (Knoten) ausgKn);

                    if (g.istStartZ(knot)) {
                        darstellung.hinzuPfeil(kX - 60,
                                               kY - 60,
                                               kX - 45,
                                               kY - 45,
                                               0.5,
                                               false);
                    }
                } else {
                    this.setzeKnoten(knot,
                                     darstellung,
                                     koordX,
                                     koordY,
                                     (Knoten) ausgKn);

                    this.gesetzteKn.put(knot.holeName(),
                                        new Vektor2D(koordX, koordY));

                    if (g.istStartZ(knot)) {
                        darstellung.hinzuPfeil(koordX - 60,
                                               koordY - 60,
                                               koordX - 45,
                                               koordY - 45,
                                               0.5,
                                               false);
                    }

                    zaehler++;
                   
                    if (zaehler < Math.ceil(Math.sqrt(knAnzahl))) {
                        koordX = koordX + gitterX;
                    } else {
                        koordX = this.links;
                        koordY = koordY + gitterY;
                        zaehler = 0;
                    }
                }
            }

            // Kanten
            it1 = knotenListe.iterator();
            while (it1.hasNext()) {
                knot1 = (Knoten) it1.next();
                koord1 = (Vektor2D) this.gesetzteKn.get(knot1.holeName());

                it2 = (new ArrayList<Integer>(
                                knot1.holeNachfolger().keySet())).iterator();
                while (it2.hasNext()) {
                    boolean gebogen = true;
                   
                    knot2 = g.holeKnoten((Integer) it2.next());
                    koord2 = (Vektor2D) this.gesetzteKn.get(knot2.holeName());
                    Condition cond
                        = knot1.getInfo().getTransZuZustand(
                                knot2.holeName()).get(0).getCond();
                    double staerke = SonstMeth.condStrength(cond,
                                                   Konstanten.STAERKE_ERST,
                                                   Konstanten.STAERKE_ZWEIT);
                   
                    if (koord1.distanz(koord2) < 140
                            && !koord1.equals(koord2)) {
                        gebogen = false;
                    }
                   
                    darstellung.hinzuPfeil(
                            (int) koord1.x,
                            (int) koord1.y,
                            (int) koord2.x,
                            (int) koord2.y,
                            staerke,
                            gebogen);
                }
            }

            // Kantenbeschriftungen
            it1 = knotenListe.iterator();
            while (it1.hasNext()) {
                int kantNum = 1;
                knot1 = (Knoten) it1.next();
                koord1 = this.gesetzteKn.get(knot1.holeName());

                it3 = ((ZInfo) knot1.getInfo()).getBeds().iterator();
                while (it3.hasNext()) {
                    Polygon p = new Polygon();
                    bed = it3.next();
                    folgeZustand = bed.getFolgezustand();
                    bedingung = bed.getCond().toString();
                    knot2 = g.holeKnoten(new Integer(folgeZustand));
                    koord2 = this.gesetzteKn.get(knot2.holeName());

                    p.addPoint((int) koord1.x, (int) koord1.y);
                    p.addPoint((int) koord2.x, (int) koord2.y);
View Full Code Here

     */
    public void naechsterZustand() {
        int aktion;
        int parameter;
        LinkedList<Transition> bedingungen;
        Transition aktBed;
        ZInfo zusatz;
        int folgeZ = 0;
        Iterator<Transition> it;
        int i = 0;
       
        while (i < this.conds.length) {
            if (this.conds[i].evaluiere(this)) {
                if (this.initial || i != this.aktAut) {
                    this.aktAut = i;
                    this.vAut[this.aktAut].setzeChanged();
                    this.vAut[this.aktAut].notifyObservers(
                            new Integer(this.aktAut));
                    this.initial = false;
                }
                break;
            }
            i++;
        }
       
        this.expAktZyklen++;
        this.fitAktZyklen[this.aktAut]++;
        this.fitRedAktZyklen[this.aktAut]++;
        this.aktivZyklen[this.aktAut]++;
        this.mutAktZyklen++;
        this.aktMemZyk++;
        this.condMutAktZyklen++;
       
        if (this.fitRedAktZyklen[this.aktAut] > this.fitRedZyklen) {
            this.setFitness(this.aktAut,
                            (int) ((double) this.getFitness()[this.aktAut]
                                    / this.fitRedWert));
            this.fitRedAktZyklen[this.aktAut] = 0;
        }
       
        if (this.fitAktZyklen[this.aktAut] > this.fitZyklen) {
            this.befehle.clear();
            this.befehle.add(new Integer(this.lastBf));

            this.setFitness(this.aktAut,
                            this.getFitness()[this.aktAut]
                            + this.fitVs[this.aktAut].fitness(
                                    (Roboter) this));

            this.fitAktZyklen[this.aktAut] = 0;
        }

        if (this.pars.getEvol().booleanValue()) {
            if (this.aktMemZyk > this.pars.getMemInt().longValue()) {
                this.resetToBest();
            }
           
            if (this.mutAktZyklen > this.mutZyklen) {
                this.mutV = true;
                this.mutiere();
                this.mutAktZyklen = 0;
                this.mutV = false;
            } else {
                this.mutV = false;
            }
           
            if (this.condMutAktZyklen > this.pars.getCondMutZyk()) {
                this.mutiereBeds();
                this.condMutAktZyklen = 0;
            }
        }
       
        if (this.aktZustand[this.aktAut] == null) {
            this.aktZustand[this.aktAut]
                            = this.vAut[this.aktAut].holeStartzustand();
        }

        if (this.isSelektiert()) {
            if (this.aktZustand[this.aktAut] != null) {
                this.vAut[this.aktAut].setzeChanged();
                this.vAut[this.aktAut].notifyObservers(
                        this.aktZustand[this.aktAut]);
            }
        }

        if (this.aktZustand[this.aktAut] != null) {
            zusatz = (ZInfo) this.aktZustand[this.aktAut].getInfo();
            aktion = zusatz.getAktion();
            parameter = zusatz.getParam();

            this.gesamtAktion(aktion, parameter);
           
            this.lastBf = aktion;
           
            bedingungen = zusatz.getBeds();
            it = bedingungen.iterator();
            this.aktZustand[this.aktAut] = null;
            while (it.hasNext() && folgeZ == 0) {
                aktBed = (Transition) it.next();
                if (aktBed.evaluiere(this)) {
                    folgeZ = aktBed.getFolgezustand();
                    this.aktZustand[this.aktAut]
                        = this.vAut[this.aktAut].holeKnoten(
                                new Integer(folgeZ));
                }
            }
View Full Code Here

    public void naechsterZustand() {
        int aktion;
        int parameter;
        LinkedList<Transition> bedingungen;
        Transition aktBed;
        ZInfo zusatz;
        int folgeZ = 0;
        Iterator<Transition> it;
        int i = 0;
       
        while (i < this.conds.length) {
            if (this.conds[i].evaluiere(this)) {
                if (this.initial || i != this.aktAut) {
                    this.aktAut = i;
                    this.vAut[this.aktAut].setzeChanged();
                    this.vAut[this.aktAut].notifyObservers(
                            new Integer(this.aktAut));
                    this.initial = false;
                }
                break;
            }
            i++;
        }
       
        this.expAktZyklen++;
        this.fitAktZyklen[this.aktAut]++;
        this.fitRedAktZyklen[this.aktAut]++;
        this.aktivZyklen[this.aktAut]++;
        this.mutAktZyklen++;
        this.aktMemZyk++;
        this.condMutAktZyklen++;
       
        if (this.fitRedAktZyklen[this.aktAut] > this.fitRedZyklen) {
            this.setFitness(this.aktAut,
                            (int) ((double) this.getFitness()[this.aktAut]
                                    / this.fitRedWert));
            this.fitRedAktZyklen[this.aktAut] = 0;
        }
       
        if (this.fitAktZyklen[this.aktAut] > this.fitZyklen) {
            this.befehle.clear();
            this.befehle.add(new Integer(this.lastBf));

            this.setFitness(this.aktAut,
                            this.getFitness()[this.aktAut]
                            + this.fitVs[this.aktAut].fitness(
                                    (Roboter) this));

            this.fitAktZyklen[this.aktAut] = 0;
        }

        if (this.pars.getEvol().booleanValue()) {
            if (this.aktMemZyk > this.pars.getMemInt().longValue()) {
                this.resetToBest();
            }
           
            if (this.mutAktZyklen > this.mutZyklen) {
                this.mutV = true;
                this.mutiere();
                this.mutAktZyklen = 0;
                this.mutV = false;
            } else {
                this.mutV = false;
            }
           
            if (this.condMutAktZyklen > this.pars.getCondMutZyk()) {
                this.mutiereBeds();
                this.condMutAktZyklen = 0;
            }
        }
       
        if (this.aktZustand[this.aktAut] == null) {
            this.aktZustand[this.aktAut]
                            = this.vAut[this.aktAut].holeStartzustand();
        }

        if (this.isSelektiert()) {
            if (this.aktZustand[this.aktAut] != null) {
                this.vAut[this.aktAut].setzeChanged();
                this.vAut[this.aktAut].notifyObservers(
                        this.aktZustand[this.aktAut]);
            }
        }

        if (this.aktZustand[this.aktAut] != null) {
            zusatz = (ZInfo) this.aktZustand[this.aktAut].getInfo();
            aktion = zusatz.getAktion();
            parameter = zusatz.getParam();

            this.gesamtAktion(aktion, parameter);
           
            this.lastBf = aktion;
           
            bedingungen = zusatz.getBeds();
            it = bedingungen.iterator();
            this.aktZustand[this.aktAut] = null;
            while (it.hasNext() && folgeZ == 0) {
                aktBed = (Transition) it.next();
                if (aktBed.evaluiere(this)) {
View Full Code Here

TOP

Related Classes of fmg.fmg8.endlAutomat.EndlicherAutomat

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.