Examples of WeightedSum


Examples of eu.planets_project.pp.plato.model.aggregators.WeightedSum

   
    public void testYetUnstableWeights() {
        leaf11.setWeight(0.59);
        leaf12.setWeight(0.41);
       
        ResultNode resultRoot = new ResultNode(root, new WeightedSum(), alternatives);
        resultRoot.analyseSensitivity(weightModifier,
                SensitivityAnalysisTestFactory.getSensitivityTest(root, new WeightedSum(), alternatives));
       
        //assert(resultRoot.isSensitive());
        assert(getResult(resultRoot, child1).isSensitive());
    }   
View Full Code Here

Examples of eu.planets_project.pp.plato.model.aggregators.WeightedSum

   
    public void testStableWeights() {
        leaf11.setWeight(0.81);
        leaf12.setWeight(0.29);
       
        ResultNode resultRoot = new ResultNode(root, new WeightedSum(), alternatives);
        resultRoot.analyseSensitivity(weightModifier,
                SensitivityAnalysisTestFactory.getSensitivityTest(root, new WeightedSum(), alternatives));
       
        assert(!getResult(resultRoot, child1).isSensitive());
    }
View Full Code Here

Examples of eu.planets_project.pp.plato.model.aggregators.WeightedSum

   
    public void testYetStableWeights() {
        leaf11.setWeight(0.69);
        leaf12.setWeight(0.31);
       
        ResultNode resultRoot = new ResultNode(root, new WeightedSum(), alternatives);
        resultRoot.analyseSensitivity(weightModifier,
                SensitivityAnalysisTestFactory.getSensitivityTest(root, new WeightedSum(), alternatives));
       
        assert(!getResult(resultRoot, child1).isSensitive());
    }
View Full Code Here

Examples of eu.planets_project.pp.plato.model.aggregators.WeightedSum

        // the alternative a2 becomes the new winner
        // in other words the current weighting is unstable
        sf1.setWeight(0.49);
        sf2.setWeight(0.51);
       
        ResultNode resultRoot = new ResultNode(root, new WeightedSum(), alternatives);
        resultRoot.analyseSensitivity(weightModifier,
                SensitivityAnalysisTestFactory.getSensitivityTest(root, new WeightedSum(), alternatives));
        assert(resultRoot.isSensitive());
    }
View Full Code Here

Examples of eu.planets_project.pp.plato.model.aggregators.WeightedSum

        // (0.47->0.51 and 0.53->0.49)
        // a change by 0.04 is not much which means this weighting is unstable
        sf1.setWeight(0.47);
        sf2.setWeight(0.53);
       
        ResultNode resultRoot = new ResultNode(root, new WeightedSum(), alternatives);
        resultRoot.analyseSensitivity(weightModifier,
                SensitivityAnalysisTestFactory.getSensitivityTest(root, new WeightedSum(), alternatives));
       
        assert(resultRoot.isSensitive());
    }
View Full Code Here

Examples of eu.planets_project.pp.plato.model.aggregators.WeightedSum

        // (0.47->0.51 and 0.53->0.49)
        // a change by 0.04 is not much which means this weighting is unstable
        sf1.setWeight(0.46);
        sf2.setWeight(0.54);
       
        ResultNode resultRoot = new ResultNode(root, new WeightedSum(), alternatives);
        resultRoot.analyseSensitivity(weightModifier,
                SensitivityAnalysisTestFactory.getSensitivityTest(root, new WeightedSum(), alternatives));
       
        assert(resultRoot.isSensitive());
    }
View Full Code Here

Examples of eu.planets_project.pp.plato.model.aggregators.WeightedSum

        // (0.47->0.51 and 0.53->0.49)
        // a change by 0.04 is not much which means this weighting is unstable
        sf1.setWeight(0.45);
        sf2.setWeight(0.55);
       
        ResultNode resultRoot = new ResultNode(root, new WeightedSum(), alternatives);
        resultRoot.analyseSensitivity(weightModifier,
                SensitivityAnalysisTestFactory.getSensitivityTest(root, new WeightedSum(), alternatives));
        assert(resultRoot.isSensitive());
    }
View Full Code Here

Examples of eu.planets_project.pp.plato.model.aggregators.WeightedSum

        // you have to move the weights a lot to change the outcome of the alternatives
        // (0.19->0.51 and 0.81->0.49), this means the weighting is stable
        sf1.setWeight(0.19);
        sf2.setWeight(0.81);
       
        ResultNode resultRoot = new ResultNode(root, new WeightedSum(), alternatives);
        resultRoot.analyseSensitivity(weightModifier,
                SensitivityAnalysisTestFactory.getSensitivityTest(root, new WeightedSum(), alternatives));
       
        assert(!resultRoot.isSensitive());
    }
View Full Code Here

Examples of eu.planets_project.pp.plato.model.aggregators.WeightedSum

        // (0.4->0.51 and 0.6->0.49)
        // a change by 0.11 is considered a lot, therefor this weighting is stable
        sf1.setWeight(0.4);
        sf2.setWeight(0.6);
       
        ResultNode resultRoot = new ResultNode(root, new WeightedSum(), alternatives);
        resultRoot.analyseSensitivity(weightModifier,
                SensitivityAnalysisTestFactory.getSensitivityTest(root, new WeightedSum(), alternatives));
       
        assert(!resultRoot.isSensitive());
    }
View Full Code Here

Examples of eu.planets_project.pp.plato.model.aggregators.WeightedSum

        // (0.4->0.51 and 0.6->0.49)
        // a change by 0.11 is considered a lot, therefor this weighting is stable
        sf1.setWeight(0.44);
        sf2.setWeight(0.56);
       
        ResultNode resultRoot = new ResultNode(root, new WeightedSum(), alternatives);
        resultRoot.analyseSensitivity(weightModifier,
                SensitivityAnalysisTestFactory.getSensitivityTest(root, new WeightedSum(), alternatives));
       
        assert(!resultRoot.isSensitive());
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.