Software Engineering & Object-Oriented Analysis & Design β Software Process and Requirements, NEC licence examination syllabus (Nepal Engineering Council).
Software Requirements Document (SRS)
The one document everybody signs, and therefore the one everybody argues about.
π Where this lives: the SRS is the point where a conversation becomes an obligation. In any procurement β a government tender, an outsourced build, a fixed-price contract β the SRS is the document a court would read to decide whether the software delivered was the software bought. That is why it has a standard structure (IEEE 830), why every requirement is numbered, and why "the system shall be user-friendly" is a genuinely dangerous sentence to sign. Search "IEEE 830 software requirements specification template".
What the SRS is, and who reads it
THE SRS (also: requirements document, functional
specification) is the OFFICIAL STATEMENT of what the system
developers should implement.
It should include BOTH the user requirements and a detailed
specification of the system requirements.
IT IS NOT A DESIGN DOCUMENT. As far as possible it says WHAT
the system should do, not HOW. This line is not absolute β
organisational and interoperability requirements do constrain
the how β but every "how" that sneaks in removes a design
option the engineers might have needed.
SIX AUDIENCES, SIX PURPOSES (Sommerville):
SYSTEM CUSTOMERS
specify the requirements and read them to check they meet
their needs. They state changes to the requirements.
MANAGERS
use it to bid for the system and to plan the development
process.
SYSTEM ENGINEERS
use it to understand what system is to be developed.
SYSTEM TEST ENGINEERS
use it to develop validation tests for the system.
β THIS IS THE MOST DEMANDING READER. If a requirement
cannot be turned into a test, it is not a requirement.
Testers find the unmeasurable requirements faster than
reviewers do.
SYSTEM MAINTENANCE ENGINEERS
use it to understand the system and the relationships
between its parts β years later, when everyone who wrote it
has left.
(and in regulated domains) AUDITORS AND CERTIFIERS
use it as the evidence base for compliance.
THE CONFLICT THIS CREATES: no single writing style serves all
six. That is precisely why the two-level structure (user
requirements then system requirements) exists.
Structure β IEEE 830 as adapted by Sommerville
1. PREFACE
Who the document is for; version history; the change
rationale for each version. Cheap to write, and the first
thing a maintenance engineer reads.
2. INTRODUCTION
Why the system is needed; its functions briefly; how it
fits with other systems; the business objectives.
3. GLOSSARY
Every technical term and domain term, defined. Do not skip
this β it is where DOMAIN REQUIREMENTS get surfaced, because
defining a term forces the expert to state the convention
hidden inside it.
4. USER REQUIREMENTS DEFINITION
Natural language + diagrams. The services, the
non-functional requirements, the constraints. Written for
the customer.
5. SYSTEM ARCHITECTURE
A high-level overview of the anticipated architecture,
showing the distribution of functions across modules, and
marking reused components.
6. SYSTEM REQUIREMENTS SPECIFICATION
Detailed functional and non-functional requirements. May
define interfaces to other systems.
7. SYSTEM MODELS
Graphical models: object models, data-flow models, entity-
relationship models, state machines β showing relationships
between components and between system and environment.
8. SYSTEM EVOLUTION
The fundamental ASSUMPTIONS the system is based on, and
anticipated changes from hardware evolution, user needs
etc. Useful to designers: it says which decisions must stay
flexible.
9. APPENDICES
Detailed, specific information β hardware requirements
(minimum and optimal configurations), database
requirements (logical organisation, relationships).
10. INDEX
Several may be appropriate: alphabetical, by diagram, by
function.
HOW MUCH DETAIL? It depends on the system:
Β· a fixed-price contract to an external supplier β maximum
detail, because the document is the contract
Β· an in-house agile team building an evolving product β
lighter, because the conversation continues
Very detailed requirements for a small, in-house, rapidly
changing system are waste. Under-specified requirements for a
fixed-price outsourced safety-critical system are negligence.
The six properties of a good SRS, and how each fails
1. CORRECT every requirement stated is one the system must
meet
2. UNAMBIGUOUS every requirement has exactly one
interpretation
3. COMPLETE all significant requirements present; responses
defined for all classes of input, valid AND
invalid; all figures labelled and referenced;
no "TBD"
4. CONSISTENT no requirement conflicts with another
5. VERIFIABLE a finite, cost-effective process exists to
check each requirement is met
6. TRACEABLE each requirement has a unique identifier, with
backward traceability to its origin and forward
traceability to design, code and tests
(also: RANKED for importance and stability, MODIFIABLE)
FAILURE MODES, WITH SPECIMENS:
β AMBIGUOUS
"The system shall provide reports for managers and
supervisors as required."
β which reports? as required by whom? separate reports or
one? "as required" is a blank cheque.
β INCOMPLETE β the invalid-input case is missing
"On entering a valid application number the system shall
display the applicant's record."
β and on an INVALID number? Completeness demands responses
to all classes of input, including the illegal ones. This
omission is the single commonest SRS defect.
β INCONSISTENT β a real pair, and both were signed
Β§4.2 "Applications shall be retained for 7 years for audit."
Β§9.1 "Personal data shall be deleted within 90 days of the
application being closed."
β these cannot both hold for an application's personal
data. Consistency checking is what reviews are FOR;
neither statement looks wrong alone.
β NOT VERIFIABLE
"The system shall never crash."
β no finite test establishes this. The verifiable form is
"MTBF shall exceed 5000 hours in a 6-month trial".
β NOT TRACEABLE
Requirements written as flowing prose with no numbers. When
the customer asks to change one thing, nobody can say which
tests, modules and design decisions are affected.
β DESIGN LEAKING IN
"The system shall store applications in a PostgreSQL table
named licence_app."
β unless the database is genuinely an organisational
constraint, this removes a design choice for no
requirement-level reason.
Of the six properties, verifiable does the most work in practice, because it subsumes much of the others: a requirement you can write a test for is rarely ambiguous, and writing the test for the invalid case is what exposes incompleteness. "How would the test engineer check this?" is the single most productive question to ask of any requirement.
π Go further: the traceability property has a name in industry: the requirements traceability matrix, mapping each requirement id to its source, its design element, its code module and its test cases. In safety-critical and regulated work (DO-178C for avionics, IEC 62304 for medical devices, ISO 26262 for automotive) it is not optional β you cannot certify a system without demonstrating that every requirement is tested and every line of code traces to a requirement. It is the mechanism that makes "we tested everything" a checkable claim rather than a hope. Search "requirements traceability matrix DO-178C".
π‘ Exam angle: reproduce the SRS structure (preface, introduction, glossary, user requirements, architecture, system requirements, system models, evolution, appendices, index) and the six readers with what each uses it for. State the characteristics of a good SRS β correct, unambiguous, complete, consistent, verifiable, traceable, ranked, modifiable β and be prepared to criticise a badly written requirement and rewrite it; that is a very common question. Remember that completeness explicitly includes responses to invalid inputs.
Syllabus points
Structure & contents of SRS
Create a free account to tick topics off, take notes as you read, watch the video lessons and get a day-by-day study plan built around your exam date.
Related topics in Software Process and Requirements