A Mobile Phone Example with four Objectives
Back to Introduction
Here’s a simple example of a model suitable for optimization using ClaferMoo. In order to analyze the model and explore the Pareto front in ClaferMoo Visualizer, click the link below:
Modeling the Optimization Problem
First, we need to define features with some quality attributes
productivity
, cost
, batterylife
,
and security
:
Next, we need to write a model of our product line with some variability regarding the features. We need to set the values for quality attributes of each feature.
We could define a specialization and extension like this (currently not supported)
Next, we define our product OptimalPhone
.
The product is underspecified allowing for all possible valid combinations of features.
Finally, we define the following four optimization goals.
“Maximize total battery life”:
“Maximize total productivity”:
“Maximize total security”:
“Minimize total cost”:
In order to analyze the model and explore the Pareto front in ClaferMoo Visualizer, click the link below:
Comparing existing products
Engineers may want to compare the existing product variants (e.g.,
currently in production) with the optimal variants available in the new
version of the product line (e.g., after the feature LTE
has been added).
For example, consider an existing product MyOldPhone
which has an older version of Bluetooth, 20EDR
, and no
WiFi
, LTE
, nor USB
. Here is the
configuration of that product in Clafer notation:
MyOldPhone : MobilePhone
[ Bluetooth20EDR ]
[ no LTE ]
[ no WiFi ]
[ no USB ]
[ LiBattery1150 ]
In order to load that configuration into the visualizer
- Download the instance data file corresponding to the above instance specification,
- In Visualizer, open that file in the
Inputs
view and click on the buttonAdd Instances
.
- The visualizer will load this configuration and show it alongside the optimal products as a square.
Now, you may proceed with some exploration. For example,
- Select the existing variant
17
and the closest optimal variant2
.
- The visualizer will show the differences in the view
Comparison
- Observe that changing the feature
Bluetooth20EDR
toBluetooth21EDR
would make the product optimal - Set the upper bound for
cost
to120
in the viewObjectives
- The cost
120
is the largest acceptable in the market segment - The visualizer only shows variants costing less or equal to
120
- Select the best variant
16
for comparison
- Observe that by increasing cost by just
7
, we can obtain a far superior variant which includes the latestBluetooth40
,LTE
, andUSB
but noWifi
.