I have come across many blogs and books where it is stated that it is bad for a system requirement to contain conjunctions like "and". However in reality I am often coming across scenario where a requirement is satisfied when a certain set of conditions are met. For instance, Shopkeeper should sell alcohol only if the buyer is older than 18 years, he has the necessary proof and he does not have any alcohol related problems. The requirement would not be complete if I break it down into multiple system requirements and I cannot complete the requirement without use of "and".
There is no reason that all the conditions have to be one requirement.
- The system shall sell alcohol only to those older than 18.
- The system shall require proof of age to sell alcohol.
- The system Shall not sell alcohol to those with alcohol related problems.
These are all perfectly valid requirements, and the system is not valid unless it meets all the requirements. System requirements are all implicitly connected with an "and" its why the are requirements and not wishes. Furthermore by expanding each condition to its own requirement it is far easier to track what has and hasn't been met this way because each requirement is a binary yes or no.
You could phrase it as a tree. This avoids any sort of grouping ambiguity in natural language.
- Alcohol can be sold if the buyer meets all of the criteria
- Buyer is older than 18 years.
- Buyer has the necessary proof of age.
- Buyer does not have any alcohol related problems.
This approach also works well for or(One of the following), and nested items.
Consider using both approaches (stand-alone and conjunctive) for your rules.
Using the example you cited, you would have three stand-alone rules:
only if the buyer is older than 18 years
has the necessary proof of identification
does not have any alcohol related problems
And then have a conjunctive rule for all three of the stand-alone rules.
- 1 + 2 + 3 == true
Your stand-alone rules represent the core of your system requirements. The conjunctive rules represent a higher level or requirements that could change based upon the jurisdiction.