SlideShare a Scribd company logo
1 of 23
Download to read offline
Expressing Measurement Uncertainty
in OCL/UML Models
Toulouse, June 27, 2018
M. F. Bertoa1, N. Moreno1, G. Barquero1, L. Burgueño1, J.Troya2 and A. Vallecillo1
1 Atenea Research Group, Univ. Málaga, Spain
2 ISA Group, Univ. Sevilla, Spain
ECMFA 2018
Motivation
Uncertainty in Engineering Disciplines
 Engineers naturally think about:
 uncertainty associated with measured values
 Uncertainty is explicitly defined in their models
and considered in model-based simulations
2
Motivation
However the situation is not the same when modeled in software! 
3
Measurement Uncertainty in Software Models
Some Attempts 
context RectangleSw::area() : Real = h*w
4
Uncertainty in Software Engineering
 Very limited support for representing uncertainty in software models
 No support for considering such properties in model-based simulations
 Not part of their type systems!
Motivation
Measure
value : Real
What is the uncertainty of the
measurement method?
How is this uncertainty propagated when
making calculations with uncertain
values?
5
Abstraction vs Precision
“Being abstract is something profoundly different from being
vague... The purpose of abstraction is not to be vague, but to
create a new semantic level in which one can be absolutely
precise.”
Edsger Dijkstra
6
(Magnitudes and) Uncertainty Representation of Uncertainty
Definition: Standard Uncertainty [GUM]
 Uncertainty of the result of a measurement 𝑥𝑥 expressed as a standard
deviation 𝑢𝑢 of the possible variation of the values of 𝑥𝑥.
 Representation: 𝑥𝑥 ± 𝑢𝑢 or 𝑥𝑥, 𝑢𝑢
 Examples:
[GUM] JCGM 100:2008. Evaluation of measurement data – Guide to the expression of uncertainty in measurement.
http://www.bipm.org/utils/common/documents/jcgm/JCGM_100_2008_E.pdf
Normal distribution: (𝑥𝑥, 𝜎𝜎) with mean 𝑥𝑥, standard deviation 𝜎𝜎
Interval 𝑎𝑎, 𝑏𝑏 : Uniform or rectangular distribution is assumed
(𝑥𝑥, 𝑢𝑢) with 𝑥𝑥 =
𝑎𝑎+𝑏𝑏
2
, 𝑢𝑢 =
(𝑏𝑏−𝑎𝑎)
2 3
7
Measurement Uncertainty Operations
 Computations with uncertain values have to respect the propagation of
uncertainty (uncertainty analysis)
Two Methods for Computing Aggregated Uncertainty
 Normal or Uniform distribution: Analytical (closed-form) solutions
 General case: Using samples (SIPMath Std.)
A. Vallecillo, C. Morcillo, and P. Orue. Expressing Measurement Uncertainty in Software Models. In Proc. of
QUATIC 2016, pages 1–10, 2016.
8
Our proposal
 Extension of the OCL/UML
 Primitive types
 Collections
Ongoing
work
9
Our proposal
 Extension of the OCL/UML
 Primitive types
 extension based on subtyping
10
UReal
 UReal are pairs (x, u)
 x : Real represents the (expected, estimated or actual) value
 u : Real represents the uncertainty, expressed as a standard deviation of the
possible variation of the values of 𝑥𝑥.
 Real numbers correspond to pairs (x, 0.0)
 Example:
(2.0, 0.3)
(2.5, 0.25)
11
UReal
 Constants
 UReal(3.0, 0.05), UReal (0.0, 0.0), UReal (-1.0, 0.003)
 Operations
 Arithmetic
 Trigonometric
 Comparisons
 Conversions
 …
 Examples (in OCL):
12
UReal - Operations
 Operations. Comparisons
 Should return probabilities, rather than crisp Boolean values
a=(2.0, 0.3)
b=(2.5, 0.25)
d=(1, 0.5)
c=(1, 0.75)
a<b  (true, 0.893)
a=b  (true, 0.106)
a>b  (true, 1.11∙10-16 )
c<d  (true, 0.152)
c=d  (true, 0.754)
c>d  (true, 0.094) 13
UInteger and UUnlimitedNatural
 UInteger
 Pairs (n, u)
 n : Integer represents the (expected, estimated or actual) value
 u : Real represents the uncertainty, expressed as a standard deviation of the possible
variation of the values of n.
 Integer numbers correspond to pairs (n, 0.0)
 UInteger operations
 Behavior defined by lifting the operation to UInteger and then projecting the result if
needed
 UUnlimitedNatural
 non-negative Integer or a special unlimited value (*)
 (n, u) where n:Integer, u:Real, n≥0
 The uncertainty of * is always 0.0
 Operations not involving special value * are defined by lifting them to UInteger
 Comparison operations need to consider the particular case of special value *,
lifting the operation to the supertype if this value is not involved
14
UBoolean
 UBooleans are pairs (b, c)
 where b:Boolean and c:Real, c ϵ [0, 1]
 c represents the confidence that the actual value of the value is indeed b
 Canonical form: (true, c)
 Equivalence relation: (b, c) = (not b, 1 - c)
 Constants
 UBoolean(true, 0.999), UBoolean(false, 0.001)
 Operations
 Redefined basic operations: and, or, not
 Redefined secondary operations: implies, equivalent, xor
 Kept equals (=) and distinct (<>) w/o uncertainty and,
 Added operations uEquals():UBoolean and uDistinct():UBoolean
 Conversion operations: toBoolean() and toBooleanC(c:Real)
15
UBoolean
 Operations
 Two implementations:
 Assuming all values are independents: Analytical specification:
 When no assumption can be made about the independence: Monte-Carlo simulation
method:
16
Collections
 Extension based on the extended operators for the primitive datatypes
 uForAll(), uExists(), uIncludes(), uExcludes(), uSelect(), …
 Examples:
17
Trains
* Note that in the implementation in USE the uncertain types are included as basic primitive data types, as well as their native operations
Trains
 Train arrival time: T = 44.560 ± 10.581
 User arrival time: M= 40.045 ± 5.704
 Their diference: T-M = 4.515 ± 12.374
 M + 3 <= T  (true; 0.887)
 The probability that the user catches the train is 0.887
19
MARTE and SysML
 Compatibility problems when combining MARTE and SysML models
NOTE: Of course, simulation tools (Modelica, Matlab/Simulink) and mathematic languages (Mathematica) provide
support for units, dimensions and uncertainty, but they are at a different abstraction level
 MARTE has stereotypes to decorate values with information
about the units and with measurement uncertainty
(“precision”)
 However:
 It is simply “decorative information”: no type checking, no
operations for aggregating uncertainty values
 SysML 1.4 provides the QUDV (Quantities, Units,
Dimensions) and ISO 80000 library with all units and
dimensions.
 However:
 No support for dealing with measurement uncertainty
20
Conclusions and future work
 Extension of OCL/UML datatypes to capture and manipulate properties of physical
systems, in particular measurement uncertainty
 Implementations available for Java and USE
21
Conclusions and future work
 Extension of OCL/UML datatypes to capture and manipulate properties of
physical systems, in particular measurement uncertainty
 Implementations available for Java and USE
 Ongoing and Future Work
 Cover the rest of the UML/OCL datatypes: String and Enum
 Mathematical properties
 Mappings from our specifications to simulation languages (Modelica, Simulink)
 Further validation of our proposal:
 case studies
 expressiveness
 applicability
22
Expressing Measurement Uncertainty
in OCL/UML Models
Toulouse, June 27, 2018
M. F. Bertoa1, N. Moreno1, G. Barquero1, L. Burgueño1, J.Troya2 and A. Vallecillo1
1 Atenea Research Group, Univ. Málaga, Spain,
2 ISA Group, Univ. Sevilla, Spain
ECMFA 2018
Thanks!

More Related Content

Recently uploaded

APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSAPPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSKurinjimalarL3
 
GDSC ASEB Gen AI study jams presentation
GDSC ASEB Gen AI study jams presentationGDSC ASEB Gen AI study jams presentation
GDSC ASEB Gen AI study jams presentationGDSCAESB
 
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptxDecoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptxJoão Esperancinha
 
VICTOR MAESTRE RAMIREZ - Planetary Defender on NASA's Double Asteroid Redirec...
VICTOR MAESTRE RAMIREZ - Planetary Defender on NASA's Double Asteroid Redirec...VICTOR MAESTRE RAMIREZ - Planetary Defender on NASA's Double Asteroid Redirec...
VICTOR MAESTRE RAMIREZ - Planetary Defender on NASA's Double Asteroid Redirec...VICTOR MAESTRE RAMIREZ
 
chaitra-1.pptx fake news detection using machine learning
chaitra-1.pptx  fake news detection using machine learningchaitra-1.pptx  fake news detection using machine learning
chaitra-1.pptx fake news detection using machine learningmisbanausheenparvam
 
Biology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxBiology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxDeepakSakkari2
 
HARMONY IN THE HUMAN BEING - Unit-II UHV-2
HARMONY IN THE HUMAN BEING - Unit-II UHV-2HARMONY IN THE HUMAN BEING - Unit-II UHV-2
HARMONY IN THE HUMAN BEING - Unit-II UHV-2RajaP95
 
Call Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call GirlsCall Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call Girlsssuser7cb4ff
 
Artificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptxArtificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptxbritheesh05
 
power system scada applications and uses
power system scada applications and usespower system scada applications and uses
power system scada applications and usesDevarapalliHaritha
 
Call Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile serviceCall Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile servicerehmti665
 
SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )Tsuyoshi Horigome
 
Past, Present and Future of Generative AI
Past, Present and Future of Generative AIPast, Present and Future of Generative AI
Past, Present and Future of Generative AIabhishek36461
 
microprocessor 8085 and its interfacing
microprocessor 8085  and its interfacingmicroprocessor 8085  and its interfacing
microprocessor 8085 and its interfacingjaychoudhary37
 
IVE Industry Focused Event - Defence Sector 2024
IVE Industry Focused Event - Defence Sector 2024IVE Industry Focused Event - Defence Sector 2024
IVE Industry Focused Event - Defence Sector 2024Mark Billinghurst
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130Suhani Kapoor
 
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCollege Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCall Girls in Nagpur High Profile
 

Recently uploaded (20)

APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSAPPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
 
GDSC ASEB Gen AI study jams presentation
GDSC ASEB Gen AI study jams presentationGDSC ASEB Gen AI study jams presentation
GDSC ASEB Gen AI study jams presentation
 
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptxDecoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
 
VICTOR MAESTRE RAMIREZ - Planetary Defender on NASA's Double Asteroid Redirec...
VICTOR MAESTRE RAMIREZ - Planetary Defender on NASA's Double Asteroid Redirec...VICTOR MAESTRE RAMIREZ - Planetary Defender on NASA's Double Asteroid Redirec...
VICTOR MAESTRE RAMIREZ - Planetary Defender on NASA's Double Asteroid Redirec...
 
chaitra-1.pptx fake news detection using machine learning
chaitra-1.pptx  fake news detection using machine learningchaitra-1.pptx  fake news detection using machine learning
chaitra-1.pptx fake news detection using machine learning
 
Biology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxBiology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptx
 
young call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Service
young call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Serviceyoung call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Service
young call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Service
 
HARMONY IN THE HUMAN BEING - Unit-II UHV-2
HARMONY IN THE HUMAN BEING - Unit-II UHV-2HARMONY IN THE HUMAN BEING - Unit-II UHV-2
HARMONY IN THE HUMAN BEING - Unit-II UHV-2
 
Call Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call GirlsCall Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call Girls
 
Artificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptxArtificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptx
 
power system scada applications and uses
power system scada applications and usespower system scada applications and uses
power system scada applications and uses
 
Call Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile serviceCall Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile service
 
SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )
 
Past, Present and Future of Generative AI
Past, Present and Future of Generative AIPast, Present and Future of Generative AI
Past, Present and Future of Generative AI
 
🔝9953056974🔝!!-YOUNG call girls in Rajendra Nagar Escort rvice Shot 2000 nigh...
🔝9953056974🔝!!-YOUNG call girls in Rajendra Nagar Escort rvice Shot 2000 nigh...🔝9953056974🔝!!-YOUNG call girls in Rajendra Nagar Escort rvice Shot 2000 nigh...
🔝9953056974🔝!!-YOUNG call girls in Rajendra Nagar Escort rvice Shot 2000 nigh...
 
microprocessor 8085 and its interfacing
microprocessor 8085  and its interfacingmicroprocessor 8085  and its interfacing
microprocessor 8085 and its interfacing
 
IVE Industry Focused Event - Defence Sector 2024
IVE Industry Focused Event - Defence Sector 2024IVE Industry Focused Event - Defence Sector 2024
IVE Industry Focused Event - Defence Sector 2024
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
 
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
 
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCollege Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
 

Featured

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by HubspotMarius Sescu
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTExpeed Software
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsPixeldarts
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthThinkNow
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfmarketingartwork
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 

Featured (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

Expressing Measurement Uncertainty in OCL/UML Models

  • 1. Expressing Measurement Uncertainty in OCL/UML Models Toulouse, June 27, 2018 M. F. Bertoa1, N. Moreno1, G. Barquero1, L. Burgueño1, J.Troya2 and A. Vallecillo1 1 Atenea Research Group, Univ. Málaga, Spain 2 ISA Group, Univ. Sevilla, Spain ECMFA 2018
  • 2. Motivation Uncertainty in Engineering Disciplines  Engineers naturally think about:  uncertainty associated with measured values  Uncertainty is explicitly defined in their models and considered in model-based simulations 2
  • 3. Motivation However the situation is not the same when modeled in software!  3
  • 4. Measurement Uncertainty in Software Models Some Attempts  context RectangleSw::area() : Real = h*w 4
  • 5. Uncertainty in Software Engineering  Very limited support for representing uncertainty in software models  No support for considering such properties in model-based simulations  Not part of their type systems! Motivation Measure value : Real What is the uncertainty of the measurement method? How is this uncertainty propagated when making calculations with uncertain values? 5
  • 6. Abstraction vs Precision “Being abstract is something profoundly different from being vague... The purpose of abstraction is not to be vague, but to create a new semantic level in which one can be absolutely precise.” Edsger Dijkstra 6
  • 7. (Magnitudes and) Uncertainty Representation of Uncertainty Definition: Standard Uncertainty [GUM]  Uncertainty of the result of a measurement 𝑥𝑥 expressed as a standard deviation 𝑢𝑢 of the possible variation of the values of 𝑥𝑥.  Representation: 𝑥𝑥 ± 𝑢𝑢 or 𝑥𝑥, 𝑢𝑢  Examples: [GUM] JCGM 100:2008. Evaluation of measurement data – Guide to the expression of uncertainty in measurement. http://www.bipm.org/utils/common/documents/jcgm/JCGM_100_2008_E.pdf Normal distribution: (𝑥𝑥, 𝜎𝜎) with mean 𝑥𝑥, standard deviation 𝜎𝜎 Interval 𝑎𝑎, 𝑏𝑏 : Uniform or rectangular distribution is assumed (𝑥𝑥, 𝑢𝑢) with 𝑥𝑥 = 𝑎𝑎+𝑏𝑏 2 , 𝑢𝑢 = (𝑏𝑏−𝑎𝑎) 2 3 7
  • 8. Measurement Uncertainty Operations  Computations with uncertain values have to respect the propagation of uncertainty (uncertainty analysis) Two Methods for Computing Aggregated Uncertainty  Normal or Uniform distribution: Analytical (closed-form) solutions  General case: Using samples (SIPMath Std.) A. Vallecillo, C. Morcillo, and P. Orue. Expressing Measurement Uncertainty in Software Models. In Proc. of QUATIC 2016, pages 1–10, 2016. 8
  • 9. Our proposal  Extension of the OCL/UML  Primitive types  Collections Ongoing work 9
  • 10. Our proposal  Extension of the OCL/UML  Primitive types  extension based on subtyping 10
  • 11. UReal  UReal are pairs (x, u)  x : Real represents the (expected, estimated or actual) value  u : Real represents the uncertainty, expressed as a standard deviation of the possible variation of the values of 𝑥𝑥.  Real numbers correspond to pairs (x, 0.0)  Example: (2.0, 0.3) (2.5, 0.25) 11
  • 12. UReal  Constants  UReal(3.0, 0.05), UReal (0.0, 0.0), UReal (-1.0, 0.003)  Operations  Arithmetic  Trigonometric  Comparisons  Conversions  …  Examples (in OCL): 12
  • 13. UReal - Operations  Operations. Comparisons  Should return probabilities, rather than crisp Boolean values a=(2.0, 0.3) b=(2.5, 0.25) d=(1, 0.5) c=(1, 0.75) a<b  (true, 0.893) a=b  (true, 0.106) a>b  (true, 1.11∙10-16 ) c<d  (true, 0.152) c=d  (true, 0.754) c>d  (true, 0.094) 13
  • 14. UInteger and UUnlimitedNatural  UInteger  Pairs (n, u)  n : Integer represents the (expected, estimated or actual) value  u : Real represents the uncertainty, expressed as a standard deviation of the possible variation of the values of n.  Integer numbers correspond to pairs (n, 0.0)  UInteger operations  Behavior defined by lifting the operation to UInteger and then projecting the result if needed  UUnlimitedNatural  non-negative Integer or a special unlimited value (*)  (n, u) where n:Integer, u:Real, n≥0  The uncertainty of * is always 0.0  Operations not involving special value * are defined by lifting them to UInteger  Comparison operations need to consider the particular case of special value *, lifting the operation to the supertype if this value is not involved 14
  • 15. UBoolean  UBooleans are pairs (b, c)  where b:Boolean and c:Real, c ϵ [0, 1]  c represents the confidence that the actual value of the value is indeed b  Canonical form: (true, c)  Equivalence relation: (b, c) = (not b, 1 - c)  Constants  UBoolean(true, 0.999), UBoolean(false, 0.001)  Operations  Redefined basic operations: and, or, not  Redefined secondary operations: implies, equivalent, xor  Kept equals (=) and distinct (<>) w/o uncertainty and,  Added operations uEquals():UBoolean and uDistinct():UBoolean  Conversion operations: toBoolean() and toBooleanC(c:Real) 15
  • 16. UBoolean  Operations  Two implementations:  Assuming all values are independents: Analytical specification:  When no assumption can be made about the independence: Monte-Carlo simulation method: 16
  • 17. Collections  Extension based on the extended operators for the primitive datatypes  uForAll(), uExists(), uIncludes(), uExcludes(), uSelect(), …  Examples: 17
  • 18. Trains * Note that in the implementation in USE the uncertain types are included as basic primitive data types, as well as their native operations
  • 19. Trains  Train arrival time: T = 44.560 ± 10.581  User arrival time: M= 40.045 ± 5.704  Their diference: T-M = 4.515 ± 12.374  M + 3 <= T  (true; 0.887)  The probability that the user catches the train is 0.887 19
  • 20. MARTE and SysML  Compatibility problems when combining MARTE and SysML models NOTE: Of course, simulation tools (Modelica, Matlab/Simulink) and mathematic languages (Mathematica) provide support for units, dimensions and uncertainty, but they are at a different abstraction level  MARTE has stereotypes to decorate values with information about the units and with measurement uncertainty (“precision”)  However:  It is simply “decorative information”: no type checking, no operations for aggregating uncertainty values  SysML 1.4 provides the QUDV (Quantities, Units, Dimensions) and ISO 80000 library with all units and dimensions.  However:  No support for dealing with measurement uncertainty 20
  • 21. Conclusions and future work  Extension of OCL/UML datatypes to capture and manipulate properties of physical systems, in particular measurement uncertainty  Implementations available for Java and USE 21
  • 22. Conclusions and future work  Extension of OCL/UML datatypes to capture and manipulate properties of physical systems, in particular measurement uncertainty  Implementations available for Java and USE  Ongoing and Future Work  Cover the rest of the UML/OCL datatypes: String and Enum  Mathematical properties  Mappings from our specifications to simulation languages (Modelica, Simulink)  Further validation of our proposal:  case studies  expressiveness  applicability 22
  • 23. Expressing Measurement Uncertainty in OCL/UML Models Toulouse, June 27, 2018 M. F. Bertoa1, N. Moreno1, G. Barquero1, L. Burgueño1, J.Troya2 and A. Vallecillo1 1 Atenea Research Group, Univ. Málaga, Spain, 2 ISA Group, Univ. Sevilla, Spain ECMFA 2018 Thanks!