<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>A Modular Safety Assurance Method considering Multi-Aspect Contracts during Cyber Physical System Design⋆</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Peter Battram</string-name>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Bernhard Kaiser</string-name>
          <email>bernhard.kaiser@berner-mattner.com</email>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Raphael Weber</string-name>
          <email>raphael.weber@offis.de</email>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Berner &amp; Mattner Systemtechnik GmbH Munich</institution>
          ,
          <country country="DE">Germany</country>
        </aff>
        <aff id="aff1">
          <label>1</label>
          <institution>OFFIS - Institute for Information Technology Oldenburg</institution>
          ,
          <country country="DE">Germany</country>
        </aff>
      </contrib-group>
      <fpage>185</fpage>
      <lpage>197</lpage>
      <abstract>
        <p>Designing safety-critical cyber physical systems (CPS) was and remains a challenging task. CPS engineers are supposed to design solutions that are easy to modify, reusable, satisfy certification authorities, meet safety goals, separate between concerns, etc. With these partly contradicting demands it sometimes is even impossible to find a viable CPS design. The idea using contract-based design methods has been around for over two decades and enables automating the (re-)validation of the specification of CPS against the surrounding system or operational environment. In this work we extend the notion of contracts by component and interface contracts and give ideas on how to integrate them in a modular safety assurance approach. The explicit separation between these two types of contracts also better reflects the separation of concerns and reduces the overall modeling effort. We evaluate our approach with an automotive E-Drive case study.</p>
      </abstract>
      <kwd-group>
        <kwd>cyber physical systems</kwd>
        <kwd>multi-aspect</kwd>
        <kwd>contract based design</kwd>
        <kwd>modular safety assurance</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>-</title>
      <p>When designing safety-critical cyber physical systems (CPS) we are dealing with
a very difficult challenge. For a CPS, being safe means that the designer of that
system must forsee everything that can lead to an unsafe situation. That being
said, the designer not only has to install certain counter-acting mechanisms,
increasing safety, he also must ensure that these mechanisms work correctly and
that they actually increase the safety of that CPS. More precisely formulated,
the designer of a safety-critical system has to guarantee its safety.
⋆ This work was supported by the Federal Ministry for Education and Research
(BMBF) under support code 01IS12005M
Copyright © 2015 by the authors. Copying permitted for private and academic purposes.
This volume is published and copyrighted by its editors.</p>
      <p>
        This fact is also mandatory when developing a system that has to be
compliant to safety standards like the ISO26262 [
        <xref ref-type="bibr" rid="ref8">8</xref>
        ] or the DO178c [
        <xref ref-type="bibr" rid="ref15">15</xref>
        ]. These standards
demand a safety case that evinces the absence of unreasonable risk for humans
caused by the system under development. A vital part of these safety cases is a
safety concept that depicts the architectural decisions concerning the fault
detection as well as the fault mitigation. Besides an increasing use of
componentsoff-the-shelf, the effective reaction to changes in the system design requires such
safety concepts to be modelled in a modular way. Therefore the modular safety
specification and analysis gain more and more importance.
      </p>
      <p>Aside from the problem of ensuring the safety of embedded systems, there
is another challenge in designing today’s CPS: The ever-growing complexity,
caused by the inclusion of yet another new feature, greatly impacting the rest
of the system. The last few decades saw tremendous effort to cope with this
complexity as well as safety issues.</p>
      <p>In order to master this complexity, we need to break it down to the essentials.
There are many formalisms to model different aspects of complex safety-critical
systems. One single formalism in isolation only represents a fraction of the
actual system under design. While some of these formalisms in isolation are well
understood, the combination of them turns out to be another challenge. The
combination of different modelling aspects allows for more realistic
representations of the actual embedded system. However, that also makes it harder to
analyze the systems to assure certain properties of interest.</p>
      <p>Safety requirements are fundamental artifacts in the specification of
safetycritical CPS, as they document how the hazards and failure of the system are
mitigated. They are produced by the hazard and safety analyses and may
therefore suffice in various viewpoints and levels of abstraction.
1.1</p>
    </sec>
    <sec id="sec-2">
      <title>Cyber Physical Systems and Contracts</title>
      <p>
        Embedded systems are small computing systems deeply embedded into their
surroundings such that their existence is barely noticed. Since most embedded
systems are small devices reacting on changes in their environment the notion
cyber physical systems was coined to emphasize the necessity to take the
environment into account during design [
        <xref ref-type="bibr" rid="ref9">9</xref>
        ]. CPS are also more networked due to
the complex interdependencies of the environmental properties that are to be
controlled by the CPS.
      </p>
      <p>
        The intended control behavior and corresponding safety properties of CPS
can be specified with various formalisms. In this regard, the use of
contractbased modeling has proven to be beneficial [
        <xref ref-type="bibr" rid="ref10">10</xref>
        ]. To cope with the complexity of
CPS, e. g. component-based design is applied during the development process.
But when components or sub-systems are abstracted by their interfaces, such
interfaces do not necessarily provide sufficient information for the correct and
safe implementation of the other components [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ]. Additional information about
the interface in form of assumptions about the context conditions the
component and the interface is needed. Contract-based design provides the concepts
to handle these aspects.
      </p>
      <p>Contracts represent a requirement in a structured way separating it into an
assumption, stating the expected properties of the environment, and a guarantee,
which describes the desired behavior of the component, provided the assumption
is met by the environment. The introduced separation is the foundation for
building a sound theory that allows the reasoning about the composition of
systems in a formal way. Additionally, it reflects the very idea of CPS to explicitly
consider the properties of the surrounding environment.</p>
      <p>In this work we provide a method to distinguish between two contract types
providing separation of concerns on the one hand and module decomposition
and reusability on the other hand. This method may be applied in different
domains allowing for the consideration of multiple aspects of CPS design and
specification. In the context of safety-critical CPS design we describe how to
integrate our proposed method into a modular safety assurance process.
1.2</p>
    </sec>
    <sec id="sec-3">
      <title>Related Work</title>
      <p>
        Using Contracts for better specification of critical systems and partly for
improving safety analysis and verifications is currently a flourishing research domain.
For example, Safety ADD (see [
        <xref ref-type="bibr" rid="ref17">17</xref>
        ]) helps to define and verify the safety
contracts for software components in a graphical editor. The algorithm traverses all
assumptions and guarantees to make sure they match.
      </p>
      <p>
        A tool for checking the refinement between contracts called OCRA
(Othello Contracts Refinement Analysis) was presented in [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ]. It provides means for
checking the contracts specified in a pattern based language called Othello which
are later translated to a linear-time temporal logic for discrete and real-time
constraints. The underlying engine allows to reason whether contract refinement is
correct.
      </p>
      <p>
        A full range of safety mechanisms, such as, definitions of faults and failures,
fault containment, safety mechanisms, handling the degradation modes and safe
states at multiple abstraction levels is proposed in [
        <xref ref-type="bibr" rid="ref11 ref12">11, 12</xref>
        ]. The interface between
the safety view and the functional design is highlighted as well. Multiple safety
patterns are provided in LTL [
        <xref ref-type="bibr" rid="ref13">13</xref>
        ] notation.
      </p>
      <p>
        Temporal logic is also used in [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ] for decomposing the system architecture
with contracts. The framework automatically generates a set of proves.
1.3
      </p>
    </sec>
    <sec id="sec-4">
      <title>Outline</title>
      <p>The paper is organized as follows: In Section 2 we give a basic overview over
contracts-based design. Section 3 details our approach to differ component and
interface contracts and how to apply them in a modular safety assurance process.
We evaluate this approach with an automotive E-Drive case-study in Section 4.
Finally, we conclude our paper in Section 5 and give an outlook.</p>
      <sec id="sec-4-1">
        <title>Fundamentals</title>
        <p>In this section we will give a brief overview over contract-based design (informal
and formal) and the pattern based RSL to specify contracts in a semantically
sound way. In Subsection 2.3 we give a formal definition of the validation
procedure that has to be performed in order to verify the correctness of contracts.
Note that this procedure may differ in necessary effort or difficulty for different
aspects.
2.1</p>
      </sec>
    </sec>
    <sec id="sec-5">
      <title>Contract-based Design</title>
      <p>Contracts are pairs consisting of an assumption (A) and a guarantee (G). The
assumption specifies how the context of the component, i. e. the environment from
the point of view of the component, should behave. Only if the assumption holds,
then the component will behave as guaranteed. This kind of specification allows
to replace components by more detailed ones, if they allow a less demanding
environment, without re-validating the whole system. Thus, the system
decomposition can be verified with respect to contracts without the knowledge of the
concrete implementation. In this work, we use the RSL to specify the assumption
and guarantee parts of contracts.</p>
      <p>Assumption: a occurs
each 50ms.</p>
      <p>Guarantee: Whenever
a occurs, b occurs
during [5ms,8ms].</p>
      <p>Assumption: a occurs
each 50ms.</p>
      <p>Guarantee: Whenever
a occurs, c occurs
during [10ms,14ms].</p>
      <p>Assumption: b occurs
each 50ms with jitter 8ms.</p>
      <p>Guarantee: Whenever b
occurs, c occurs during
[5ms,6ms].
a</p>
      <p>Subsystem A1</p>
      <p>b
System A</p>
      <p>Subsystem A2
c</p>
      <p>One advantage of using contracts is that they can help to decrease the
complexity of verifying the implementation against its specification. For example,
consider the system in Fig. 1, to which a contract is assigned. The system
contract states, that the input port ’a’ is triggered each 50ms, and when it is
triggered, the system has to respond by sending an event on port ’c’ within a specific
time interval. The system is decomposed into two subsystems each with one
contract, and some internal behavior modeled by, e. g. state machines. Assume that
the functionality on subsystem A2 depends on the output of subsystem A1.
Further, assume that the subsystems would not be annotated with contracts. Thus,
to validate the contract of the overall system A, the composed behavior of both
subsystems has to be computed, which generally leads to large state spaces.
Using contracts for A1 and A2, we can omit the composition and validate the
sub-contracts locally.</p>
      <p>Formally, the semantics of a contract is defined as
(1)
where (X)Cmpl defines the complement of a set X in some universe U , and [[X]] is
defined as the semantic interpretation of X. In our case, [[X]] is given in terms of
sets of timed traces. A trace over an alphabet Σ is a sequence of events. Further,
a time sequence τ is a monotonically increasing sequence of real values, such
that for each t ∈ R there exist some i ≥ 1 such that τi &gt; t. A timed trace is a
sequence (ρ,τ ) where ρ is a sequence of events and τ a time sequence. The set
of all timed traces over Σ is denoted by T r(Σ).</p>
      <p>The specification S of a component is given in terms of a set of contracts, i. e.
[[S]] := !n</p>
      <p>i=1[[Ci]]. An implementation I of a component satisfies its specification
S, if [[I]] ⊆ [[S]] holds. The refinement relation between two contracts C and C′
is defined as follows:</p>
      <p>C′ refines C, if [[A]] ⊆ [[A′]] and [[G′]] ⊆ [[G]],
(2)
2.2</p>
    </sec>
    <sec id="sec-6">
      <title>Requirements Specification Language</title>
      <p>
        Natural language requirements are often accompanied by ambiguity,
incompleteness or inconsistency; the reason for this resides in the very nature of a spoken
language. These unintended byproducts may not be detected until late phases of
the development process and therefore cause the realization to not fulfill the
intended goals of the specification or cause incompatibilities to other system parts.
A solution to this problem would be the use of formal languages to specify the
requirements. But these are often hard to understand and therefore difficult to use.
An alternative that bridges this gap is the pattern-based Requirements
Specification Language (RSL) [
        <xref ref-type="bibr" rid="ref1 ref14">14, 1</xref>
        ]. This formal language provides a fixed semantic
that enables an automated validation or verification but is still well readable
compared to natural language.
      </p>
      <p>Consisting of static text elements and attributes which are filled in by a
requirements engineer, patterns have a well-defined semantic so that a consistent
interpretation of the system specification between all stakeholders can be
ensured. To cope with the needs of the different aspects of a design, various sets
of patterns have been defined which are partly described in the following.
2.3</p>
    </sec>
    <sec id="sec-7">
      <title>Validation of Contracts</title>
      <p>When a component is decomposed into a set of sub-components, we have to
check whether the overall contract C = (A, G) (which also will be called global
contract) and all subcontracts Ci = (Ai, Gi) (also called local contracts) for
i ∈ {1, ..., n} are consistent. We have to check the following virtual integration
condition:
i) A ∧ G1 ∧ ... ∧ Gn ⇒</p>
      <p>A1 ∧ ... ∧ An
ii) A ∧ G1 ∧ ... ∧ Gn ⇒</p>
      <p>G.</p>
      <p>
        (3)
An in-depth discussion about virtual integration can be found in [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ]. In [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ]
contracts were extended by so called weak assumptions. Weak assumptions
are used to describe a set of possible environments in which the component
guarantees different behaviors. This separation is only methodological, and
does not affect the semantics of the definition of the original contracts: Let
C = (As, Aw1 , ..., Awn , G1, ..., Gn) be a contract consisting of a strong
assumption As, a set of weak assumptions Awi , and a set of corresponding
guarantees Gi for i ∈ N. Semantically, we map C to a standard contract of the form
C′ = (As, G), where G = (G′1 ∧ ... ∧ G′n) G′i = (Awi ⇒ Gi). For timing and
a special subset of safety properties the validation has already been done [
        <xref ref-type="bibr" rid="ref6 ref7">6, 7</xref>
        ].
For other aspects this may, however, be more difficult which is one reason to also
consider a methodological approach. We propose the methodological separation
between component and interface contracts described in the following section.
3
      </p>
      <sec id="sec-7-1">
        <title>Multi-Aspect Modular Safety Assurance</title>
        <p>This section gives informal definitions of component and interface contracts.
Furthermore, we describe how to transform them into each other and how to
integrate them into a modular safety assurance process. The term multi-aspect
thereby refers to the possibility to specify required properties concerning multiple
views on the CPS (e. g. signal quality, timing, or reliability).
3.1</p>
      </sec>
    </sec>
    <sec id="sec-8">
      <title>Component Contracts</title>
      <p>In contract-based design, contracts are used to systematically derive and
document requirements and to conduct contract validation on the systems
architecture. Such validation can serve as evidence for the correct allocation of functions
which in turn constitute the overall function of a system, i. e. the allocation of the
functions to a given CPS architecture and environment is correct and provably
valid.</p>
      <p>
        Component contracts are contracts between any system of consideration and
its operational context. Therefore, they are a key artifact in order to make
requirements allocated to a component modular and reusable, and to make
formerly tacit assumptions explicit. In the context of safety, contract-based
specifications aim at reasoning about the fault containment properties of components
in a modular, reusable way [
        <xref ref-type="bibr" rid="ref12">12</xref>
        ].
      </p>
      <p>Fig. 2 depicts an excerpt of the architecture of an E-Drive system (more
details in Section 4) and two exemplary contracts linked to the Microcontroller
component. The functional contract e. g. states that under the assumption that
the components power supply is sufficient and the temperature of the
components environment is suitable, the component will start the calculation of the
pWM signal within 5 milliseconds after the acceleration pedal has been pressed.
A safety contract, focusing on failure propagation, states that the outputs of the
Microcontroller component (shutOffSignal and pWM) will not fail, if the
components input (phaseCurrentValue) or the component itself do not fail. These
contracts are represented in a formal way using the predefined RSL (see
Section 2.2).</p>
      <sec id="sec-8-1">
        <title>Functional Contract</title>
        <p>Assumption:
Always (Power = 12 V AND
Temp_Env &lt; 90°).</p>
        <p>Guarantee:
Whenever accelPedalPressed
occurs, microControllerPWMCalc
occurs within 5 ms.</p>
        <p>Phase Current</p>
        <p>Sensors
phaseCurrent</p>
        <p>Value</p>
        <p>Microcontroller
E-Drive</p>
      </sec>
      <sec id="sec-8-2">
        <title>Safety Contract</title>
        <p>Assumption:
None of {{phaseCurrentValue_fail},
{MicroController_internal_fail}}
occurs.</p>
        <p>Guarantee:
None of {{shutOffSignal_fail,
PWM_fail}} occurs.
The relationship between assumptions of specific component to guarantees of its
neighbors (and vice versa) can be defined by an interface contract. The
difference to component contracts is mainly that assumptions refer to signal qualities
provided at input ports of a component and promises refer to signal qualities
provided at the output ports of the neighbor components. Interface contracts
and component contracts can be transformed into each other canonically.</p>
        <p>
          An interface contract is a combination or a pair consisting of an assumption
and a guarantee attached to the interfaces. Each contract is negotiated between
two respective neighbor components. Assumptions and guarantees may refer to
signal characteristics at a given port, as seen by an omniscient external observer,
e. g. the accuracy of a signal with respect to the real physical quantity, the
integrity of a signal, the delay of a port signal with respect to an event in the
outside world. It is obvious that some reusable component, taken out of its
environment, shall not refer to such context knowledge that is not directly related to
quantities observable at its direct interfaces - therefore the modularization to its
full extent is only achieved by later transforming interface contracts into
component contracts. Yet, interface contracts help verifying the architecture when
decomposing the system, because it can easily be checked along the signal flow
links whether or not the assumptions at the input of some component are fulfilled
by the guarantees at the linked output of its predecessor component. Unfulfilled
contracts, i. e. assumptions that are not satisfied by corresponding guarantees,
can be detected and highlighted automatically, which has been demonstrated by
a prototype tool in [
          <xref ref-type="bibr" rid="ref16">16</xref>
          ]. Fig. 3 illustrates the concept of the interface contract.
        </p>
        <p>Ci-1
Guarantee:
output.imprecision&lt;10mA</p>
        <p>Super Component</p>
        <p>Ci</p>
        <p>Ci+1
Assumption:
input.imprecision&lt;30Nm</p>
        <p>Assumption:
Contract input.imprecision&lt;10mA</p>
        <p>
          Guarantee:
output.imprecision&lt;20Nm Contract
In order to use both types of contracts during the design of CPS, we propose
the following steps:
1. Let S be some CPS to be developed with its external interfaces, some
requirements (e. g. some signal to be provided with a required accuracy and
safety integrity, or an event to be triggered with a specified maximum delay
counted upon some internal condition, e. g. some failure condition) and some
assumptions about its environment. The job at hand is to decompose the
requirements and to allocate them onto the designated (sub-)components of
the system, thereby verifying that the refinement is correct.
2. The requirements engineer specifies the informal (textual) requirements
formally, or at least in a semi-formal notation, which allows to specify the target
properties unambiguously. A parametrized template language (like the RSL)
may be a semi-formal way to do so, temporal logics like LTL [
          <xref ref-type="bibr" rid="ref13">13</xref>
          ] may be
formal notations that are suitable. Thereby, the requirements to the system
are stated as guarantees that the system must fulfill, while it can rely on
assumptions, which are the formalized assumptions about the technical
usage environment. These assumptions and guarantees constitute a component
contract with the system to be developed being the subject component.
3. The architect decomposes the system into components, specifying their
purposes and their interfaces at which (intermediate) signals are provided. Each
signal gets some meaning assigned and all signals are listed in a signal
dictionary. The architect states his ideas about how to decompose the requirements
into sub-requirement and how to assign the budgets on quality properties
(such as timing, accuracy, safety integrity) among the components. He does
so by tentatively specifying assertions that are meant to hold at different
“probing points” (signals) in the architecture.
4. The assertions can be interpreted as interface contracts as follows: The
output of the component upstream in the signal flow must guarantee the
properties at the given point, whereas the input of the component downstream
in the signal flow may rely on the property as being granted, i. e. this is
an assumption. Interface contracts are made between neighbor components.
Where an input comes directly from an input port of the surrounding
system or an output direct feeds an output port of the surrounding system, the
stated assertions are propagated one level up in the system hierarchy (or
matched with the systems assumptions and guarantees, when we are on the
top level of the hierarchy).
5. The interface contracts are not yet suitable for specifying the
sub-components as standalone components with the potential of being designed from
some external supplier who does not know about the rest of the system. This
is due to the fact that the assertions were stated from the architects point
of view (who is in the position of an omniscient observer, which is obviously
not true for the component supplier). For instance, the manufacturer of a
car airbag controller cannot guarantee that the airbag inflates at max 100
microseconds after the crash occurs, simply because he has no knowledge
about the crash occurrence. All he knows is the signal at the input port
of his own component, provided for example by some sensor subsystem,
and therefore all requirements must refer to this behavior at the ports. The
solution to this challenge is to transfer the interface contracts into component
contracts, which is a canonical step (i. e. can be fully automated).
6. The resulting component contracts only consist of propositions that refer to
the observable behavior at the outer interface of the component of interest.
Therefore, the guarantees that the component will have to fulfill can be
transferred into requirements to the component (if the supplier is unfamiliar
with the specific formal notation, a pattern generator could be used to create
boilerplate language in English or any other natural language out of it). The
other way around, the assumptions granted to the component can also be
exported to the supplier and give him some certainty about properties of the
usage environment he can rely on when designing the component.
3.4
        </p>
      </sec>
    </sec>
    <sec id="sec-9">
      <title>Integration into a Modular Safety Assurance Method</title>
      <p>For the usage of component and interface contracts in an integrated safety
process, we propose a three-step approach:
– During conventional system design, functional requirements are analyzed
and an initial system architecture is derived from these requirements. The
architectural view allows for specifying system contracts, which cover in
this step the decomposition and verification of the nominal behavior of the
system. The system architecture is hence enriched by functional contracts.
– The next step in the system engineering process is the safety analysis. The
purpose of this analysis is to find failures, i. e. component behavior observable
at the component interfaces that violates the specification of the nominal
behavior and that might lead, if not handled appropriately, to some hazard
or accident. The contracts defined in the previous step formalize the nominal
behavior of the system, which aids in finding deviations. This means, that the
failure mode definitions needed to aggregate different types of safety analysis,
can be interpreted as contract violations: If, for instance, an output interface
of some sensor component provides the value for a measured temperature
and an interface contract promises for this output an accuracy of ±2◦C,
then every value actually provided at the output which deviates from the
true value by more than 2◦C is obviously considered as failure of the sensor
component (to be precise, corresponding to failure modes “too high” or “too
low” respectively, when applying the failure mode keywords known from the
HAZOP analysis technique). The existing functional contracts together with
the architecture design and the results of safety analysis serve as a basis to
define safety contracts and thereby derive the functional safety requirements.
– The final step in the safety process is to create the technical safety concept.</p>
      <p>The systems architectural view is now updated to include additional safety
components and mechanisms in addition to the system design, which may
become necessary to detect and mitigate the identified component failures,
or to achieve the required safety integrity level. To these new components,
but also to the existing ones, additional contracts can be assigned, this time
relating to safety properties. Examples for those properties can be promises
for safety-relevant properties that hold with a defined safety integrity level
or a minimum guaranteed probability, or the guarantee that despite certain
failures at a component input, there will be no failures at its output (e. g.
Assumption: Input can be any well-formed bus message; Guarantee: Output
is an integer software variable either corresponding to the value transmitted
by the bus message or the accompanying Boolean valid flag being set to
FALSE.) Transforming such kind of safety-related interface contracts into
component contracts leads to the formulation of the related technical safety
requirements. As a result, the system architecture showing the nominal
behavior design is enriched towards the final system safety architecture.
4</p>
      <sec id="sec-9-1">
        <title>E-Drive Case Study</title>
        <p>
          We evaluated our approach by applying the component and interface contract
modeling to an automotive E-Drive case study that has been introduced in [
          <xref ref-type="bibr" rid="ref16">16</xref>
          ].
An E-Drive is a system responsible for actuating a vehicle. It consists of an
electric machine, a controller and power electronics. An excerpt of the E-Drive
system architecture is depicted in Fig. 4. This case study qualifies for the
evaluation of our approach, because of its safety-critical properties and its modular
character, meaning that an E-Drive could for example replace a conventional
combustion engine in the future.
        </p>
        <p>Besides the architecture of the E-Drive, Fig. 4 also shows interface contracts
(located on the left and right hand side above the architecture) as well as a
component contract for the Microcontroller component (located in the center
above the architecture).</p>
        <p>Assumption:
Microcontroller.
phaseCurrentValue.</p>
        <p>imprecision 1mA</p>
        <p>Contract
Guarantee:
PhaseCurrentSensors.
phaseCurrentValue.
imprecision 1mA</p>
        <p>Phase
CurrentSensors
E-Drive</p>
        <p>Assumption:
Temp_Env 90°
Guarantee:
Microcontroller.phaseCurrentValue.
imprecision 1mA =&gt;
Microcontroller.shutOffSignal.
occurenceTime 100ms.</p>
        <p>Microcontroller
phaseCurrent CurrentPlausibility</p>
        <p>Value Check</p>
        <p>TorqueController</p>
        <p>For this case study the interface contracts have been modeled along the signal
flow from the Phase Current Sensors via the Microcontroller to the Emergency
Shut-Off component. They specifically state which condition the signal property
does fulfill or has to fulfill like for example the guarantee of the Phase Current
Sensors output. This guarantee states that the imprecision of the phase current
value is not allowed to exceed one milliampere. Following the signal flow, the next
component to process the signal is the Microcontroller. This component itself has
requirements regarding the input signals, which are stated as an assumption. In
this case the component also demands the phase current value’s imprecisions to
not exceed one milliampere. This pair of guarantee and assumption constitutes
an interface contract between the two components regarding the phase current
value’s imprecisions.</p>
        <p>The same procedure was performed for the shut-off signal sent from the
Microcontroller to the Emergency Shut-Off component (right hand side of Fig. 4).
For this case, analyses like a compatibility check can be performed. Applying
this kind of analysis to our case study showed that the compatibility between
the components along this signal flow was given.</p>
        <p>In the next process step the interface contracts were used to derive the
component contracts for the components of the E-Drive system. The result, the
component contract for the Microcontroller is depicted in the top center of Fig. 4.
As can be seen the guarantee was derived by the previously defined assumption
and guarantee of the Microcontroller, stating that if the left hand side of the
implication is fulfilled, the right hand side can be guaranteed. The assumption in
the example was added to state that the Microcontroller can just guarantee its
correct functionality for an environmental temperature not exceeding 90◦Celsius.</p>
        <p>The evaluation of the approach showed that besides the fact that forcing the
engineer to capture requirements in a more structured and ultimately a more
formal way decreases the ambiguity of the specification. Interface as well as
component contracts enable analyses to validate the specification against the system
context or the operational environment. Additionally, these approaches support
a modular safety assessment by encapsulating the assumptions and guarantees
relevant for the component that shall be changed or replaced.
5</p>
      </sec>
      <sec id="sec-9-2">
        <title>Conclusion</title>
        <p>Coping with specifications for CPS and validating them is a regular task that
needs to be performed during system design. This paper described a new method
to apply contract-based design in the context of a modular safety assurance
process. We therefore distinguished between component and interface contracts to
better support the system architect in validating the correctness of his design
(including the specification and the structural composition). We evaluated our
approach using an automotive E-Drive case-study which also showed an
improvement in the usability and applicability of contracts in general. Future work will
be conducted in the field of multi-aspect validation and verification of
inseparable properties of CPS. There are still a lot of design concerns that have not
yet been formalized or addressed at all. Optimizing one or more properties of
interest (e. g. reduce costs, maximize safety, . . . ) is another topic which we will
look into.</p>
      </sec>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          1.
          <string-name>
            <surname>Baumgart</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          , B¨ode, E., Bu¨ker,
          <string-name>
            <given-names>M.</given-names>
            ,
            <surname>Damm</surname>
          </string-name>
          ,
          <string-name>
            <given-names>W.</given-names>
            ,
            <surname>Ehmen</surname>
          </string-name>
          ,
          <string-name>
            <given-names>G.</given-names>
            ,
            <surname>Gezgin</surname>
          </string-name>
          ,
          <string-name>
            <given-names>T.</given-names>
            ,
            <surname>Henkler</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            ,
            <surname>Hungar</surname>
          </string-name>
          ,
          <string-name>
            <given-names>H.</given-names>
            ,
            <surname>Josko</surname>
          </string-name>
          ,
          <string-name>
            <given-names>B.</given-names>
            ,
            <surname>Oertel</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            ,
            <surname>Peikenkamp</surname>
          </string-name>
          ,
          <string-name>
            <given-names>T.</given-names>
            ,
            <surname>Reinkemeier</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            ,
            <surname>Stierand</surname>
          </string-name>
          ,
          <string-name>
            <given-names>I.</given-names>
            ,
            <surname>Weber</surname>
          </string-name>
          ,
          <string-name>
            <surname>R.</surname>
          </string-name>
          :
          <article-title>Architecture modeling</article-title>
          .
          <source>Tech. rep.</source>
          ,
          <source>OFFIS (March</source>
          <year>2011</year>
          ), http://ses.informatik.uni-oldenburg.de/download/bib/paper/OFFISTR2011_ArchitectureModeling.pdf
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          2.
          <string-name>
            <surname>Benveniste</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Caillaud</surname>
            ,
            <given-names>B.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Nickovic</surname>
            ,
            <given-names>D.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Passerone</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Raclet</surname>
            ,
            <given-names>J.B.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Reinkemeier</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Sangiovanni-Vincentelli</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Damm</surname>
            ,
            <given-names>W.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Henzinger</surname>
            ,
            <given-names>T.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Larsen</surname>
            ,
            <given-names>K.</given-names>
          </string-name>
          :
          <article-title>Contracts for systems design</article-title>
          . In: Inria Research (
          <year>2012</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          3.
          <string-name>
            <surname>Bozzano</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Cimatti</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Katoen</surname>
            ,
            <given-names>J.P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Nguyen</surname>
          </string-name>
          , V.Y.,
          <string-name>
            <surname>Noll</surname>
            ,
            <given-names>T.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Roveri</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          :
          <article-title>Safety, dependability and performance analysis of extended aadl models</article-title>
          .
          <source>Comput. J</source>
          .
          <volume>54</volume>
          (
          <issue>5</issue>
          ),
          <fpage>754</fpage>
          -
          <lpage>775</lpage>
          (May
          <year>2011</year>
          ), http://dx.doi.org/10.1093/comjnl/bxq024
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          4.
          <string-name>
            <surname>Cimatti</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Dorigatti</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Tonetta</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          :
          <article-title>Ocra: A tool for checking the refinement of temporal contracts</article-title>
          .
          <source>In: ASE IEEE</source>
          . pp.
          <fpage>702</fpage>
          -
          <lpage>705</lpage>
          (
          <year>2013</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          5.
          <string-name>
            <surname>Damm</surname>
            ,
            <given-names>W.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Hungar</surname>
            ,
            <given-names>H.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Josko</surname>
            ,
            <given-names>B.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Peikenkamp</surname>
            ,
            <given-names>T.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Stierand</surname>
            ,
            <given-names>I.</given-names>
          </string-name>
          :
          <article-title>Using contractbased component specifications for virtual integration testing and architecture design</article-title>
          .
          <source>In: DATE Exhibition</source>
          . pp.
          <fpage>1</fpage>
          -
          <lpage>6</lpage>
          (
          <year>2011</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          6.
          <string-name>
            <surname>Gezgin</surname>
            ,
            <given-names>T.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Weber</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Girod</surname>
            ,
            <given-names>M.:</given-names>
          </string-name>
          <article-title>A refinement checking technique for contractbased architecture designs</article-title>
          .
          <source>In: Fourth International Workshop on Model Based Architecting and Construction of Embedded Systems (10</source>
          <year>2011</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          7.
          <string-name>
            <surname>Gezgin</surname>
            ,
            <given-names>T.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Weber</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Oertel</surname>
            ,
            <given-names>M.:</given-names>
          </string-name>
          <article-title>Multi-aspect virtual integration approach for real-time and safety properties</article-title>
          . In: International Workshop on Design and
          <article-title>Implementation of Formal Tools and Systems (DIFTS14)</article-title>
          .
          <source>IEEE (Oct</source>
          <year>2014</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          8. ISO:
          <string-name>
            <surname>Road Vehicles - Functional Safety</surname>
          </string-name>
          .
          <source>International Standard Organization (November</source>
          <year>2011</year>
          ), iSO
          <fpage>26262</fpage>
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          9.
          <string-name>
            <surname>Lee</surname>
            ,
            <given-names>E.A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Seshia</surname>
            ,
            <given-names>S.A.</given-names>
          </string-name>
          :
          <article-title>Introduction to Embedded Systems - A Cyber-Physical Systems Approach</article-title>
          .
          <source>Lee and Seshia</source>
          ,
          <volume>1</volume>
          <fpage>edn</fpage>
          . (
          <year>2010</year>
          ), http://chess.eecs.berkeley. edu/pubs/794.html
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          10. Meyer, B.:
          <article-title>Applying ”design by contract”</article-title>
          .
          <source>Computer</source>
          <volume>25</volume>
          (
          <issue>10</issue>
          ),
          <fpage>40</fpage>
          -
          <lpage>51</lpage>
          (
          <year>1992</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref11">
        <mixed-citation>
          11.
          <string-name>
            <surname>Oertel</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Kacimi</surname>
            ,
            <given-names>O.</given-names>
          </string-name>
          , B¨ode, E.:
          <article-title>Proving compliance of implementation models to safety specifications</article-title>
          . In: Bondavalli,
          <string-name>
            <given-names>A.</given-names>
            ,
            <surname>Ceccarelli</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            ,
            <surname>Ortmeier</surname>
          </string-name>
          ,
          <string-name>
            <surname>F</surname>
          </string-name>
          . (eds.) Computer Safety, Reliability, and Security,
          <source>Lecture Notes in Computer Science</source>
          , vol.
          <volume>8696</volume>
          , pp.
          <fpage>97</fpage>
          -
          <lpage>107</lpage>
          . Springer International Publishing (
          <year>2014</year>
          ), http://dx.doi.org/ 10.1007/978-3-
          <fpage>319</fpage>
          -10557-4_
          <fpage>13</fpage>
        </mixed-citation>
      </ref>
      <ref id="ref12">
        <mixed-citation>
          12.
          <string-name>
            <surname>Oertel</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Mahdi</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          , B¨ode, E.,
          <string-name>
            <surname>Rettberg</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>Contract-based safety: Specification and application guidelines</article-title>
          .
          <source>In: Proceedings of the 1st International Workshop on Emerging Ideas and Trends in Engineering of Cyber-Physical Systems (EITEC</source>
          <year>2014</year>
          )
          <article-title>(</article-title>
          <year>2014</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref13">
        <mixed-citation>
          13.
          <string-name>
            <surname>Pnueli</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>The temporal logic of programs</article-title>
          .
          <source>In: Foundations of Computer Science</source>
          ,
          <year>1977</year>
          ., 18th Annual Symposium on. pp.
          <fpage>46</fpage>
          -
          <lpage>57</lpage>
          (
          <year>Oct 1977</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref14">
        <mixed-citation>
          14.
          <string-name>
            <surname>Reinkemeier</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Stierand</surname>
            ,
            <given-names>I.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Rehkop</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Henkler</surname>
            ,
            <given-names>S.:</given-names>
          </string-name>
          <article-title>A pattern-based requirement specification language: Mapping automotive specific timing requirements</article-title>
          . In: Reussner,
          <string-name>
            <given-names>R.</given-names>
            ,
            <surname>Pretschner</surname>
          </string-name>
          ,
          <string-name>
            <surname>A.</surname>
          </string-name>
          , J¨ahnichen, S. (eds.) Software Engineering 2011 Workshopband. pp.
          <fpage>99</fpage>
          -
          <lpage>108</lpage>
          . Gesellschaft fu¨r Informatik e.V. (GI) (
          <year>2011</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref15">
        <mixed-citation>
          15. RTCA: DO-178C
          <source>: Software Considerations in Airborne Systems and Equipment Certification. Radio Technical Commission for Aeronautics (RTCA)</source>
          (
          <year>2011</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref16">
        <mixed-citation>
          16.
          <string-name>
            <surname>Sonski</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          :
          <article-title>Contract-based modeling of component properties for safety-critical systems</article-title>
          .
          <source>Master's thesis</source>
          , Hochschule Darmstadt University of Applied Sciences (
          <year>2013</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref17">
        <mixed-citation>
          17.
          <string-name>
            <surname>Warg</surname>
            ,
            <given-names>F.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Vedder</surname>
            ,
            <given-names>B.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Skoglund</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Soderberg</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>Safetyadd: A tool for safetycontract based design</article-title>
          .
          <source>In: International Symposium on Software Reliability Engineering (ISSRE)</source>
          <year>2014</year>
          <article-title>Workshops</article-title>
          . to appear (
          <year>2014</year>
          )
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>