EverCheck EverTest EverView Workflow Training Guide Pricing Download Free Trial ✉ support@everbits.com

Making
the Car Move

The fourth and last unit of our car model: the mo­tion along the road. Drive force, brake force and re­sis­tance in; speed, ac­cel­er­a­tion and dis­tance out, lim­ited by the grip of the tyres. Spec­i­fied in plain words and ver­i­fied like a soft­ware unit: model re­view, static anal­y­sis, six tests, de­ci­sion cov­er­age. Every re­port linked as the tool wrote it.

See the work products ↓

7 min read · all re­ports open in a browser, no MATLAB needed

The longitudinal motion unit in EverView with its requirement tags, and the EverTest traceability matrix: six test cases, six requirements, all passed

Three tools · EverView · EverCheck · EverTest

Five work products, fourth unit #

The pow­er­train pushes, the driv­ing re­sis­tances hold back, the brakes slow down. This unit adds the three forces up and turns them into mo­tion. It has two states, speed and dis­tance, three places where it lim­its a value, and the most de­mand­ing test of the se­ries: a drive of ten kilo­me­tres that touches every limit of the in­ter­face. Same work­flow, same five work prod­ucts.

StepWork productToolISO 26262Result
1Unit Spec­i­fi­ca­tionWordPart 8, Clause 9 — ver­i­fi­ca­tion en­vi­ron­ment spec­i­fied6 re­quire­ments
2WEB_LON.html — model viewEverViewPart 6, Clause 8 — de­sign re­view input26 blocks, 6 re­quire­ment tags
3SMA_LON.html — static anal­y­sisEverCheckPart 6, Clause 8 — ver­i­fi­ca­tion of unit de­sign54 / 54 checks passed
4VER_LON.html — test re­sultsEverTestPart 8, Clause 9 — ver­i­fi­ca­tion ex­e­cuted and eval­u­ated6 / 6 passed, 6 / 6 re­quire­ments, 11 / 11 de­sign ranges
5COV_LON.html — struc­tural cov­er­ageEverTestPart 6, Clause 9 — cov­er­age met­ricsDe­ci­sion 6 / 6

All re­ports are self-con­tained HTML files. They open off­line, with­out MATLAB, and are the files that doc­u­ment the test en­vi­ron­ment in the safety case.

From forces to motion #

New­ton’s sec­ond law, one step at a time. Every 20 ms the unit takes the three forces, works out the ac­cel­er­a­tion, and moves the speed and the dis­tance on by one step. Three lim­its keep the re­sult phys­i­cal.

EffectWhere it comes fromHow it behavesOur car
GripThe tyres pass on only as much force as the road gives themDrive minus brake force is cut at plus and minus MU_ROAD × weight14 715 N dry, 10 300 N wet, 4 415 N on snow
Ac­cel­er­a­tionTyre force minus re­sis­tance, di­vided by the massThe speed changes by ac­cel­er­a­tion × 20 ms per cycle1500 kg: 12 000 N give 8 m/s²
No rolling backBrakes and hills slow a car down, they do not drive it back­wardsThe speed never goes below 0; the ac­cel­er­a­tion re­ports what was ac­tu­ally ap­pliedHeld on a 15 % hill: 0 m/s, 0 m/s²
Dis­tanceSpeed times time, added upGrows by speed × 20 ms per cycle; never de­creases3.92 m after 1 s of full drive

With this unit the car model is com­plete, and the num­bers of the ear­lier pages fi­nally add up to driv­ing:

Left: speed over time for full drive to 100 km/h and full braking on dry, wet and snowy roads. Right: stopping distance from 100 km/h: 40 m dry, 57 m wet, 131 m snow

Fig­ure 1 · Com­puted from the spec­i­fi­ca­tion: the same car on three roads, flat, with­out air drag. Left: full drive to 100 km/h, then full brake. Right: the stop­ping dis­tance.

Why a plain sum. The unit uses the sim­plest in­te­gra­tion there is: the new speed is the old speed plus ac­cel­er­a­tion times 20 ms, and the dis­tance grows by the speed at the start of the cycle. After one sec­ond of full drive that gives 3.92 m, where the exact for­mula gives 4.00 m. The spec­i­fi­ca­tion states this dif­fer­ence, so the test can ex­pect it in­stead of tol­er­at­ing it.

The plan. The car was built in steps, and each step was ver­i­fied be­fore the next one was added: the pow­er­train, the driv­ing re­sis­tances, the brakes and the lon­gi­tu­di­nal mo­tion (this page). Next the loop is closed with the cruise con­troller.

Why verify the motion of a test tool #

The cruise con­troller only ever sees one num­ber from the car: the speed. Every other unit reaches the con­troller through this one. A car that rolls back­wards on a hill, that brakes harder than its tyres allow, or that loses a metre per kilo­me­tre would test the con­troller against a car that does not exist. The con­troller would pass, and the road would find the prob­lem.

The unit has two states, and both run for the whole drive. An error in a state does not show in one step; it adds up. That is why the tests here run up to two min­utes of sim­u­lated time and look at the speed and the dis­tance in every cycle, and why the spec­i­fi­ca­tion says how large the round­ing of sin­gle pre­ci­sion may get over ten kilo­me­tres.

ISO 26262-8 asks for a spec­i­fied ver­i­fi­ca­tion en­vi­ron­ment (Clause 9) and for con­fi­dence in every tool whose error could let a fault go un­de­tected (Clause 11). The pow­er­train page ex­plains the ar­gu­ment in full. The full run for this unit takes about fif­teen sec­onds.

Unit Specification #

Three pages in the same lay­out as for the other units: the in­ter­face table, six re­quire­ments, and the six test cases with the val­ues a re­viewer can check by hand.

NameTypeData typeMinMaxUnitDescription
fDriveInputsin­gle012000NDrive force at the wheels (from the pow­er­train)
fBrakeInputsin­gle015000NBrake force at the wheels (from the brakes)
fResInputsin­gle−2207.255273.83NDriv­ing re­sis­tance, pos­i­tive slows the car (from the re­sis­tances)
vOut­putsin­gle085m/sVe­hi­cle speed, never neg­a­tive
accLongOut­putsin­gle−13.32599.4716m/s²Lon­gi­tu­di­nal ac­cel­er­a­tion ac­tu­ally ap­plied
distanceOut­putsin­gle010000mDis­tance trav­elled
MU_ROADPa­ram­e­tersin­gle0.31.0–Road grip: dry 1.0, wet 0.7, snow 0.3
VEH_MASSPa­ram­e­tersin­gle15001500kgVe­hi­cle mass
GPa­ram­e­tersin­gle9.819.81m/s²Grav­ity
V_INITPa­ram­e­tersin­gle00m/sSpeed at the start
TSPa­ram­e­tersin­gle0.020.02sSam­ple time

What mat­ters: the input ranges are the out­put ranges of the three units that feed this one, so the in­ter­faces of the car model fit to­gether by con­struc­tion. MU_ROAD is the only pa­ram­e­ter with a range: one car, tested on dry, wet and snowy roads. Speed and dis­tance have no phys­i­cal limit in­side this unit; 85 m/s (just above the 300 km/h lim­iter of the pow­er­train) and 10 km (longer than any test) are de­sign as­sump­tions, and the spec­i­fi­ca­tion says so.

Model view for the design review #

Twenty-six blocks, read from left to right. The shaded area on the left is the grip of the road: drive minus brake force, cut at plus and minus MU_ROAD × VEH_MASS × G by a min and a max. Then the re­sis­tance is sub­tracted, the re­sult di­vided by the mass and mul­ti­plied by the sam­ple time. A sum and a max make the new speed, never below 0, and a unit delay holds it. The bot­tom line adds up the dis­tance in a sec­ond unit delay.

EverView export of the longitudinal motion unit: grip limits on the left, Newton's law in the middle, speed and distance held in two unit delays, REQ tags on the implementing blocks

Fig­ure 2 · The unit in EverView. Sig­nal names, types and ranges on every line; one REQ tag per re­quire­ment on the block that im­ple­ments it.

Open WEB_LON.html →

Static analysis #

The same 54 checks as for the other units, run be­fore any test ef­fort is spent: in­ter­face com­plete and con­sis­tent, only ap­proved block types, ex­plicit ini­tial­iza­tion, di­vi­sions safe against zero, unique re­quire­ment IDs, re­quire­ment trace­abil­ity, model con­fig­u­ra­tion, no warn­ings dur­ing model up­date. Re­sult: 54 of 54 passed.

EverCheck summary: test run, harness, test object, complexity metrics, environment; 54 of 54 checks passed

Fig­ure 3 · EverCheck sum­mary: 26 blocks, op­er­a­tor com­plex­ity 15, 54 / 54.

Open SMA_LON.html →

One test case per requirement #

Each test is a short drive: ac­cel­er­ate, hold, brake, stop. Six test cases, one per re­quire­ment, 6967 time steps in total, and an ex­pected value in every one of them, com­puted from the spec­i­fi­ca­tion be­fore the first run.

Test caseSituationWhat we expectREQ
TC1_StartFull drive from the first cycle, 0.5 sSpeed 0, 0.16, 0.32 m/s; dis­tance 0, 0, 0.0032 m; ac­cel­er­a­tion 8 m/s² at onceLON-1
TC2_New­ton12 000 N, then 6000 N against 1500 N, then coast­ing against 1500 N, 1 s each8, 11 and 10 m/s after each sec­ond; 8, 3 and −1 m/s²LON-2
TC3_GripSnow: full drive for 1 s, then full brake for 0.5 sBoth capped at 4414.5 N: +2.943 and −2.943 m/s²LON-3
TC4_NoReverseWet road: drive to 4 m/s, brake to a stop, hold on a 15 % up­hill with and with­out brake, roll down a 15 % down­hillStops at 1.2 s, −0.857 m/s² in the last cycle; stays at 0 on the hill; rolls for­ward at 0.8048 m/s²LON-4
TC5_Dis­tance1 s full drive, 1 s cruise, brake to a stop3.92 m, 11.92 m, 15.26 m at the stop, then con­stantLON-5
TC6_RangeFull drive down­hill, cruise at 85 m/s against the high­est re­sis­tance, full brake, 125 s9.4715 and −13.3259 m/s², ex­actly 85 m/s, ex­actly 10 000 m; never out­side the rangesLON-6

The test harness, live

This is the EverView ex­port of the test har­ness it­self, live in the frame: the lon­gi­tu­di­nal mo­tion unit be­tween the EverTest source and sink, with the sig­nal names and ranges of the in­ter­face. Dou­ble-click into LON to walk the model, click a block for its prop­er­ties. Ex­actly what a re­viewer does, with no li­cence.

Open full screen in a new tab ↗

EverView export of the LON test harness: model browser, the unit between EverTest source and sink, properties panel Open the live har­nessFull screen in a new tab. Walk into the unit, click a block for its prop­er­ties. Best on a tablet or desk­top.Open live ex­port ↗

LIVE EVERVIEW EXPORT · LON_har­ness · NAVIGATE · SEARCH · PROPERTIES

Open LON_har­ness.html →

Test results and traceability #

One run ex­e­cutes the six cases in the har­ness and writes the ver­i­fi­ca­tion re­port. Re­sult: 6 of 6 passed, all six re­quire­ments cov­ered, all eleven de­sign ranges reached.

Requirements traceability matrix: six test cases, six requirements, one requirement per test case, all passed

Fig­ure 4 · Re­quire­ments trace­abil­ity ma­trix: one test case per re­quire­ment, all passed.

EverPlot of TC4: speed rises to 4 m/s, falls to 0 under braking, stays at 0 on the uphill with and without brake, then rises slowly on the downhill; marker lines at every input change

Fig­ure 5 · TC4_NoReverse in the re­port: up to 4 m/s, braked to 0, held on the hill with and with­out brake, never below 0, then rolling for­ward down­hill.

TC1 test data: time, inputs, reference and recorded speed, acceleration and distance for the first 26 cycles, all green

Fig­ure 6 · The test data of TC1: the hand-com­puted ref­er­ence next to the recorded value in every cycle, with the phase marker, the goal and the plot com­mands in the de­scrip­tion col­umn.

What the first runs found

Three things did not pass on the first at­tempt. None of them was a mod­el­ling error, all three were gaps be­tween the spec­i­fi­ca­tion and the arith­metic, and each was closed in the spec­i­fi­ca­tion first:

EverPlot of TC6: acceleration at 9.47 then 0 then -13.33 m/s squared; distance rising to exactly 10000 m; speed rising to 85 m/s, cruising, braking to 0

Fig­ure 7 · TC6_Range: ac­cel­er­a­tion, dis­tance and speed over 125 s. Every limit of the in­ter­face reached, none passed.

Open VER_LON.html →

Structural coverage: three limits, both ways #

Each of the three lim­its is a min or max block, and each is a de­ci­sion with two out­comes: the limit is ac­tive or it is not. The cov­er­age re­port shows all six out­comes, cy­clo­matic com­plex­ity 4.

Coverage report: MinMax blocks GripLower, GripUpper and NoReverse, each 100 percent decision coverage, both inputs taken

Fig­ure 8 · COV_LON: de­ci­sion 6 / 6 on the two grip lim­its and the no-rolling-back limit.

EverPlot of TC3 on snow: acceleration at +2.943 m/s squared during full drive, then -2.943 m/s squared during full braking

Fig­ure 9 · TC3_Grip on snow: both grip lim­its ac­tive, one after the other. With­out the lim­its the plot would show +8 and −10 m/s².

Open COV_LON.html →

Four units of one test tool #

The ar­gu­ment is the same as for the pow­er­train, the re­sis­tances and the brakes. EverCheck and EverTest bring their own TCL 3 qual­i­fi­ca­tion kit. The plant model is a tool we build our­selves, and its con­fi­dence comes from the work shown here: a spec­i­fi­ca­tion, a model that passed the prod­uct’s static checks, tests against val­ues com­puted in ad­vance, cov­er­age of every de­ci­sion, and re­ports that record every ver­sion. With this page all four plant units have that record, and the in­ter­faces be­tween them were spec­i­fied to fit.

How ISO 26262 tool qual­i­fi­ca­tion works →

What it took #

Frequently asked questions

Why can the car not roll backwards?

Be­cause the cruise con­troller under test only drives for­wards, and a re­verse gear is not part of this model. With­out the limit a car held by its brakes on a hill would start to roll back as soon as the brake force ex­ceeded the hill, which is not what brakes do. The limit is one max block, and TC4 checks it on a hill with and with­out the brake.

Why does the speed react one cycle later than the acceleration?

The ac­cel­er­a­tion of a cycle is the change from this cycle’s speed to the next one. The speed is a state and shows the change in the next cycle. TC1 shows it in the first three num­bers: ac­cel­er­a­tion 8 m/s² at once, speed 0.16 m/s one cycle later, dis­tance two cy­cles later.

Why 3.92 m and not 4.00 m after one second?

The unit adds up the speed at the start of each cycle, the sim­plest in­te­gra­tion there is. Over one sec­ond of con­stant ac­cel­er­a­tion that misses half a cycle of speed gain: 0.08 m. At 50 Hz the dif­fer­ence stays below 0.1 m per sec­ond of ac­cel­er­a­tion, and the spec­i­fi­ca­tion writes it down in­stead of hid­ing it in a tol­er­ance.

Why is the upper acceleration limit 9.4716 and not 9.4715?

The exact value is 9.4715 m/s². In sin­gle pre­ci­sion the model com­putes 9.47151, one hun­dred-thou­sandth above it, and the range check stopped the sim­u­la­tion. The de­sign limit was raised by 0.0001 in the spec­i­fi­ca­tion, the model and the test spec­i­fi­ca­tion, with the rea­son writ­ten next to it.

What comes next?

The car model is com­plete. Next the loop is closed: the cruise con­troller drives the four ver­i­fied units, and the tests look at the whole car on the road.

Same workflow, your test environment

Down­load the trial, take one plant unit, and pro­duce the five work prod­ucts for it. Or bring one unit to a half-day work­ing ses­sion — your model, your re­quire­ments, your re­ports at the end.

⬇ Download Free Trial Talk to us