%
\DeclareMathSymbol{\N}{\mathbin}{AMSb}{"4E}
\DeclareMathSymbol{\Z}{\mathbin}{AMSb}{"5A}
\DeclareMathSymbol{\R}{\mathbin}{AMSb}{"52}
\DeclareMathSymbol{\Q}{\mathbin}{AMSb}{"51}
\DeclareMathSymbol{\I}{\mathbin}{AMSb}{"49}
\DeclareMathSymbol{\C}{\mathbin}{AMSb}{"43}
%\DeclareMathSymbol{\hh}{\mathbin}{AMSb}{"48}


\newcommand{\ft}{\ensuremath{4\!\!\rightarrow\!\!20mA} }
\usepackage{graphicx}
\usepackage{fancyhdr}
\usepackage{tikz}
\usepackage{amsfonts,amsmath,amsthm}
\usetikzlibrary{shapes.gates.logic.US,trees,positioning,arrows}
\def\layersep{1.8cm}
%\input{../style}\def\layersep{1.8cm}
\usepackage{ifthen}
\usepackage{lastpage}
\usetikzlibrary{shapes,snakes}
\newcommand{\tickYES}{\checkmark}
%%   \newcommand{\fc}{fault~scenario}
\newcommand{\fc}{failure~cause}
%%   \newcommand{\fcs}{fault~scenarios}
\newcommand{\fcs}{failure~causes}
% Page layout definitions to suit A4 paper
\setcounter{secnumdepth}{3}        \setcounter{tocdepth}{4}
\setlength{\topmargin}{0mm}
\setlength{\textwidth}{160mm}      \setlength{\textheight}{220mm}
\setlength{\oddsidemargin}{0mm}    \setlength{\evensidemargin}{0mm}
%
\newcommand{\permil}{\ensuremath{0/{\!}_{00}}}

\newcommand{\emp}{} %% was italics
\newcommand{\sd}{\ensuremath{\Sigma \Delta ADC}} 
%\newcommand{\sd}{\ensuremath{Sigma\;Delta\;ADC}} 
\newcommand{\derivec}{{D}}
%\newcommand{\hh}{\ensuremath{{\stackrel{o}{H}}}}
\newcommand{\hh}{\ensuremath{{\hbar}}}
\newcommand{\abslev}{\ensuremath{\alpha}}
\newcommand{\oc}{\ensuremath{^{o}{C}}}
\newcommand{\adctw}{{${\mathcal{ADC}}_{12}$}}
\newcommand{\adcten}{{${\mathcal{ADC}}_{10}$}}
\newcommand{\ohms}[1]{\ensuremath{#1\Omega}}
\newcommand{\fm}{\emp failure~mode}
\newcommand{\fms}{\emp failure~modes}
\newcommand{\FG}{\ensuremath{{FG}}}
\newcommand{\DC}{\ensuremath{{DC}}}
\newcommand{\fg}{\emp functional~grouping}
\newcommand{\fgs}{\emp functional~groupings}
\newcommand{\dc}{\emp derived~component}
\newcommand{\dcs}{\emp derived~components}
\newcommand{\bc}{\emp base~component}
\newcommand{\bcs}{\emp base~components}
\newcommand{\irl}{in~real~life}
\newcommand{\enc}{\ensuremath{\stackrel{enc}{\longrightarrow}}}
\newcommand{\pin}{\ensuremath{\stackrel{pi}{\longleftrightarrow}}}
\newcommand{\half}{\ensuremath{\frac{1}{2}}}
\newcommand{\cf}[1]{\textbf{#1()}}

%
% OK after about 3 years its not rigorous FMEA (RFMEA) anymore, oh no, its Exhaustive FMEA
% but since the fuckers might change it yet again, I am making this a macro.
\newcommand{\XFMEA}{XFMEA}
%

%\newcommand{\pic}{\em pure~intersection~chain}
\newcommand{\pic}{\emp pair-wise~intersection~chain}
\newcommand{\wrt}{\emp with~respect~to}
\newcommand{\swf}{software~function}
% DO NOT USE THIS ONE USE \abslev \newcommand{\abslevel}{\ensuremath{\Psi}}


%% GLOSSARY FORMAT
%
% \newcommand{\fmmdname}{\glossary{name={FMMDNAME},description={ }}

%\fmodegloss

\newcommand{\fmmdglossSYS}{\glossary{name={system}, description={A product designed to work as a coherent entity}}}
\newcommand{\fmmdglossSS}{\glossary{name={sub-system}, description={A part of a system, sub-systems may contain sub-systems and so-on}}}
\newcommand{\fmmdglossDC}{\glossary{name={{\dc}}, description={A theoretical component, derived from a collection of components (which may be derived components themselves)}}}
\newcommand{\fmmdglossFG}{\glossary{name={{\fg}}, description={A collection of sub-systems and/or components that interact to perform a specific function}}}
\newcommand{\fmmdglossSYMPTOM}{\glossary{name={symptom}, description={A failure mode of a {\fg}, caused by a combination of its component failure modes}}}
\newcommand{\fmmdglossBC}{\glossary{name={base component}, description={Any bought in component, or lowest level module/or part}}}



%\newcommand{\fmmdglossFIT}{\glossary{name={FIT},description={Failure in Time (FIT). The statistical likelihood of failure mode occurring within a $10^9$ hour period.}}
\newcommand{\fmmdglossFIT}{\glossary{name={FIT}, description={Failure in Time (FIT). The number of times a particular 
failure is expected to occur within a $10^{9}$ hour time period.}}}

\newcommand{\fmmdglossHFMEA}{\glossary{name={HFMEA},description={
Hardware FMEA. FMEA applied to hardware i.e. mechanical or electrical equipment.}}}

\newcommand{\fmmdglossSFMEA}{\glossary{name={SFMEA},description={
Software FMEA. FMEA techniques applied to software. }}}

\newcommand{\fmmdglossXFMEA}{\glossary{name={XFMEA},description={
Exhaustive FMEA. Applying FMEA exhaustively means checking each failure mode 
for effects on all components in a given system. }}}

\newcommand{\fmmdglossDFMEA}{\glossary{name={DFMEA},description={Design FMEA. FMEA applied in design stages of a product. Used as a discussion method to reveal safety weakness and improve built in safety.}}}
\newcommand{\fmmdglossPFMEA}{\glossary{name={PFMEA},description={Production FMEA. FMEA applied applied for cost benefit analysis typically used in mass production.}}}
\newcommand{\fmmdglossSFTA}{\glossary{name={SFTA},description={Software Fault Tree Analysis (SFTA): top down failure investigation applied to software.}}}
\newcommand{\fmmdglossFTA}{\glossary{name={FTA},description={Fault Tree Analysis (FTA). A top down failure analysis technique which starts with undesirable top level events and works downwards to putative causes.}}}
\newcommand{\fmmdglossFMEDA}{\glossary{name={FMEDA},description={Failure Mode Effects and Diagnostic Analysis (FMEDA). An extended FMEA technique which provides for diagnostic mitigation and has a final statistical safety level as a result.}}}
\newcommand{\fmmdglossFMECA}{\glossary{name={FMECA},description={Failure Mode Effects and Criticality Analysis (FMECA). An extended FMEA technique which is used to order the severity or criticality of top level events/symptoms.}}}
\newcommand{\fmmdglossFS}{\glossary{name={forward~search},description={Failure analysis where the start points are base component failure modes and the result is system level failure/symptom.}}}
\newcommand{\fmmdglossBS}{\glossary{name={backward~search},description={Failure analysis where the start points are system level failure/symptom and the results are lower level putative causes.}}}
\newcommand{\fmmdglossINHIBIT}{\glossary{name={inhibit},description={A guard on a process such that if a condition is not met, the process may not continue.}}}
\newcommand{\fmmdglossSIGPATH}{\glossary{name={signal~path},description={The components (software or hardware) and connections that a particular signal or value is derived from in a system.}}}
\newcommand{\fmmdglossRD}{\glossary{name={reasoning~distance},description={A reasoning distance is the number of stages of logic and reasoning, counted by the number of components examined, used to map a failure cause to its potential outcomes.}}}
\newcommand{\fmmdglossOBS}{\glossary{name={observability}, description={If it cannot be detected that a failure has occurred it is termed unobservable or undetectable.}}}

\newcommand{\fmmdglossSMARTINSTRUMENT}{\glossary{name={smart~instrument}, description={
A smart instrument is  one that uses software 
in conjunction with its sensing electronics, rather than
analogue electronics only~\cite{smart_instruments_1514209}.}}}

\newcommand{\fmmdglossCONTRACTPROG}{\glossary{name={contract~programming}, description={
A software discipline whereby each function is assigned strict pre and post conditions
which define a formalised `contract' for how the function should behave.}}}

%
%\newcommand{\fmmdglossRD}{\glossary{name={reasoning~distance}{yahda yahda ya}}}
%
\newcommand{\fmmdgloss}{\glossary{name={FMMD},description={
Failure Mode Modular De-Composition (FMMD). A bottom-up methodology for incrementally building 
failure mode models, using a procedure taking functional groups of components and creating 
derived components representing them, and in turn using the 
derived components to create higher level functional groups, and so on, 
that are used to build a hierarchical failure mode model of a system}}}


\newcommand{\fmodegloss}{\glossary{name={failure mode},description={The way in which a failure occurs. 
A component or sub-system may fail in a number of ways, and each of these is a 
failure mode of the component or sub-system.}}}

\newcommand{\fmeagloss}{\glossary{name={FMEA}, description={
Failure Mode and Effects analysis (FMEA) is a process where each failure mode of components in a given system,
is analysed to determine system level failures/symptoms.}}}

\newcommand{\frategloss}{\glossary{name={failure rate}, description={
The number of failures within a population (of size N), divided by N over a given time interval}}}
\newcommand{\pecgloss}{\glossary{name={PEC},description={A Programmable Electronic controller, 
will typically consist of sensors and actuators interfaced electronically, with some firmware/software component in overall control}}}

\usepackage{amsthm}

\newtheorem{example}{Example:}
\newtheorem{definition}{Definition:}
\newtheorem*{summary}{Summary:}


%
\newcommand{\Fam}{{\mathbb F}}
\newcommand{\Pow}{{\mathbb P}}
\newcommand{\Dis}{{\vee}}
\newcommand{\Con}{{\wedge}}
\newcommand{\FMEA}{{\bowtie}}
%
\newcommand{\Nat}{{\mathbb N}}
\newcommand{\Real}{{\mathbb R}}
\newcommand{\Complex} {{\mathbb C}}
\newcommand{\Rational} {{\mathbb Q}}
%
