Automated verifjcation of rules and regulations in CAD models of - - PowerPoint PPT Presentation
Automated verifjcation of rules and regulations in CAD models of - - PowerPoint PPT Presentation
Automated verifjcation of rules and regulations in CAD models of railway signalling and interlocking Bjrnar Luteberget and Claus Feyling 15th International Conference on Railway Engineering Design and Operation July 21, 2016 1 / 24 Talk
Talk outline
- 1. Background and motivation
- 2. Semantic CAD using railML
- 3. Knowledge base design for verifjcation
- 4. Prototype tool integrating this verifjcation into existing
engineering tools (RailCOMPLETE)
2 / 24
Designing signalling and interlocking
◮ Constructing new railway lines or improving existing ones
requires through planning to meet quality demands
◮ Computer-aided design (CAD) tools are widely used for
producing documentation
◮ Creating a good design takes much skill and effort 3 / 24
Technical regulations
◮ In our case study: Norwegian regulations from
infrastructure manager Jernbaneverket
4 / 24
Technical regulations
Example from regulations:
◮ A home main signal shall be placed at least 200 m in front
- f the fjrst controlled, facing switch in the entry train path.
200 m ◮ Many regulations fall into one or more of the following
categories:
– Object properties – Topological layout properties – Geometrical layout properties – Interlocking specifjcation properties
5 / 24
Objective
Given a railway signalling and interlocking design, verify that it complies with regulations. Secondary objectives:
◮ Integrate with engineering/design tools
– On-the-fmy verifjcation (“lightweight”) – Usable for engineers who are not formal methods experts
◮ Find suitable language for expressing regulations 6 / 24
Talk outline
- 1. Background and motivation
- 2. Semantic CAD using railML
- 3. Knowledge base design for verifjcation
- 4. Prototype tool integrating this verifjcation into existing
engineering tools (RailCOMPLETE)
7 / 24
The railML XML standard data exchange format
◮ Thoroughly modelled infrastructure schema ◮ First presented by Nash et al. at COMPRAIL 2004 ◮ Development by international standard committee 8 / 24
Embedding railML in CAD: “semantic CAD”
◮ Extending CAD objects with additional information gives
railway-technical meaning to the symbols
CAD document Model space Polyline (geometry corresponding to track horizon- tal geometry) Block reference (symbol for sig- nalling equipment) ... Extension dictionary Extension dictionary ... Complete railML document railML fragment railML fragment ...
9 / 24
CAD verifjcation tool and tool chain
◮ Also, the structured data can be re-used for many other
purposes, notably data exchange with other tools:
– Interlocking code generation and verifjcation – Capacity simulation – 3D view, Building Information Modeling
◮ This leads us to the tool chain overview... 10 / 24
Tool chain overview
CAD program (design stage) CAD document (station layout) Verification issues GUI Shapes and symbols w/ attached railML fragments Interlocking specification Complete railML document Verification program User decision Issue description (rule,
- bjects, locations)
Machine- readable layout and specifications Interlocking code generation (Prover) Code verification Capacity analysis (OpenTrack, LUKS, Treno) Building Information Modeling (BIM) (Autodesk, Bentley, etc.) Export railML
◮ Static verifjcation can
discover violations of technical regulations early, as the user is building the model
◮ Dotted boxes indicate external
programs
◮ More heavy-weight
verifjcation, simulation, testing, etc. benefjts from machine-readable data exhcange
11 / 24
Talk outline
- 1. Background and motivation
- 2. Semantic CAD using railML
- 3. Knowledge base design for verifjcation
- 4. Prototype tool integrating this verifjcation into existing
engineering tools (RailCOMPLETE)
12 / 24
Formalization of regulations
◮ Formalize the following information
– The CAD design (extensional information, or facts) – The regulations (intensional information, or rules)
◮ Use a solver which:
– Is capable of expressing and verifying the regulations – Runs fast enough for on-the-fmy verifjcation
13 / 24
Datalog
◮ Basic Datalog: conjunctive queries with fjxed-point
- perators (“SQL with recursion”)
– Guaranteed termination – Polynomial running time (in the number of facts)
◮ Expressed as logic programs in a Prolog-like syntax:
a(X, Y ) :– b(X, Z), c(Z, Y )
- ∀x, y : ((∃z : (b(x, z) ∧ c(z, y))) → a(x, y))
◮ We also use:
– Stratifjed negation (negation-as-failure semantics) – Arithmetic (which is “unsafe”)
14 / 24
Encoding facts and rules in Datalog
◮ The process of formalizing the railway data and rules to
Datalog format is divided into three stages:
- 1. Railway designs (station data) – facts
- 2. Derived concepts (used in several rules) – rules
- 3. Technical regulations to be verifjed – rules
◮ Now, more details about each stage... 15 / 24
Derived concepts
◮ Derived concepts are defjned through intermediate rules ◮ Railway concepts defjned independently of the design ◮ Example: directlyConnected(a, b) ← ∃t : track(t) ∧ belongsTo(a, t) ∧ belongsTo(b, t), connected(a, b) ← directlyConnected(a, b) ∨ (∃c1, c2 : connection(c1, c2)∧ directlyConnected(a, c1) ∧ connected(c2, b)). ◮ A library of concepts allows concise expression of
technical regulations
16 / 24
Technical regulations as Datalog rules
◮ Detecting errors in the design corresponds to fjnding
- bjects involved in a regulation violation
◮ To validate the rules in a given design, we show that there
are no satisfjable instances of the negation of the rule
◮ An example:
– Home signal placement: topological and geometrical layout property for placement of a home signal
17 / 24
Rule example
◮ A home main signal shall be placed at least 200 m in front
- f the fjrst controlled, facing switch in the entry train path.
◮ Uses arithmetic and negation 200 m isFirstFacingSwitch(b, s) ← stationBoundary(b) ∧ facingSwitch(s)∧ ¬(∃x : facingSwitch(x) ∧ between(b, x, s)), ruleViolation(b, s) ← isFirstFacingSwitch(b, s)∧ (¬(∃x : signalFunction(x, home) ∧ between(b, x, s))∨ (∃x, d, l : signalFunction(x, home)∧ ∧ distance(x, s, d, l) ∧ l < 200). 18 / 24
Talk outline
- 1. Background and motivation
- 2. Semantic CAD using railML
- 3. Knowledge base design for verifjcation
- 4. Prototype tool integrating this verifjcation into existing