{"id":364,"date":"2025-09-04T11:19:52","date_gmt":"2025-09-04T11:19:52","guid":{"rendered":"https:\/\/www.jecdm.cs.put.poznan.pl\/?page_id=364"},"modified":"2025-09-04T16:35:55","modified_gmt":"2025-09-04T16:35:55","slug":"configuring-the-decision-support-system-and-simulating-its-use","status":"publish","type":"page","link":"https:\/\/www.jecdm.cs.put.poznan.pl\/?page_id=364","title":{"rendered":"Configuring the Decision Support System and simulating its use"},"content":{"rendered":"\n<p style=\"font-size:14px\">This quick-start tutorial demonstrates how to configure the Decision Support System and simulate its use. The example involves artificial and easily comprehensible data. The modelled decision-making process makes the following assumptions:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li style=\"font-size:14px\">A simple 2D decision problem is considered.<\/li>\n\n\n\n<li style=\"font-size:14px\">The process is modelled as interactive.<\/li>\n\n\n\n<li style=\"font-size:14px\">The process involves a robust preference learning strategy, named ERS (<a href=\"http:\/\/ssrn.com\/abstract=5415565\">http:\/\/ssrn.com\/abstract=5415565<\/a>).<\/li>\n\n\n\n<li style=\"font-size:14px\">The decision maker&#8217;s preferences are assumed to be consistent with an L-norm.<\/li>\n\n\n\n<li style=\"font-size:14px\">The interactive procedure randomly selects two pairs of solutions to be presented to the decision-maker for evaluation.<\/li>\n\n\n\n<li style=\"font-size:14px\">The decision maker&#8217;s responses are simulated using an artificial decision maker, consistent with the L-norm.<\/li>\n<\/ul>\n\n\n\n<p style=\"font-size:14px\">The results of the processing are visualized and reported in the console. Note that, although it is a quick-start tutorial, having at least a moderate understanding of the concepts described in &#8220;Tutorial Series on Java Framework for Evolutionary Computation and Decision Making. Tutorial 4: Decision Support module&#8221; is recommended. The complete source code for this tutorial can be found in the Projects module: y2025.SoftwareX_JECDM.QuickStart1 (framework&#8217;s version at least<strong> <\/strong>1.7.0). In what follows, the relevant commented code blocks are presented, and the expected results are visualized for convenience. Note that a list of essential imports can be found at the end of this tutorial.<\/p>\n\n\n\n<p style=\"font-size:18px\"><strong>The overview of the source code:<\/strong><\/p>\n\n\n\n<p style=\"font-size:14px\">The code starts by defining three elements: <br>1) random number generator,<br>2) considered criteria<br>3) normalization functions mapping the considered objective space into a normalized hypercube:<\/p>\n\n\n<pre class=\"wp-block-code has-white-color has-text-color has-background has-link-color wp-elements-85758463d49aa98f006f17fb2855dadd\" style=\"background-color:#2b2b2b;font-size:14px\" aria-describedby=\"shcb-language-1\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/ Let us start with defining a random number generator:<\/span>\nIRandom R = <span class=\"hljs-keyword\">new<\/span> L32_X64_MIX(<span class=\"hljs-number\">0<\/span>);\n\n<span class=\"hljs-comment\">\/\/ Then, we can proceed to define two criteria, named C1 and C2. The first is of the cost-type, while the latter is of the gain-type.<\/span>\nCriteria C = Criteria.constructCriteria(\n        <span class=\"hljs-keyword\">new<\/span> <span class=\"hljs-built_in\">String<\/span>&#91;]{<span class=\"hljs-string\">\"C1\"<\/span>, <span class=\"hljs-string\">\"C2\"<\/span>}, <span class=\"hljs-comment\">\/\/ criteria names<\/span>\n        <span class=\"hljs-keyword\">new<\/span> boolean&#91;]{<span class=\"hljs-literal\">false<\/span>, <span class=\"hljs-literal\">true<\/span>} <span class=\"hljs-comment\">\/\/ criteria types (false = cost; true = gain)<\/span>\n);\n\n<span class=\"hljs-comment\">\/\/ We will also assume that the alternatives are spanned on the &#91;0, 10] interval for the first criterion, and on the &#91;1, 2] interval for the latter. Important: the scaling-sensitive components assume that the calculations are performed in the &#91;0, 1] hypercube, with the 0-vector being the utopia and 1-vector the nadir, by default. Thus, we need to define suitable normalization functions that will be passed to these components to allow them to perform adequate rescaling:<\/span>\n\nINormalization&#91;] normalizations = <span class=\"hljs-keyword\">new<\/span> INormalization&#91;]{\n        <span class=\"hljs-keyword\">new<\/span> Linear(<span class=\"hljs-number\">0.0<\/span>d, <span class=\"hljs-number\">10.0<\/span>d), <span class=\"hljs-comment\">\/\/ Linear = performs standard min-max rescaling (min = 0, max = 10)<\/span>\n        <span class=\"hljs-keyword\">new<\/span> LinearWithFlip(<span class=\"hljs-number\">1.0<\/span>d, <span class=\"hljs-number\">2.0<\/span>d, <span class=\"hljs-number\">1.0<\/span>d) <span class=\"hljs-comment\">\/\/ LinearWithFlip = as Linear, but flips the<\/span>\n        <span class=\"hljs-comment\">\/\/ normalization product around the passed threshold, i.e., final normalization = 1 - normalization. Flipping is required as the second criterion is of the gain-type.<\/span>\n};<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-1\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p style=\"font-size:14px\">Then, a set of artificial alternatives is generated:<\/p>\n\n\n<pre class=\"wp-block-code has-white-color has-text-color has-background has-link-color wp-elements-19f7cc5341c994bc1e75a27abf79033b\" style=\"background-color:#2b2b2b;font-size:14px\" aria-describedby=\"shcb-language-2\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/ Now, assume an artificial set of alternatives whose performance vectors are defined on a 2-dimensional concave sphere that is suitably rescaled to account for the expected performance bounds and criteria types. We will first construct the relevant performance matrix (alternatives x performances) using the standard parametric equation of a sphere:<\/span>\n\nint noAlternatives = <span class=\"hljs-number\">50<\/span>; <span class=\"hljs-comment\">\/\/ the number of alternatives in the artificial data set<\/span>\ndouble&#91;]&#91;] pm = <span class=\"hljs-keyword\">new<\/span> double&#91;noAlternatives]&#91;<span class=\"hljs-number\">2<\/span>];\n<span class=\"hljs-keyword\">for<\/span> (int i = <span class=\"hljs-number\">0<\/span>; i &lt; noAlternatives; i++)\n{\n        double angle = <span class=\"hljs-built_in\">Math<\/span>.PI \/ <span class=\"hljs-number\">2.0<\/span>d * (double) i \/ (noAlternatives - <span class=\"hljs-number\">1<\/span>);\n        pm&#91;i]&#91;<span class=\"hljs-number\">0<\/span>] = <span class=\"hljs-built_in\">Math<\/span>.sin(angle) * <span class=\"hljs-number\">10.0<\/span>d; <span class=\"hljs-comment\">\/\/ performance according to the first criterion (cost, &#91;0, 10] bound)<\/span>\n        pm&#91;i]&#91;<span class=\"hljs-number\">1<\/span>] = <span class=\"hljs-number\">2.0<\/span>d - <span class=\"hljs-built_in\">Math<\/span>.cos(angle); <span class=\"hljs-comment\">\/\/ performance according to the second criterion (gain, &#91;1, 2] bound)<\/span>\n}\n\n<span class=\"hljs-comment\">\/\/ We can now define an alternative set using the performance matrix. The resulting alternatives will be named \"A1\", \"A2\", and so on.<\/span>\nAlternatives alternatives = Alternatives.getAlternativeArray(<span class=\"hljs-string\">\"A\"<\/span>, pm, <span class=\"hljs-number\">1<\/span>);\n\n<span class=\"hljs-comment\">\/\/ Let us print the data on alternatives:<\/span>\nassert alternatives != <span class=\"hljs-literal\">null<\/span>;\n<span class=\"hljs-keyword\">for<\/span> (Alternative A : alternatives)\n        System.out.println(A.getName() + <span class=\"hljs-string\">\" : \"<\/span>\n                 + PrintUtils.getVectorOfDoubles(A.getPerformanceVector(), <span class=\"hljs-number\">2<\/span>).replace(<span class=\"hljs-string\">','<\/span>, <span class=\"hljs-string\">'.'<\/span>));<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-2\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p style=\"font-size:14px\">The following code starts configuring the decision support system. This process begins by defining a refiner object, used to pre-process the input alternatives:<\/p>\n\n\n<pre class=\"wp-block-code has-white-color has-text-color has-background has-link-color wp-elements-843d1f316fd6ad66ad962f157ae33517\" style=\"background-color:#2b2b2b;font-size:14px\" aria-describedby=\"shcb-language-3\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/ We will start by constructing a decision-support system. It requires a considerable amount of<\/span>\n<span class=\"hljs-comment\">\/\/ parameterization, which can be done via the inner Params class:<\/span>\n\nDecisionSupportSystem.Params pDSS = <span class=\"hljs-keyword\">new<\/span> DecisionSupportSystem.Params();\n\npDSS._criteria = C; <span class=\"hljs-comment\">\/\/ defined the criteria<\/span>\n{\n        <span class=\"hljs-comment\">\/\/ Refiner is an object that pre-processes input alternatives used when running the system. It involves<\/span>\n        <span class=\"hljs-comment\">\/\/ checking the premature termination criteria (optional). If none of them is triggered, the system<\/span>\n        <span class=\"hljs-comment\">\/\/ proceeds to perform an optional reduction step using reduction filters. They intend to filter out<\/span>\n        <span class=\"hljs-comment\">\/\/ unwanted input alternatives.<\/span>\n        Refiner.Params pR = <span class=\"hljs-keyword\">new<\/span> Refiner.Params(); <span class=\"hljs-comment\">\/\/ to be parameterized via the Params class<\/span>\n        pR._terminationFilters = <span class=\"hljs-keyword\">new<\/span> LinkedList&lt;&gt;(); <span class=\"hljs-comment\">\/\/ define the termination filters<\/span>\n        pR._terminationFilters.add(<span class=\"hljs-keyword\">new<\/span> RequiredSpread(<span class=\"hljs-number\">1.0E-3<\/span>));  <span class=\"hljs-comment\">\/\/ RequiredSpread: checks if the input<\/span>\n        <span class=\"hljs-comment\">\/\/ alternatives are contained within a hypercube of the input size. The measurement is done in<\/span>\n        <span class=\"hljs-comment\">\/\/ the normalized space. If so, it is assumed that the alternatives are too narrowly spread to make<\/span>\n        <span class=\"hljs-comment\">\/\/ meaningful processing. Thus, the processing would be terminated.<\/span>\n        pR._reductionFilters = <span class=\"hljs-keyword\">new<\/span> LinkedList&lt;&gt;(); <span class=\"hljs-comment\">\/\/ define the reduction filters<\/span>\n        pR._reductionFilters.add(<span class=\"hljs-keyword\">new<\/span> RemoveDominated()); <span class=\"hljs-comment\">\/\/ RemoveDominated: removes dominated alternatives as they<\/span>\n        <span class=\"hljs-comment\">\/\/ are rarely useful (important note, these filters sequentially create new alternative sets (in fact,<\/span>\n        <span class=\"hljs-comment\">\/\/ arrays) and pass them further, the input set is not manipulated)<\/span>\n        pDSS._refiner = <span class=\"hljs-keyword\">new<\/span> Refiner(pR); <span class=\"hljs-comment\">\/\/ instantiate the refiner<\/span>\n}<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-3\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p style=\"font-size:14px\">Next, an interaction trigger that specifies an interaction pattern is defined:<\/p>\n\n\n<pre class=\"wp-block-code has-white-color has-text-color has-background has-link-color wp-elements-4e29cf9c4f620406939b5931a6538889\" style=\"background-color:#2b2b2b;font-size:14px\" aria-describedby=\"shcb-language-4\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/  Let us now define an interaction trigger. It can accept a series of rules for checking if the preference elicitation should be performed when executing the processing. In this tutorial example, we assume that the rule is based on verifying the interaction counter. We will assume that interactions are allowed every 5 iterations, starting from the 10th iteration. A limit of 2 interactions is also imposed.<\/span>\n\npDSS._interactionTrigger = <span class=\"hljs-keyword\">new<\/span> InteractionTrigger(\n        <span class=\"hljs-keyword\">new<\/span> IterationInterval( <span class=\"hljs-comment\">\/\/ rule based on examining the iteration counter<\/span>\n                <span class=\"hljs-number\">10<\/span>, <span class=\"hljs-comment\">\/\/ allow for interactions starting from the 10th iteration<\/span>\n                <span class=\"hljs-number\">5<\/span>, <span class=\"hljs-comment\">\/\/ allow for iterations every 5 iterations<\/span>\n                <span class=\"hljs-number\">2<\/span> <span class=\"hljs-comment\">\/\/ impose the limit of 2 iterations<\/span>\n        )\n);<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-4\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p style=\"font-size:14px\">Then, a procedure for creating a reference subset of alternatives to be evaluated by the decision-maker is defined: <\/p>\n\n\n<pre class=\"wp-block-code has-white-color has-text-color has-background has-link-color wp-elements-cf7b2ef54a8b50429cbe1f06fc0fe758\" style=\"background-color:#2b2b2b;font-size:14px\" aria-describedby=\"shcb-language-5\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/ Now, we need to establish a reference set constructor. \"Reference Sets\" is a subset of the input alternatives that serves as a foundation for preference elicitation. In this example, we assume that the elicitation is based on pairwise comparisons. For simplicity, we also assume that these pairs are selected randomly. The object allows for mapping different constructors to different Decision Makers. We assume cooperation with just one Decision Maker, named DM1.<\/span>\n{\n    ReferenceSetsConstructor.Params pRSC = <span class=\"hljs-keyword\">new<\/span> ReferenceSetsConstructor.Params(); <span class=\"hljs-comment\">\/\/ parameterize via the Params class<\/span>\n    LinkedList&lt;IReferenceSetConstructor&gt; rsc = <span class=\"hljs-keyword\">new<\/span> LinkedList&lt;&gt;(); <span class=\"hljs-comment\">\/\/ instantiate a list of constructors<\/span>\n    <span class=\"hljs-comment\">\/\/ RandomPairs: select a pair randomly (drawn from a uniform distribution). The input validator<\/span>\n    <span class=\"hljs-comment\">\/\/ RequiredSpread sets neglecting pairs contained within a hypercube of size 10-3 (in the normalized space).<\/span>\n    rsc.add(<span class=\"hljs-keyword\">new<\/span> RandomPairs(<span class=\"hljs-keyword\">new<\/span> interaction.reference.validator.RequiredSpread(<span class=\"hljs-number\">1.0E-3<\/span>)));\n    pRSC._dmConstructors = <span class=\"hljs-keyword\">new<\/span> HashMap&lt;&gt;();\n    <span class=\"hljs-comment\">\/\/ Map the constructors onto the Decision Maker labelled as DM1:<\/span>\n    pRSC._dmConstructors.put(<span class=\"hljs-string\">\"DM1\"<\/span>, rsc);\n    <span class=\"hljs-comment\">\/\/ Instantiate the reference sets constructor:<\/span>\n    pDSS._referenceSetsConstructor = <span class=\"hljs-keyword\">new<\/span> ReferenceSetsConstructor(pRSC);\n}<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-5\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p style=\"font-size:14px\">This tutorial assumes a cooperation with an artificial decision-maker, whose value system is modeled with an L-norm:<\/p>\n\n\n<pre class=\"wp-block-code has-white-color has-text-color has-background has-link-color wp-elements-8d0721deeb528920e81a6d739529581d\" style=\"background-color:#2b2b2b;font-size:14px\" aria-describedby=\"shcb-language-6\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/ We will now define a feedback provider. This object is responsible for creating feedback based on the input reference sets. We will use an artificial Decision Maker modelled with an L-norm. Specifically, when presenting a pair to be compared, the suitably configured feedback provider will use the model to verify which alternative is better by comparing the attained scores. An alternative that achieves a better score will be considered preferred:<\/span>\n{\n    <span class=\"hljs-comment\">\/\/ Define the artificial Decision Maker's model as the L-norm:<\/span>\n    IPreferenceModel&lt;LNorm&gt; dmModel = <span class=\"hljs-keyword\">new<\/span> model.definitions.LNorm(\n            <span class=\"hljs-keyword\">new<\/span> LNorm(<span class=\"hljs-keyword\">new<\/span> double&#91;]{<span class=\"hljs-number\">0.6<\/span>d, <span class=\"hljs-number\">0.4<\/span>d}, <span class=\"hljs-comment\">\/\/ the weights<\/span>\n                    Double.POSITIVE_INFINITY, <span class=\"hljs-comment\">\/\/ the compensation level: makes the function effectively<\/span>\n                    <span class=\"hljs-comment\">\/\/ a Weighted Chebyshev function<\/span>\n                    INormalization.getCloned(normalizations) <span class=\"hljs-comment\">\/\/ normalizations used to rescale alternatives<\/span>\n                    <span class=\"hljs-comment\">\/\/ when making a comparison<\/span>\n            ));\n\n    <span class=\"hljs-comment\">\/\/ Create a single-DM feedback provider using the instantiated model. Note that the decision maker's label must match those defined when creating the reference sets constructor<\/span>\n    pDSS._feedbackProvider = FeedbackProvider.getForSingleDM(\n            <span class=\"hljs-string\">\"DM1\"<\/span>, <span class=\"hljs-keyword\">new<\/span> ArtificialValueDM&lt;&gt;(dmModel));\n}<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-6\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p style=\"font-size:14px\">Then, the code defines three core components related to learning preferences in the configured system: <br>1) the definition of the assumed preference model,<br>2) the preference learning algorithm,<br>3) and the inconsistency handler:<\/p>\n\n\n<pre class=\"wp-block-code has-white-color has-text-color has-background has-link-color wp-elements-6a090dbe358e9692983fe4f52153d903\" style=\"background-color:#2b2b2b;font-size:14px\" aria-describedby=\"shcb-language-7\" data-shcb-language-name=\"Java\" data-shcb-language-slug=\"java\"><span><code class=\"hljs language-java shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/ Finally, we will define the data used to instantiate the decision maker's model system. This system is<\/span>\n<span class=\"hljs-comment\">\/\/ primarily responsible for handling the preference learning part. It comprises three elements: preference<\/span>\n<span class=\"hljs-comment\">\/\/ model definition, preference learning procedure, and inconsistency handler.<\/span>\n{\n    <span class=\"hljs-comment\">\/\/ We need to start by constructing a single model bundle that will be associated with the decision maker's bundle:<\/span>\n    ModelBundle&lt;LNorm&gt; modelBundle = <span class=\"hljs-keyword\">new<\/span> ModelBundle&lt;&gt;();\n    <span class=\"hljs-comment\">\/\/ Assume that the model to be learned is defined as an L-Norm:<\/span>\n    modelBundle._preferenceModel = <span class=\"hljs-keyword\">new<\/span> model.definitions.LNorm(\n            <span class=\"hljs-keyword\">null<\/span>, <span class=\"hljs-comment\">\/\/ null = no internal models, i.e., concrete instances, are supplied a priori):<\/span>\n            <span class=\"hljs-comment\">\/\/ a dedicated evaluator may be bound with the preference model; for this reason, one may implement a suitable interface:<\/span>\n            <span class=\"hljs-keyword\">new<\/span> IEvaluator&lt;&gt;()\n            {\n                &#91;...]\n\n                <span class=\"hljs-meta\">@Override<\/span>\n                <span class=\"hljs-function\"><span class=\"hljs-keyword\">public<\/span> EvaluationResult <span class=\"hljs-title\">evaluateAlternatives<\/span><span class=\"hljs-params\">(AbstractAlternatives&lt;?&gt; alternatives, ArrayList&lt;LNorm&gt; models)<\/span> <span class=\"hljs-keyword\">throws<\/span> PreferenceModelException\n                <\/span>{\n                    <span class=\"hljs-comment\">\/\/ We will implement this method to allow batch evaluation of the input alternatives <\/span>\n<span class=\"hljs-function\">given the internal <span class=\"hljs-title\">models<\/span> <span class=\"hljs-params\">(constructed instances)<\/span>. This example procedure assigns a score of 0 or 1 to \neach alternative in accordance with the relation of potential optimality. Specifically, an alternative \nis considered potentially <span class=\"hljs-title\">optimal<\/span> <span class=\"hljs-params\">(i.e., the most relevant)<\/span> <span class=\"hljs-keyword\">if<\/span> it achieves the highest score among other \nalternatives <span class=\"hljs-keyword\">for<\/span> at least one compatible model instance. Such alternatives will be assigned a score of 1.\n Otherwise, a score of 0 will be assigned.  An auxiliary class <span class=\"hljs-title\">PO<\/span> <span class=\"hljs-params\">(Potential Optimality)<\/span> will be employed \nto perform these calculations. Note that the procedure generates a complex result that involves the \nprocessing time as well. The calculated scores are stored in an <span class=\"hljs-title\">array<\/span> <span class=\"hljs-params\">(<span class=\"hljs-keyword\">double<\/span> &#91;])<\/span> whose elements match \nthe input alternatives 1:1 by index.\n                    EvaluationResult evaluationResult <\/span>= <span class=\"hljs-keyword\">new<\/span> EvaluationResult();\n                    evaluationResult._startTime = System.nanoTime();\n                    evaluationResult._evaluations = <span class=\"hljs-keyword\">new<\/span> <span class=\"hljs-keyword\">double<\/span>&#91;alternatives.size()];\n                    <span class=\"hljs-keyword\">for<\/span> (<span class=\"hljs-keyword\">int<\/span> i = <span class=\"hljs-number\">0<\/span>; i &lt; alternatives.size(); i++)\n                        evaluationResult._evaluations&#91;i] = PO.isHolding(alternatives.get(i), alternatives, models) ? <span class=\"hljs-number\">1.0<\/span>d : <span class=\"hljs-number\">0.0<\/span>d;\n                    evaluationResult._elapsedTime = (<span class=\"hljs-keyword\">long<\/span>) ((System.nanoTime() - evaluationResult._startTime) \/ <span class=\"hljs-number\">1000000.0<\/span>d);\n                    <span class=\"hljs-keyword\">return<\/span> evaluationResult;\n                }\n            }\n    );\n    {\n        <span class=\"hljs-comment\">\/\/ The following code defines the preference learning strategy called each time a new feedback is <\/span>\nreceived. We will use the ERS procedure proposed in https:<span class=\"hljs-comment\">\/\/papers.ssrn.com\/sol3\/papers.cfm?abstract_id=5415565. <\/span>\n<span class=\"hljs-function\">This method generates a series of L-norm instances <span class=\"hljs-title\">that<\/span> <span class=\"hljs-params\">(i)<\/span> are compatible with the feedback <span class=\"hljs-title\">and<\/span> <span class=\"hljs-params\">(ii)<\/span> are evenly \nspaced in the model parameter space.\n        ERS.Params&lt;LNorm&gt; pERS <\/span>= <span class=\"hljs-keyword\">new<\/span> ERS.Params&lt;&gt;( <span class=\"hljs-comment\">\/\/ parameterize via the Params class<\/span>\n                <span class=\"hljs-comment\">\/\/ an auxiliary random model generator must be delivered (this generator constructs random L-norms)<\/span>\n                <span class=\"hljs-keyword\">new<\/span> LNormGenerator(\n                        C._no, <span class=\"hljs-comment\">\/\/ the number of criteria<\/span>\n                        Double.POSITIVE_INFINITY)); <span class=\"hljs-comment\">\/\/ the compensation level (makes the model a weighted Chebyshev function)<\/span>\n        pERS._similarity = <span class=\"hljs-keyword\">new<\/span> Euclidean(); <span class=\"hljs-comment\">\/\/ similarity measure (defines a similarity between two L-norms as<\/span>\n        <span class=\"hljs-comment\">\/\/ a Euclidean distance between their weight vectors)<\/span>\n        pERS._kMostSimilarNeighbors = <span class=\"hljs-number\">3<\/span>;\n        pERS._feasibleSamplesToGenerate = <span class=\"hljs-number\">50<\/span>; <span class=\"hljs-comment\">\/\/ the number of feasible models to generate<\/span>\n        pERS._iterationsLimit = <span class=\"hljs-keyword\">new<\/span> Constant(<span class=\"hljs-number\">100000<\/span>); <span class=\"hljs-comment\">\/\/ the limit for the number of iterations for the ERS procedure<\/span>\n        pERS._comparator = <span class=\"hljs-keyword\">new<\/span> MostSimilarWithTieResolving&lt;&gt;(); <span class=\"hljs-comment\">\/\/ model comparator (see the Java Doc description)<\/span>\n        pERS._EMC = <span class=\"hljs-keyword\">new<\/span> EvolutionaryModelConstructor&lt;&gt;( <span class=\"hljs-comment\">\/\/ evolutionary model constructor; this object defines<\/span>\n                <span class=\"hljs-comment\">\/\/ rules for generating a new model using parent ones (see the paper on ERS for more details)<\/span>\n                <span class=\"hljs-keyword\">new<\/span> LNormOnSimplex(Double.POSITIVE_INFINITY, <span class=\"hljs-number\">0.2<\/span>d, <span class=\"hljs-number\">0.2<\/span>d),\n                <span class=\"hljs-keyword\">new<\/span> Tournament&lt;&gt;(<span class=\"hljs-number\">2<\/span>)\n        );\n\n        modelBundle._modelConstructor = <span class=\"hljs-keyword\">new<\/span> ERS&lt;&gt;(pERS); <span class=\"hljs-comment\">\/\/ instantiate the preference learning procedure<\/span>\n    }\n\n    <span class=\"hljs-comment\">\/\/ Inconsistency handler is triggered when a preference learning procedure is not capable of constructing<\/span>\n    <span class=\"hljs-comment\">\/\/ feasible models; RemoveOldest = removes the oldest feedback and runs the preference learning procedure<\/span>\n    <span class=\"hljs-comment\">\/\/ until compatibility is restored. Then, starting from the newest removed models, these removed models<\/span>\n    <span class=\"hljs-comment\">\/\/ are individually reintroduced to the feedback set as long as they do not violate the consistency.<\/span>\n    modelBundle._inconsistencyHandler = <span class=\"hljs-keyword\">new<\/span> RemoveOldest&lt;&gt;();\n\n    <span class=\"hljs-comment\">\/\/ Finally, we can establish a decision maker's bundle associated with the decision maker labelled as DM1:<\/span>\n    DMBundle dmBundle = <span class=\"hljs-keyword\">new<\/span> DMBundle(<span class=\"hljs-string\">\"DM1\"<\/span>, modelBundle);\n    pDSS._dmBundles = <span class=\"hljs-keyword\">new<\/span> DMBundle&#91;]{dmBundle};\n}<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-7\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Java<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">java<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p style=\"font-size:14px\">The following code instantiates the decision support system as defined above. Also, it prepares two plots that will be used to visualize the alternatives space along with the decision maker&#8217;s feedback, and the learnt preference model instances compatible with the feedback:<\/p>\n\n\n<pre class=\"wp-block-code has-white-color has-text-color has-background has-link-color wp-elements-8cb6b5919f19d304f45612cf62b43684\" style=\"background-color:#2b2b2b;font-size:14px\" aria-describedby=\"shcb-language-8\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/  We can now instantiate the suitably configured decision-support system. Note that the constructor can throw a custom exception during a thorough validation of the input.<\/span>\n<span class=\"hljs-keyword\">try<\/span>\n{\n    DecisionSupportSystem DSS = <span class=\"hljs-keyword\">new<\/span> DecisionSupportSystem(pDSS);\n\n    <span class=\"hljs-comment\">\/\/ This notification must be executed before starting processing:<\/span>\n    DSS.notifySystemStarts();\n\n    <span class=\"hljs-comment\">\/\/ For convenience, let us present the results twofold. First, we will use a regular 2D scatter plot to<\/span>\n    <span class=\"hljs-comment\">\/\/ depict the objective\/criteria space. It will illustrate (i) potentially optimal alternatives,<\/span>\n    <span class=\"hljs-comment\">\/\/ (ii) not potentially optimal alternatives, and (iii) pairwise comparisons made by<\/span>\n    <span class=\"hljs-comment\">\/\/ the artificial decision-maker.<\/span>\n    Plot2D plotOS = Plot2DFactory.getPlot(\n            <span class=\"hljs-string\">\"f1\"<\/span>, <span class=\"hljs-string\">\"f2\"<\/span>, <span class=\"hljs-comment\">\/\/ axes' labels<\/span>\n            DRMPFactory.getFor2D(<span class=\"hljs-keyword\">new<\/span> Range(<span class=\"hljs-number\">0.0<\/span>d, <span class=\"hljs-number\">10.0<\/span>d), <span class=\"hljs-keyword\">new<\/span> Range(<span class=\"hljs-number\">1.0<\/span>d, <span class=\"hljs-number\">2.0<\/span>d)), <span class=\"hljs-comment\">\/\/ axes' limits<\/span>\n            <span class=\"hljs-number\">5<\/span>, <span class=\"hljs-number\">5<\/span>, <span class=\"hljs-comment\">\/\/ the number of ticks for the axes<\/span>\n            <span class=\"hljs-string\">\"0.00\"<\/span>, <span class=\"hljs-comment\">\/\/ axes' tick label formatting<\/span>\n            <span class=\"hljs-number\">1.5<\/span>f, <span class=\"hljs-comment\">\/\/ font rescalling factor<\/span>\n            scheme -&gt; scheme._colors.put(ColorFields.PLOT_BACKGROUND, Color.WHITE), <span class=\"hljs-comment\">\/\/ set the plot background color to white<\/span>\n            pP -&gt; pP._drawLegend = <span class=\"hljs-literal\">true<\/span> <span class=\"hljs-comment\">\/\/ request drawing the legend<\/span>\n    );\n\n    <span class=\"hljs-comment\">\/\/ Second, we will use another scatter plot to depict weight vectors of the compatible models learnt by ERS:<\/span>\n    Plot2D plotWS = Plot2DFactory.getPlot(\n            <span class=\"hljs-string\">\"w1\"<\/span>, <span class=\"hljs-string\">\"w2\"<\/span>,  <span class=\"hljs-comment\">\/\/ axes' labels<\/span>\n            DRMPFactory.getFor2D(Range.getNormalRange(), Range.getNormalRange()), <span class=\"hljs-comment\">\/\/ axes' limits<\/span>\n            <span class=\"hljs-number\">5<\/span>, <span class=\"hljs-number\">5<\/span>,  <span class=\"hljs-comment\">\/\/  the number of ticks for the axes<\/span>\n            <span class=\"hljs-string\">\"0.00\"<\/span>,  <span class=\"hljs-comment\">\/\/ axes' tick label formatting<\/span>\n            <span class=\"hljs-number\">1.5<\/span>f,  <span class=\"hljs-comment\">\/\/ font rescalling factor<\/span>\n            scheme -&gt; scheme._colors.put(ColorFields.PLOT_BACKGROUND, Color.WHITE), <span class=\"hljs-comment\">\/\/ set the plot background color to white<\/span>\n            pP -&gt; pP._drawLegend = <span class=\"hljs-literal\">true<\/span>  <span class=\"hljs-comment\">\/\/ request drawing the legend<\/span>\n    );\n\n    <span class=\"hljs-comment\">\/\/ Organize the plots in a grid (1 row, 2 columns):<\/span>\n    GridPlots GP = <span class=\"hljs-keyword\">new<\/span> GridPlots(<span class=\"hljs-keyword\">new<\/span> AbstractPlot&#91;]{plotOS, plotWS}, <span class=\"hljs-number\">1<\/span>, <span class=\"hljs-number\">2<\/span>);\n    <span class=\"hljs-comment\">\/\/ Construct the frame and display it:<\/span>\n    Frame frame = <span class=\"hljs-keyword\">new<\/span> Frame(GP, <span class=\"hljs-number\">1600<\/span>, <span class=\"hljs-number\">800<\/span>);\n    frame.setVisible(<span class=\"hljs-literal\">true<\/span>);<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-8\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p style=\"font-size:14px\">Next, running the system is simulated in the loop. It communicates with external components via the decision-making context:<\/p>\n\n\n<pre class=\"wp-block-code has-white-color has-text-color has-background has-link-color wp-elements-000ed8f3e751d27fafa3a836482db788\" style=\"background-color:#2b2b2b;font-size:14px\" aria-describedby=\"shcb-language-9\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php shcb-wrap-lines\">\n<span class=\"hljs-comment\">\/\/ In this example, we will iteratively run the system. If the preference elicitation and model update are triggered in an iteration, we will be deriving potentially optimal solutions. They will be stored in the PO object and passed to the system in the following iterations, subsequently reducing the number of alternatives for consideration. Here, we can treat the alternatives object explicitly as PO:<\/span>\n\nAlternatives PO = alternatives;\n\n<span class=\"hljs-keyword\">for<\/span> (int it = <span class=\"hljs-number\">0<\/span>; it &lt; <span class=\"hljs-number\">30<\/span>; it++) <span class=\"hljs-comment\">\/\/ the limit for the number of iterations = 30<\/span>\n{\n    System.out.println(<span class=\"hljs-string\">\"Iteration = \"<\/span> + it + <span class=\"hljs-string\">\" ====================================\"<\/span>);\n\n    <span class=\"hljs-comment\">\/\/ When running the system, a decision-making context must be specified and passed to the central method (context's params container). It bridges the system with some external components (e.g., an evolutionary algorithm for multiple objective optimization):<\/span>\n    DMContext.Params pDMC = <span class=\"hljs-keyword\">new<\/span> DMContext.Params(); <span class=\"hljs-comment\">\/\/ create the context (params container)<\/span>\n    pDMC._currentAlternativesSuperset = PO; <span class=\"hljs-comment\">\/\/ define the current set of alternatives<\/span>\n    <span class=\"hljs-comment\">\/\/ Define the current objective (criteria) space bounds (utopia &#91;0, 2] and nadir &#91;10, 1] points are passed via the constructor):<\/span>\n    pDMC._currentOS = <span class=\"hljs-keyword\">new<\/span> ObjectiveSpace(<span class=\"hljs-keyword\">new<\/span> double&#91;]{<span class=\"hljs-number\">0.0<\/span>d, <span class=\"hljs-number\">2.0<\/span>d}, <span class=\"hljs-keyword\">new<\/span> double&#91;]{<span class=\"hljs-number\">10.0<\/span>d, <span class=\"hljs-number\">1.0<\/span>d});\n    <span class=\"hljs-comment\">\/\/ The normalization builder is responsible for deriving normalization functions, properly rescaling the objective space into &#91;0, 1] hypercube. The standard builder constructs regular linear normalization functions for the cost-type criteria, and linear normalization functions with a flip for the gain-type criteria<\/span>\n    pDMC._normalizationBuilder = <span class=\"hljs-keyword\">new<\/span> StandardLinearBuilder();\n    <span class=\"hljs-comment\">\/\/ If this flag is set to true, the normalization functions are derived and propagated<\/span>\n    <span class=\"hljs-comment\">\/\/ to relevant rescaling-sensitive objects:<\/span>\n    pDMC._osChanged = <span class=\"hljs-keyword\">true<\/span>;\n    pDMC._currentIteration = it; <span class=\"hljs-comment\">\/\/ current iteration number<\/span>\n    pDMC._R = R; <span class=\"hljs-comment\">\/\/ random number generator to be used in various system's components<\/span>\n    <span class=\"hljs-comment\">\/\/ Having defined the context, we can call the \"execute process\" method. It first attempts to perform the preference elicitation. If it is performed successfully, it executes the preference learning procedures to discover the proper parameterization of the assumed preference models. The summary of the whole processing is returned in a complex Report object:<\/span>\n    Report report = DSS.executeProcess(pDMC);<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-9\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p style=\"font-size:14px\">For those interactions in which the interaction was triggered, the report on the processing is printed, and alternatives that are potentially optimal to the decision-maker are determined:<\/p>\n\n\n<pre class=\"wp-block-code has-white-color has-text-color has-background has-link-color wp-elements-48f8d85c5c5b676ee29eee0d49a93379\" style=\"background-color:#2b2b2b;font-size:14px\" aria-describedby=\"shcb-language-10\" data-shcb-language-name=\"JavaScript\" data-shcb-language-slug=\"javascript\"><span><code class=\"hljs language-javascript shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/ If the preference elicitation was triggered (by default, it should happen in the 10th<\/span>\n<span class=\"hljs-comment\">\/\/ and 15th iterations):<\/span>\n<span class=\"hljs-comment\">\/\/ - we will print the report and other auxiliary information<\/span>\n<span class=\"hljs-comment\">\/\/ - we will update the plots<\/span>\n<span class=\"hljs-keyword\">if<\/span> (report._elicitationReport._interactionStatus.equals(Status.PROCESS_ENDED_SUCCESSFULLY))\n{\n    report.printStringRepresentation(<span class=\"hljs-number\">3<\/span>); <span class=\"hljs-comment\">\/\/ print the report<\/span>\n\n    <span class=\"hljs-comment\">\/\/ Print the decision maker's history of preference elicitation:<\/span>\n    System.out.println(<span class=\"hljs-string\">\"Preference elicitation history:\"<\/span>);\n    History history = DSS.getDecisionMakersSystems()&#91;<span class=\"hljs-number\">0<\/span>].getHistory();\n    System.out.println(history.getFullStringRepresentation());\n\n    <span class=\"hljs-comment\">\/\/ Evaluate the alternatives using the implemented evaluator:<\/span>\n    EvaluationResult evaluationResult = DSS.getDecisionMakersSystems()&#91;<span class=\"hljs-number\">0<\/span>].getModelSystems()&#91;<span class=\"hljs-number\">0<\/span>].evaluateAlternatives(alternatives);\n    <span class=\"hljs-comment\">\/\/ Print the evaluation result:<\/span>\n    System.out.println(<span class=\"hljs-string\">\"Evaluation result:\"<\/span>);\n    System.out.println(evaluationResult.toString());\n\n    <span class=\"hljs-comment\">\/\/ We can now determine the subset of alternatives that proved potentially optimal:<\/span>\n    ArrayList&lt;Alternative&gt; aPO = <span class=\"hljs-keyword\">new<\/span> ArrayList&lt;&gt;(alternatives.size());\n    <span class=\"hljs-keyword\">for<\/span> (int i = <span class=\"hljs-number\">0<\/span>; i &lt; alternatives.size(); i++)\n        <span class=\"hljs-keyword\">if<\/span> (Double.compare(evaluationResult._evaluations&#91;i], <span class=\"hljs-number\">0.5<\/span>d) &gt;= <span class=\"hljs-number\">0<\/span>) aPO.add(alternatives.get(i));\n\n    <span class=\"hljs-comment\">\/\/ We will use these derived alternatives to instantiate a new PO object that will be passed via<\/span>\n    <span class=\"hljs-comment\">\/\/ the context in subsequent iterations:<\/span>\n    PO = <span class=\"hljs-keyword\">new<\/span> Alternatives(aPO);\n\n    System.out.println(<span class=\"hljs-string\">\"Potentially optimal alternatives = \"<\/span> + PO.size());<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-10\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">JavaScript<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">javascript<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p style=\"font-size:14px\">The following code updates the first plot depicting the objective space:<\/p>\n\n\n<pre class=\"wp-block-code has-white-color has-text-color has-background has-link-color wp-elements-db8c97b3f511dc1b4e7faaba66d04eaa\" style=\"background-color:#2b2b2b;font-size:14px\" aria-describedby=\"shcb-language-11\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/ The following code constructs data sets to be displayed on plot 1:<\/span>\n{\n    ArrayList&lt;IDataSet&gt; DSs = <span class=\"hljs-keyword\">new<\/span> ArrayList&lt;&gt;(); <span class=\"hljs-comment\">\/\/ define data sets array<\/span>\n\n    <span class=\"hljs-comment\">\/\/ We will first focus on the pairwise comparisons. We will parse them from the history of<\/span>\n    <span class=\"hljs-comment\">\/\/ preference elicitation and store them in an array of alternatives (each pair will be<\/span>\n    <span class=\"hljs-comment\">\/\/ associated with one pairwise comparison):<\/span>\n    ArrayList&lt;Alternative&gt; pcs = <span class=\"hljs-keyword\">new<\/span> ArrayList&lt;&gt;(history.getNoPreferenceExamples() * <span class=\"hljs-number\">2<\/span>);\n\n    <span class=\"hljs-comment\">\/\/ Note that the history protects access to stored feedback.<\/span>\n    <span class=\"hljs-comment\">\/\/ A copy of auxiliary wrappers can be retrieved, though:<\/span>\n    <span class=\"hljs-keyword\">for<\/span> (PreferenceInformationWrapper piw : history.getPreferenceInformationCopy())\n    {\n        <span class=\"hljs-comment\">\/\/ Check the types and ignore irrelevant forms (should not happen in this example):<\/span>\n        <span class=\"hljs-keyword\">if<\/span> (!(piw._preferenceInformation <span class=\"hljs-keyword\">instanceof<\/span> PairwiseComparison PC)) <span class=\"hljs-keyword\">continue<\/span>;\n        <span class=\"hljs-keyword\">if<\/span> (!PC.getRelation().equals(Relations.PREFERENCE)) <span class=\"hljs-keyword\">continue<\/span>;\n        <span class=\"hljs-comment\">\/\/ RRetrieve the alternatives and store them in the array (side <span class=\"hljs-doctag\">note:<\/span> the alternatives are<\/span>\n        <span class=\"hljs-comment\">\/\/ not immutable; thus, the preference elicitation history is not completely immutable as well):<\/span>\n        pcs.add(PC.getNotPreferredAlternative());\n        pcs.add(PC.getPreferredAlternative());\n    }\n\n    <span class=\"hljs-comment\">\/\/ Generate data matrix to be displayed:<\/span>\n    double&#91;]&#91;] data = <span class=\"hljs-keyword\">new<\/span> double&#91;pcs.size()]&#91;<span class=\"hljs-number\">2<\/span>];\n    <span class=\"hljs-keyword\">for<\/span> (int i = <span class=\"hljs-number\">0<\/span>; i &lt; pcs.size(); i += <span class=\"hljs-number\">2<\/span>)\n    {\n        data&#91;i]&#91;<span class=\"hljs-number\">0<\/span>] = pcs.get(i).getPerformanceVector()&#91;<span class=\"hljs-number\">0<\/span>];\n        data&#91;i]&#91;<span class=\"hljs-number\">1<\/span>] = pcs.get(i).getPerformanceVector()&#91;<span class=\"hljs-number\">1<\/span>];\n        data&#91;i + <span class=\"hljs-number\">1<\/span>]&#91;<span class=\"hljs-number\">0<\/span>] = pcs.get(i + <span class=\"hljs-number\">1<\/span>).getPerformanceVector()&#91;<span class=\"hljs-number\">0<\/span>];\n        data&#91;i + <span class=\"hljs-number\">1<\/span>]&#91;<span class=\"hljs-number\">1<\/span>] = pcs.get(i + <span class=\"hljs-number\">1<\/span>).getPerformanceVector()&#91;<span class=\"hljs-number\">1<\/span>];\n    }\n\n    <span class=\"hljs-comment\">\/\/ Create a data set to be illustrated as arrows reflecting the pairwise comparisons:<\/span>\n    DSs.add(DSFactory2D.getDS(\n                    <span class=\"hljs-string\">\"PCs\"<\/span>, <span class=\"hljs-comment\">\/\/ data set name<\/span>\n                    data, <span class=\"hljs-comment\">\/\/ data (matrix)<\/span>\n                    <span class=\"hljs-keyword\">new<\/span> LineStyle(<span class=\"hljs-number\">1.0<\/span>f, color.gradient.Color.BLUE), <span class=\"hljs-comment\">\/\/ line style (width and color)<\/span>\n                    <span class=\"hljs-keyword\">new<\/span> ArrowStyles( <span class=\"hljs-comment\">\/\/ arrow style; an end of the arrow is defined:<\/span>\n                            <span class=\"hljs-keyword\">new<\/span> ArrowStyle( <span class=\"hljs-comment\">\/\/ style for the arrow's end<\/span>\n                                    <span class=\"hljs-number\">3.5<\/span>f, <span class=\"hljs-comment\">\/\/ length<\/span>\n                                    <span class=\"hljs-number\">3.5<\/span>f, <span class=\"hljs-comment\">\/\/ width<\/span>\n                                    color.gradient.Color.BLUE, <span class=\"hljs-comment\">\/\/ fill color<\/span>\n                                    Arrow.TRIANGULAR_2D <span class=\"hljs-comment\">\/\/ style<\/span>\n                            )\n                    ),\n                    <span class=\"hljs-comment\">\/\/ Important flag for data interpretation: if true, each pair in the input data<\/span>\n                    <span class=\"hljs-comment\">\/\/ matrix will be treated as a singular and disconnected line (if false, the whole<\/span>\n                    <span class=\"hljs-comment\">\/\/ matrix will be assumed to contain a series of points forming a connected series of lines):<\/span>\n                    <span class=\"hljs-keyword\">true<\/span>\n            )\n    );\n\n    <span class=\"hljs-comment\">\/\/ The following lines prepare a data set portraying all alternatives:<\/span>\n    data = <span class=\"hljs-keyword\">new<\/span> double&#91;alternatives.size()]&#91;<span class=\"hljs-number\">2<\/span>];\n    <span class=\"hljs-keyword\">for<\/span> (int i = <span class=\"hljs-number\">0<\/span>; i &lt; alternatives.size(); i++)\n    {\n        data&#91;i]&#91;<span class=\"hljs-number\">0<\/span>] = alternatives.get(i).getPerformanceVector()&#91;<span class=\"hljs-number\">0<\/span>];\n        data&#91;i]&#91;<span class=\"hljs-number\">1<\/span>] = alternatives.get(i).getPerformanceVector()&#91;<span class=\"hljs-number\">1<\/span>];\n    }\n    DSs.add(DSFactory2D.getDS(<span class=\"hljs-string\">\"All alternatives\"<\/span>, data,\n            <span class=\"hljs-keyword\">new<\/span> MarkerStyle(\n                    <span class=\"hljs-number\">1.0<\/span>f, <span class=\"hljs-comment\">\/\/ size<\/span>\n                    color.gradient.Color.RED, <span class=\"hljs-comment\">\/\/ fill color<\/span>\n                    Marker.CIRCLE, <span class=\"hljs-comment\">\/\/ style<\/span>\n                    <span class=\"hljs-number\">2.0<\/span>f <span class=\"hljs-comment\">\/\/ size used when drawing a corresponding legend entry<\/span>\n            )));\n\n    <span class=\"hljs-comment\">\/\/ The following lines prepare a data set portraying potentially optimal alternatives:<\/span>\n    data = <span class=\"hljs-keyword\">new<\/span> double&#91;PO.size()]&#91;<span class=\"hljs-number\">2<\/span>];\n    <span class=\"hljs-keyword\">for<\/span> (int i = <span class=\"hljs-number\">0<\/span>; i &lt; PO.size(); i++)\n    {\n        data&#91;i]&#91;<span class=\"hljs-number\">0<\/span>] = PO.get(i).getPerformanceVector()&#91;<span class=\"hljs-number\">0<\/span>];\n        data&#91;i]&#91;<span class=\"hljs-number\">1<\/span>] = PO.get(i).getPerformanceVector()&#91;<span class=\"hljs-number\">1<\/span>];\n    }\n    DSs.add(DSFactory2D.getDS(<span class=\"hljs-string\">\"PO alternatives\"<\/span>, data,\n            <span class=\"hljs-keyword\">new<\/span> MarkerStyle(\n                    <span class=\"hljs-number\">2.0<\/span>f, <span class=\"hljs-comment\">\/\/ size<\/span>\n                    color.gradient.Color.BLACK, <span class=\"hljs-comment\">\/\/ fill color<\/span>\n                    Marker.SQUARE, <span class=\"hljs-comment\">\/\/ style<\/span>\n                    <span class=\"hljs-number\">3.0<\/span>f <span class=\"hljs-comment\">\/\/ size used when drawing a corresponding legend entry<\/span>\n            )));\n\n    <span class=\"hljs-comment\">\/\/ Update data sets:<\/span>\n    plotOS.getModel().setDataSets(\n            DSs, <span class=\"hljs-keyword\">true<\/span>, <span class=\"hljs-comment\">\/\/ update the display ranges (prepares axes' titles, etc.)<\/span>\n            <span class=\"hljs-keyword\">true<\/span> <span class=\"hljs-comment\">\/\/ update data associated with legend rendering<\/span>\n    );\n}<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-11\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>The following code updates the first plot depicting the compatible model space, and creates a joint render to be stored on a disc:<\/p>\n\n\n<pre class=\"wp-block-code has-white-color has-text-color has-background has-link-color wp-elements-94c8447aa31efb1d8222918e1b74c38d\" style=\"background-color:#2b2b2b;font-size:14px\" aria-describedby=\"shcb-language-12\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php shcb-wrap-lines\"><span class=\"hljs-comment\">\/\/ The following code constructs data sets to be displayed on plot 2 (compatible models' weight vectors):<\/span>\n            {\n                <span class=\"hljs-comment\">\/\/ Derive the preference model:<\/span>\n                IPreferenceModel<span class=\"hljs-meta\">&lt;?<\/span> extends AbstractInternalModel&gt; preferenceModel =\n                        DSS.getDecisionMakersSystems()&#91;<span class=\"hljs-number\">0<\/span>].getModelSystems()&#91;<span class=\"hljs-number\">0<\/span>].getPreferenceModel();\n                <span class=\"hljs-comment\">\/\/ Derive the model's instances:<\/span>\n                ArrayList<span class=\"hljs-meta\">&lt;?<\/span> extends AbstractInternalModel&gt; models = preferenceModel.getInternalModels();\n                <span class=\"hljs-comment\">\/\/ Prepare a data matrix associated with internal models' weight vectors:<\/span>\n                double&#91;]&#91;] w = <span class=\"hljs-keyword\">new<\/span> double&#91;models.size()]&#91;<span class=\"hljs-number\">2<\/span>];\n                <span class=\"hljs-keyword\">for<\/span> (int i = <span class=\"hljs-number\">0<\/span>; i &lt; models.size(); i++)\n                    w&#91;i] = models.get(i).getWeights().<span class=\"hljs-keyword\">clone<\/span>(); <span class=\"hljs-comment\">\/\/ note that getWeights() method is imposed by<\/span>\n                <span class=\"hljs-comment\">\/\/ the implemented interface; the result may vary depending on the concrete model definition;<\/span>\n                <span class=\"hljs-comment\">\/\/ also the clone method is used for safety<\/span>\n                <span class=\"hljs-comment\">\/\/ Create the data set and update the plot:<\/span>\n                plotWS.getModel().setDataSet(DSFactory2D.getDS(<span class=\"hljs-string\">\"Compatible weights\"<\/span>, w,\n                                <span class=\"hljs-keyword\">new<\/span> MarkerStyle(<span class=\"hljs-number\">1.0<\/span>f, <span class=\"hljs-comment\">\/\/ size<\/span>\n                                        color.gradient.Color.BLACK, <span class=\"hljs-comment\">\/\/ fill color<\/span>\n                                        Marker.SQUARE <span class=\"hljs-comment\">\/\/ style<\/span>\n                                )),\n                        <span class=\"hljs-keyword\">true<\/span>, <span class=\"hljs-comment\">\/\/ update the display ranges (prepares axes' titles, etc.)<\/span>\n                        <span class=\"hljs-keyword\">true<\/span> <span class=\"hljs-comment\">\/\/ update data associated with legend rendering<\/span>\n                );\n            }\n\n            <span class=\"hljs-comment\">\/\/ For this quick-start tutorial, the screenshot of the plot is generated and stored.<\/span>\n            <span class=\"hljs-comment\">\/\/ It can be accomplished in the following way:<\/span>\n            Screenshot screenshot1 = plotOS.getModel().requestScreenshotCreation(\n                    plotOS.getWidth(), <span class=\"hljs-comment\">\/\/ screenshot width (independent to the current plot width)<\/span>\n                    plotOS.getHeight(),  <span class=\"hljs-comment\">\/\/ screenshot height (independent to the current plot height)<\/span>\n                    <span class=\"hljs-keyword\">false<\/span>, <span class=\"hljs-comment\">\/\/ do not use the alpha channel<\/span>\n                    <span class=\"hljs-keyword\">null<\/span> <span class=\"hljs-comment\">\/\/ optional parameter that indicates that the plot will be clipped to its content by<\/span>\n                    <span class=\"hljs-comment\">\/\/ removing the first\/last columns\/rows that match the given color (e.g., check Color.WHITE)<\/span>\n            );\n\n            <span class=\"hljs-comment\">\/\/ For this quick-start tutorial, the screenshot of the plot is generated and stored.<\/span>\n            <span class=\"hljs-comment\">\/\/ It can be accomplished in the following way:<\/span>\n            Screenshot screenshot2 = plotWS.getModel().requestScreenshotCreation(\n                    plotWS.getWidth(), <span class=\"hljs-comment\">\/\/ screenshot width (independent to the current plot width)<\/span>\n                    plotWS.getHeight(),  <span class=\"hljs-comment\">\/\/ screenshot height (independent to the current plot height)<\/span>\n                    <span class=\"hljs-keyword\">false<\/span>, <span class=\"hljs-comment\">\/\/ do not use the alpha channel<\/span>\n                    <span class=\"hljs-keyword\">null<\/span> <span class=\"hljs-comment\">\/\/ optional parameter that indicates that the plot will be clipped to its content by<\/span>\n                    <span class=\"hljs-comment\">\/\/ removing the first\/last columns\/rows that match the given color (e.g., check Color.WHITE)<\/span>\n            );\n\n            screenshot1._barrier.await();\n            screenshot2._barrier.await();\n            BufferedImage screenshot = ImageUtils.mergeHorizontally(screenshot1._image, screenshot2._image);\n\n            <span class=\"hljs-comment\">\/\/ Finally, we can use the following method to save the screenshot.<\/span>\n            ImageSaver.saveImage(\n                    screenshot, <span class=\"hljs-comment\">\/\/ screenshot to be saved<\/span>\n                    <span class=\"hljs-string\">\"D:\"<\/span> + File.separatorChar + <span class=\"hljs-string\">\"quickstart3_\"<\/span> + it, <span class=\"hljs-comment\">\/\/ file path (excludes the extension; alter it according<\/span>\n                    <span class=\"hljs-comment\">\/\/ to your computer specification and needs)<\/span>\n                    <span class=\"hljs-string\">\"jpg\"<\/span>, <span class=\"hljs-comment\">\/\/ file extension (only regular file types, e.g., bmp or jpg are supported; in the case of<\/span>\n                    <span class=\"hljs-comment\">\/\/ providing an unsupported extension, an error message will be printed)<\/span>\n                    <span class=\"hljs-number\">1.0<\/span>f <span class=\"hljs-comment\">\/\/ image quality (1.0 = the best; not all extensions support this parameter)<\/span>\n            );\n        }\n    }\n\n} <span class=\"hljs-keyword\">catch<\/span> (DecisionSupportSystemException | ModelSystemException | HistoryException | InterruptedException e)\n{\n    <span class=\"hljs-keyword\">throw<\/span> <span class=\"hljs-keyword\">new<\/span> RuntimeException(e);\n}<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-12\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p style=\"font-size:14px\">An example console output associated with the report on the system&#8217;s processing done in the 15th iteration (when the second interaction was expected to happen) is illustrated below:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1512\" height=\"791\" src=\"https:\/\/www.jecdm.cs.put.poznan.pl\/wp-content\/uploads\/2025\/09\/log.jpg\" alt=\"\" class=\"wp-image-390\"\/><\/figure>\n\n\n\n<p>Expected render generated in the 10th iteration:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1584\" height=\"761\" src=\"https:\/\/www.jecdm.cs.put.poznan.pl\/wp-content\/uploads\/2025\/09\/quickstart3_10.jpg\" alt=\"\" class=\"wp-image-388\"\/><\/figure>\n\n\n\n<p>Expected render generated in the 15th iteration:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1584\" height=\"761\" src=\"https:\/\/www.jecdm.cs.put.poznan.pl\/wp-content\/uploads\/2025\/09\/quickstart3_15.jpg\" alt=\"\" class=\"wp-image-389\"\/><\/figure>\n\n\n\n<p style=\"font-size:18px\"><strong>Used imports:<\/strong><\/p>\n\n\n<pre class=\"wp-block-code has-white-color has-text-color has-background has-link-color wp-elements-9565b797b955629ef7007a20af97dea1\" style=\"background-color:#2b2b2b;font-size:14px\" aria-describedby=\"shcb-language-13\" data-shcb-language-name=\"CSS\" data-shcb-language-slug=\"css\"><span><code class=\"hljs language-css\"><span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">alternative<\/span><span class=\"hljs-selector-class\">.AbstractAlternatives<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">alternative<\/span><span class=\"hljs-selector-class\">.Alternative<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">alternative<\/span><span class=\"hljs-selector-class\">.Alternatives<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">color<\/span><span class=\"hljs-selector-class\">.Color<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">criterion<\/span><span class=\"hljs-selector-class\">.Criteria<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">dataset<\/span><span class=\"hljs-selector-class\">.DSFactory2D<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">dataset<\/span><span class=\"hljs-selector-class\">.IDataSet<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">dataset<\/span><span class=\"hljs-selector-class\">.painter<\/span><span class=\"hljs-selector-class\">.style<\/span><span class=\"hljs-selector-class\">.ArrowStyle<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">dataset<\/span><span class=\"hljs-selector-class\">.painter<\/span><span class=\"hljs-selector-class\">.style<\/span><span class=\"hljs-selector-class\">.ArrowStyles<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">dataset<\/span><span class=\"hljs-selector-class\">.painter<\/span><span class=\"hljs-selector-class\">.style<\/span><span class=\"hljs-selector-class\">.LineStyle<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">dataset<\/span><span class=\"hljs-selector-class\">.painter<\/span><span class=\"hljs-selector-class\">.style<\/span><span class=\"hljs-selector-class\">.MarkerStyle<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">dataset<\/span><span class=\"hljs-selector-class\">.painter<\/span><span class=\"hljs-selector-class\">.style<\/span><span class=\"hljs-selector-class\">.enums<\/span><span class=\"hljs-selector-class\">.Arrow<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">dataset<\/span><span class=\"hljs-selector-class\">.painter<\/span><span class=\"hljs-selector-class\">.style<\/span><span class=\"hljs-selector-class\">.enums<\/span><span class=\"hljs-selector-class\">.Marker<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">decisionsupport<\/span><span class=\"hljs-selector-class\">.operators<\/span><span class=\"hljs-selector-class\">.LNormOnSimplex<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">dmcontext<\/span><span class=\"hljs-selector-class\">.DMContext<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">drmanager<\/span><span class=\"hljs-selector-class\">.DRMPFactory<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">exeption<\/span><span class=\"hljs-selector-class\">.DecisionSupportSystemException<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">exeption<\/span><span class=\"hljs-selector-class\">.HistoryException<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">exeption<\/span><span class=\"hljs-selector-class\">.ModelSystemException<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">exeption<\/span><span class=\"hljs-selector-class\">.PreferenceModelException<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">frame<\/span><span class=\"hljs-selector-class\">.Frame<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">history<\/span><span class=\"hljs-selector-class\">.History<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">history<\/span><span class=\"hljs-selector-class\">.PreferenceInformationWrapper<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">inconsistency<\/span><span class=\"hljs-selector-class\">.RemoveOldest<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">interaction<\/span><span class=\"hljs-selector-class\">.Status<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">interaction<\/span><span class=\"hljs-selector-class\">.feedbackprovider<\/span><span class=\"hljs-selector-class\">.FeedbackProvider<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">interaction<\/span><span class=\"hljs-selector-class\">.feedbackprovider<\/span><span class=\"hljs-selector-class\">.dm<\/span><span class=\"hljs-selector-class\">.artificial<\/span><span class=\"hljs-selector-class\">.value<\/span><span class=\"hljs-selector-class\">.ArtificialValueDM<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">interaction<\/span><span class=\"hljs-selector-class\">.reference<\/span><span class=\"hljs-selector-class\">.ReferenceSetsConstructor<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">interaction<\/span><span class=\"hljs-selector-class\">.reference<\/span><span class=\"hljs-selector-class\">.constructor<\/span><span class=\"hljs-selector-class\">.IReferenceSetConstructor<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">interaction<\/span><span class=\"hljs-selector-class\">.reference<\/span><span class=\"hljs-selector-class\">.constructor<\/span><span class=\"hljs-selector-class\">.RandomPairs<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">interaction<\/span><span class=\"hljs-selector-class\">.refine<\/span><span class=\"hljs-selector-class\">.Refiner<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">interaction<\/span><span class=\"hljs-selector-class\">.refine<\/span><span class=\"hljs-selector-class\">.filters<\/span><span class=\"hljs-selector-class\">.reduction<\/span><span class=\"hljs-selector-class\">.RemoveDominated<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">interaction<\/span><span class=\"hljs-selector-class\">.refine<\/span><span class=\"hljs-selector-class\">.filters<\/span><span class=\"hljs-selector-class\">.termination<\/span><span class=\"hljs-selector-class\">.RequiredSpread<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">interaction<\/span><span class=\"hljs-selector-class\">.trigger<\/span><span class=\"hljs-selector-class\">.InteractionTrigger<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">interaction<\/span><span class=\"hljs-selector-class\">.trigger<\/span><span class=\"hljs-selector-class\">.rules<\/span><span class=\"hljs-selector-class\">.IterationInterval<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">model<\/span><span class=\"hljs-selector-class\">.IPreferenceModel<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">model<\/span><span class=\"hljs-selector-class\">.constructor<\/span><span class=\"hljs-selector-class\">.random<\/span><span class=\"hljs-selector-class\">.LNormGenerator<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">model<\/span><span class=\"hljs-selector-class\">.constructor<\/span><span class=\"hljs-selector-class\">.value<\/span><span class=\"hljs-selector-class\">.rs<\/span><span class=\"hljs-selector-class\">.ers<\/span><span class=\"hljs-selector-class\">.ERS<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">model<\/span><span class=\"hljs-selector-class\">.constructor<\/span><span class=\"hljs-selector-class\">.value<\/span><span class=\"hljs-selector-class\">.rs<\/span><span class=\"hljs-selector-class\">.ers<\/span><span class=\"hljs-selector-class\">.comparators<\/span><span class=\"hljs-selector-class\">.MostSimilarWithTieResolving<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">model<\/span><span class=\"hljs-selector-class\">.constructor<\/span><span class=\"hljs-selector-class\">.value<\/span><span class=\"hljs-selector-class\">.rs<\/span><span class=\"hljs-selector-class\">.ers<\/span><span class=\"hljs-selector-class\">.evolutionary<\/span><span class=\"hljs-selector-class\">.EvolutionaryModelConstructor<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">model<\/span><span class=\"hljs-selector-class\">.constructor<\/span><span class=\"hljs-selector-class\">.value<\/span><span class=\"hljs-selector-class\">.rs<\/span><span class=\"hljs-selector-class\">.ers<\/span><span class=\"hljs-selector-class\">.evolutionary<\/span><span class=\"hljs-selector-class\">.Tournament<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">model<\/span><span class=\"hljs-selector-class\">.constructor<\/span><span class=\"hljs-selector-class\">.value<\/span><span class=\"hljs-selector-class\">.rs<\/span><span class=\"hljs-selector-class\">.iterationslimit<\/span><span class=\"hljs-selector-class\">.Constant<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">model<\/span><span class=\"hljs-selector-class\">.evaluator<\/span><span class=\"hljs-selector-class\">.EvaluationResult<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">model<\/span><span class=\"hljs-selector-class\">.evaluator<\/span><span class=\"hljs-selector-class\">.IEvaluator<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">model<\/span><span class=\"hljs-selector-class\">.internals<\/span><span class=\"hljs-selector-class\">.AbstractInternalModel<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">model<\/span><span class=\"hljs-selector-class\">.internals<\/span><span class=\"hljs-selector-class\">.value<\/span><span class=\"hljs-selector-class\">.scalarizing<\/span><span class=\"hljs-selector-class\">.LNorm<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">model<\/span><span class=\"hljs-selector-class\">.similarity<\/span><span class=\"hljs-selector-class\">.lnorm<\/span><span class=\"hljs-selector-class\">.Euclidean<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">plot<\/span><span class=\"hljs-selector-class\">.AbstractPlot<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">plot<\/span><span class=\"hljs-selector-class\">.Plot2D<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">plot<\/span><span class=\"hljs-selector-class\">.Plot2DFactory<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">plotswrapper<\/span><span class=\"hljs-selector-class\">.GridPlots<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">preference<\/span><span class=\"hljs-selector-class\">.indirect<\/span><span class=\"hljs-selector-class\">.PairwiseComparison<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">print<\/span><span class=\"hljs-selector-class\">.PrintUtils<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">random<\/span><span class=\"hljs-selector-class\">.IRandom<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">random<\/span><span class=\"hljs-selector-class\">.L32_X64_MIX<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">relation<\/span><span class=\"hljs-selector-class\">.PO<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">relation<\/span><span class=\"hljs-selector-class\">.Relations<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">scheme<\/span><span class=\"hljs-selector-class\">.enums<\/span><span class=\"hljs-selector-class\">.ColorFields<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">space<\/span><span class=\"hljs-selector-class\">.Range<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">space<\/span><span class=\"hljs-selector-class\">.normalization<\/span><span class=\"hljs-selector-class\">.INormalization<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">space<\/span><span class=\"hljs-selector-class\">.normalization<\/span><span class=\"hljs-selector-class\">.builder<\/span><span class=\"hljs-selector-class\">.StandardLinearBuilder<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">space<\/span><span class=\"hljs-selector-class\">.normalization<\/span><span class=\"hljs-selector-class\">.minmax<\/span><span class=\"hljs-selector-class\">.Linear<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">space<\/span><span class=\"hljs-selector-class\">.normalization<\/span><span class=\"hljs-selector-class\">.minmax<\/span><span class=\"hljs-selector-class\">.LinearWithFlip<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">space<\/span><span class=\"hljs-selector-class\">.os<\/span><span class=\"hljs-selector-class\">.ObjectiveSpace<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">system<\/span><span class=\"hljs-selector-class\">.ds<\/span><span class=\"hljs-selector-class\">.DMBundle<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">system<\/span><span class=\"hljs-selector-class\">.ds<\/span><span class=\"hljs-selector-class\">.DecisionSupportSystem<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">system<\/span><span class=\"hljs-selector-class\">.ds<\/span><span class=\"hljs-selector-class\">.ModelBundle<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">system<\/span><span class=\"hljs-selector-class\">.ds<\/span><span class=\"hljs-selector-class\">.Report<\/span>;\n\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">java<\/span><span class=\"hljs-selector-class\">.util<\/span><span class=\"hljs-selector-class\">.ArrayList<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">java<\/span><span class=\"hljs-selector-class\">.util<\/span><span class=\"hljs-selector-class\">.HashMap<\/span>;\n<span class=\"hljs-selector-tag\">import<\/span> <span class=\"hljs-selector-tag\">java<\/span><span class=\"hljs-selector-class\">.util<\/span><span class=\"hljs-selector-class\">.LinkedList<\/span>;<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-13\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">CSS<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">css<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>","protected":false},"excerpt":{"rendered":"<p>This quick-start tutorial demonstrates how to configure the Decision Support System and simulate its use. The example involves artificial and easily comprehensible data. The modelled decision-making process makes the following assumptions: The results of the processing are visualized and reported in the console. Note that, although it is a quick-start tutorial, having at least a\u2026 <span class=\"read-more\"><a href=\"https:\/\/www.jecdm.cs.put.poznan.pl\/?page_id=364\">Read More &raquo;<\/a><\/span><\/p>\n","protected":false},"author":2,"featured_media":0,"parent":276,"menu_order":3,"comment_status":"closed","ping_status":"closed","template":"page-templates\/full-width.php","meta":{"footnotes":""},"class_list":["post-364","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.jecdm.cs.put.poznan.pl\/index.php?rest_route=\/wp\/v2\/pages\/364"}],"collection":[{"href":"https:\/\/www.jecdm.cs.put.poznan.pl\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.jecdm.cs.put.poznan.pl\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.jecdm.cs.put.poznan.pl\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.jecdm.cs.put.poznan.pl\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=364"}],"version-history":[{"count":30,"href":"https:\/\/www.jecdm.cs.put.poznan.pl\/index.php?rest_route=\/wp\/v2\/pages\/364\/revisions"}],"predecessor-version":[{"id":410,"href":"https:\/\/www.jecdm.cs.put.poznan.pl\/index.php?rest_route=\/wp\/v2\/pages\/364\/revisions\/410"}],"up":[{"embeddable":true,"href":"https:\/\/www.jecdm.cs.put.poznan.pl\/index.php?rest_route=\/wp\/v2\/pages\/276"}],"wp:attachment":[{"href":"https:\/\/www.jecdm.cs.put.poznan.pl\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=364"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}