Dynamics AX 2012 Optimization – Product Configurator
Purpose:
The purpose of this document is to illustrate how Product Configurator
can be used in Dynamics AX 2012 to configure products and services. In
this document the emphasis will be put on how to build rules base or
constraints base for particular business scenario to ensure that valid
combination of modeling variables values is selected.
Challenge:
In Dynamics AX 2012 new Product Configurator was introduced which will
ultimately replace Product Builder in the next release. Product
Configurator is a new Configurator solution which leverages Solver
Foundation engine. One of the reasons to introduce Product Configurator
was to eliminate a need for Developer license in order to use
Configurator capabilities of Dynamics AX 2012, so functional users will
be able to use Configurator efficiently. The challenge is to understand
how Product Configurator can be effectively used to implement real
world rules-based and constraint-based configuration scenarios.
Solution:
Example of start-to-end Car configuration using Product Configurator in
Dynamics AX 2012 will be described in this document. We start with
definition of the problem and its formalization, and then continue with
translating this knowledge into Dynamics AX 2012 terms and setting up
the system appropriately, and end with working solution and the result.
Configuration Model:
Modeling Variable Name
|
Modeling Variable Value(s)
|
Type
|
"Sport Car", "Family Car"
|
Package
|
"Deluxe", "Luxury", "Standard"
|
Frame
|
"Convertible", "Hatchback", "Sedan"
|
Engine
|
"A", "B"
|
Transmission
|
"Manual", "HalfAutomatic", "Automatic"
|
In this example Car is configured using 5 modeling variables such as
Type, Package, Frame, Engine and Transmission. Each modeling variable
has a set of possible values as depicted in the table above. The task is
to build rules base or constraints base for Car configuration scenario
to ensure that valid combination of modeling variables values is
selected.
Configuration Model Diagram:

In
the configuration process client initially is supposed to provide input
regarding Type of Car which he/she needs and what Package will have to
be included. After that other Car specifications will be determined such
as Frame, Engine and Transmission based on Configuration rules.
For example, Client says: "I need Deluxe Sport Car" and the system will
have to ensure that valid combination of Car specifications is selected
as the result of configuration.
On the Configuration Model Diagram you can see that certain modeling
variables drive the selection of other modeling variables. For example,
Type of Car is used to determine Transmission. Please see the full list
of Configuration rules which were composed with knowledge of business
domain (Automotive industry in this example).
Configuration Rules:
Rule 1: IF Package = "Deluxe" AND Frame = "Convertible" THEN Engine = "A"
Rule 2: IF Package = "Deluxe" AND Frame = "Hatchback" THEN Engine = "B"
Rule 3: IF Package = "Standard" AND Frame = "Convertible" THEN Engine = "A"
Rule 4: IF Engine = "A" THEN Transmission = "Manual"
Rule 5: IF Engine = "B" THEN Transmission = "Automatic"
Rule 6: IF Type = "Sport Car" THEN Frame = "Convertible"
Rule 7: IF Type = "Family Car" THEN Frame = "Sedan"
Rule 8: IF Type = "Sport Car" THEN Transmission = "Manual"
Rules 1, 2 and 3 use Package and Frame to determine Engine. Rules 4 and
5 make decision about Transmission based on Engine. Rules 6 and 7
decide on Frame taking into account Type. And Rule 8 uses Type to
determine Transmission.
Please note that certain modeling variable selection may be a result of
different combinations of other modeling variables selections which is
the case in complex business domains (such as Automotive industry).
Next step:
We will define Product Configuration Model, Attributes and Attribute
types, and design User Interface for Product Configuration Model in
Dynamics AX 2012
Attribute types
Attribute Type Name
|
Base Type
|
Attribute Type Fixed List
|
CarType
|
Text
|
"Sport Car", "Family Car"
|
CarPackage
|
Text
|
"Deluxe", "Luxury", "Standard"
|
CarFrame
|
Text
|
"Convertible", "Hatchback", "Sedan"
|
CarEngine
|
Text
|
"A", "B"
|
CarTransmission
|
Text
|
"Manual", "HalfAutomatic", "Automatic"
|
Attribute Type = "CarType"
Attribute Type = "CarPackage"
Attribute Type = "CarFrame"
Attribute Type = "CarEngine"
Attribute Type = "CarTransmission"
Product Configuration Model
Attributes
Attribute Name
|
Attribute Type
|
Type
|
CarType
|
Package
|
CarPackage
|
Frame
|
CarFrame
|
Engine
|
CarEngine
|
Transmission
|
CarTransmission
|
User interface
Attribute Group
|
Attribute Name
|
Preferences
|
Type
|
Preferences
|
Package
|
Specifications
|
Frame
|
Specifications
|
Engine
|
Specifications
|
Transmission
|
To better organize configuration process all modeling variables will be
divided into 2 groups: Preferences and Specifications. Preferences will
represent client's initial requirements regarding Type of Car and
Package to be included. Specifications group will represent physical
characteristics of Car such as Frame, Engine and Transmission which will
be defined based on initial client's requirements.
Next step:
We will implement 2 options to illustrate Rules-based and
Constraints-based approach in order to structure knowledge base. Option 1
implements Rules-based approach and Option 2 implements
Constraints-based approach.
Option 1: Constraints (Rules base)
Using Rules-based approach all Rules can be represented as Expression
constraints in Dynamics AX 2012. Please see all Expression constraints
in relation to the original rule below
Rule 1: IF Package = "Deluxe" AND Frame = "Convertible" THEN Engine = "A"
Rule 2: IF Package = "Deluxe" AND Frame = "Hatchback" THEN Engine = "B"
Rule 3: IF Package = "Standard" AND Frame = "Convertible" THEN Engine = "A"
Rule 4: IF Engine = "A" THEN Transmission = "Manual"
Rule 5: IF Engine = "B" THEN Transmission = "Automatic"
Rule 6: IF Type = "Sport Car" THEN Frame = "Convertible"
Rule 7: IF Type = "Family Car" THEN Frame = "Sedan"
Rule 8: IF Type = "Sport Car" THEN Transmission = "Manual"
Option 1: Result
Please note that when you just open Configuration screen and you don't
have any particular selections for modeling variables yet, almost all selections for all modeling variables will be available
Type
|
Package
|
Frame
|
Engine
|
Transmission
|
The exceptions are Frame = "Hatchback" and Transmission =
"Half-automatic" which were filtered out because of lack of relevant
rules.
However when you specify client's requirements "Deluxe Sport Car" the
system will automatically filter out all inappropriate selections and
the final result will look like the following
Please note that after you have selected Type = "Sport Car" and Package
= "Deluxe" the only one selection for each modeling variable will
remain available based on existing rules
Type
|
Package
|
Frame
|
Engine
|
Transmission
|
Please note that every time you change selection for particular
modeling variable the system sends current configuration to Solver for
analysis and then adjusts selections for all related modeling variables
in real time. Red circle is your indication that particular selection for modeling variable is not available within current configuration.
Also please note that using Rules-based approach the system implements deduction
principle based on existing rules. For example, when you specify
Transmission = "Manual" the system will know that Engine = "A" based on
Rule 4
Rule 4: IF Engine = "A" THEN Transmission = "Manual" (forward chaining)
Type
|
Package
|
Frame
|
Engine
|
Transmission
|
And vice versa when you specify Engine = "A" the system will know that Transmission = "Manual" based on Rule 4
Rule 4*: IF Transmission = "Manual" THEN Engine = "A" (backward chaining)
Type
|
Package
|
Frame
|
Engine
|
Transmission
|
You can download XML file for Rules-based configuration (PC-AlexCar-Rules) here: https://skydrive.live.com/redir.aspx?cid=9c660ef56a3ba3f7&resid=9C660EF56A3BA3F7!110&parid=9C660EF56A3BA3F7!101&authkey=!ALJ3y9wD7_Ir8TE
Option 2: Table Constraints
In order to use Constraints-based approach we will have to represent
Rules differently by grouping them into 4 groups. Rules 1, 2 and 3 will
fall into 1st group which represents all valid combinations of Package, Frame and Engine. Rules 4 and 5 will form 2nd group which represents all valid combinations of Engine and Transmission. Rules 6 and 7 will be basis for 3rd group which represents all valid combinations of Type and Frame. And Rule 8 will represent 4th group with the only one valid combination of Type and Transmission defined at the moment.
Group 1: Package-Frame-Engine
Rule 1: IF Package = "Deluxe" AND Frame = "Convertible" THEN Engine = "A"
Rule 2: IF Package = "Deluxe" AND Frame = "Hatchback" THEN Engine = "B"
Rule 3: IF Package = "Standard" AND Frame = "Convertible" THEN Engine = "A"
|
|
Please note that I substituted Rules 1, 2 and 3 with Group 1 Table representing all valid combinations of Package-Frame-Engine
Group 2: Engine-Transmission
Rule 4: IF Engine = "A" THEN Transmission = "Manual"
Rule 5: IF Engine = "B" THEN Transmission = "Automatic"
|
|
Please note that I substituted Rules 4 and 5 with Group 2 Table representing all valid combinations of Engine-Transmission
Group 3: Type-Frame
Rule 6: IF Type = "Sport Car" THEN Frame = "Convertible"
Rule 7: IF Type = "Family Car" THEN Frame = "Sedan"
|
|
Please note that I substituted Rules 6 and 7 with Group 3 Table representing all valid combinations of Type-Frame
Group 4: Type-Transmission
Rule 8: IF Type = "Sport Car" THEN Transmission = "Manual"
|
|
Please note that I substituted Rule 8 with Group 4 Table representing valid combination of Type-Transmission
The
difference between Rules-based approach and Constraints-based approach
is that instead of expressing the rules in form of conditions and
conclusions (Rules-based approach) I'm expressing relations between
modeling variables and valid modeling variables value combinations
(Constraints-based approach).
Using Constraints-based approach all Rules can be represented as Table
constraints (User defined) in Dynamics AX 2012. Please see all Table
constraints in relation to the original rules group below
Group1: PackageFrameEngine
Group2: Engine-Transmission
Group3: Type-Frame
Group4: Type-Transmission
Option 2: Constraints (Constraints base)
After we set up Table constraints we can link them to our Product Configuration Model
For all Product Configuration Model Table constraints we have to define
the relation between Column name in the original Table constraint and
Product Configuration Model Attribute name.
Group1: Package-Frame-Engine
Group2: Engine-Transmission
Group3: Type-Frame
Group4: Type-Transmission
Option 2: Result
Please note that when you just open Configuration screen you have
particular selections for almost all modeling variables already in
place, this is because the system took into account valid combinations
of modeling variables specified in Table constraints. Moreover based on
current Table constraints the only 2 combinations of 5 modeling
variables are available. They are {Type = "Sport Car", Package = "Deluxe", Frame = "Convertible", Engine = "A", Transmission = "Manual"} and {Type = "Sport Car", Package = "Standard", Frame = "Convertible", Engine = "A", Transmission = "Manual"}.
Type
|
Package
|
Frame
|
Engine
|
Transmission
|
Let's explain why the only 2 combinations of 5 modeling variables are
available based on current Table constraints at the moment. In order to
explain this I will get back to 4 groups defined earlier which represent
knowledge base.
Group 1: Package-Frame-Engine
Package
|
Frame
|
Engine
|
Deluxe
|
Convertible
|
A
|
Deluxe
|
Hatchback
|
B
|
Standard
|
Convertible
|
A
|
Group 2: Engine-Transmission
Engine
|
Transmission
|
A
|
Manual
|
B
|
Automatic
|
Group 3: Type-Frame
Type
|
Frame
|
Sport Car
|
Convertible
|
Family Car
|
Sedan
|
Group 4: Type-Transmission
Type
|
Transmission
|
Sport Car
|
Manual
|
Please note that each Group represents valid combinations of modeling
variables. Please also note that certain modeling variables are used
multiple times in different groups which means that we can reduce number
of groups by combining them together and making sure that selections
of "shared" modeling variables in different groups will be the same as
we add a combination into new "super" group.
Iteration 1: Combine Group 1 and Group 2 into Group 1-2 by "shared" modeling variable "Engine"
Group 1-2: Package-Frame-Engine-Transmission
Package
|
Frame
|
Engine
|
Transmission
|
Deluxe
|
Convertible
|
A
|
Manual
|
Deluxe
|
Hatchback
|
B
|
Automatic
|
Standard
|
Convertible
|
A
|
Manual
|
Iteration 2: Combine Group 1-2 and Group 3 into Group 1-2-3 by "shared" modeling variable "Frame"
Group 1-2-3: Package-Frame-Engine-Transmission-Type
Package
|
Frame
|
Engine
|
Transmission
|
Type
|
Deluxe
|
Convertible
|
A
|
Manual
|
SportCar
|
Standard
|
Convertible
|
A
|
Manual
|
SportCar
|
Iteration 3: Combine Group 1-2-3 and Group 4 into Group 1-2-3-4 by "shared" modeling variables "Type" and "Transmission"
Group 1-2-3-4: Package-Frame-Engine-Transmission-Type
Package
|
Frame
|
Engine
|
Transmission
|
Type
|
Deluxe
|
Convertible
|
A
|
Manual
|
SportCar
|
Standard
|
Convertible
|
A
|
Manual
|
SportCar
|
Group 1-2-3-4 Table represents all valid combinations of 5 modeling variables
As
the result we have only 2 valid combinations of 5 modeling variables
which is exactly what was available on Configuration screen
You can download XML file for Constraints-based configuration (PC-AlexCar-Constraints) here: https://skydrive.live.com/redir.aspx?cid=9c660ef56a3ba3f7&resid=9C660EF56A3BA3F7!110&parid=9C660EF56A3BA3F7!101&authkey=!ALJ3y9wD7_Ir8TE
Summary:
Product Configurator is a very powerful solution which can be used in
Dynamics AX 2012 for configuring products and services. Product
Configurator allows you to implement Rules-based approach and
Constraints-based approach for Product Configuration Models. In similar
walkthrough I will also explain how Product Builder in Dynamics AX 2012
allows you to implement Rules-based approach and Constraints-based
approach for Product Models.
Author: Alex Anikiev, PhD, MCP
Tags: Dynamics ERP, Dynamics AX 2012, Solver Foundation, Product Configurator, Rules-based Configurator, Constraints-based Configurator.
Note:
This document is intended for information purposes only, presented as
it is with no warranties from the author. This document may be updated
with more content to better outline the concepts and describe the
examples.
PS: http://ax2012solveroptimization.blogspot.in/2012/03/dynamics-ax-2012-optimization-product.html



























































No comments:
Post a Comment