Link to home
Create AccountLog in
Programming Languages-Other

Programming Languages-Other

--

Questions

--

Followers

Top Experts

Avatar of alirezakaveh
alirezakaveh🇦🇪

use case diagram and scenario
hello experts
could you please confirm my solution for the following problem regarding use case?


Consider the following requirements:
• When a person enters the room (that is, the room is occupied) and it is dark outside, the
system should turn on the light.
• When the last person leaves the room (that is, the room is not occupied), the system
should turn off the light.
• When it gets bright outside and the light is on, the system should turn off the light.
• When it gets dark and the room is occupied, the system should turn on the light.
Draw a use-case diagram for the listed requirements. Additionally provide a scenario
description.


my solution for use case is :
User generated image



my solution for scenario is:
Scenario: turning on the light  
-      Weather is getting dark
-      Sensor detecting darkness outside the room
-      Sensor detecting somebody is inside the room
-      System will turn on lights

Zero AI Policy

We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.


Avatar of TommySzalapskiTommySzalapski🇺🇸

Do you have occupancy sensors or people entering and leaving sensors?
I don't see you turning the lights off ever but the requirements definitely say you should.

Avatar of alirezakavehalirezakaveh🇦🇪

ASKER

yes you are right i changed it to this diagram
User generated image

You are missing the case where it is dark outside but the room is empty.

Reward 1Reward 2Reward 3Reward 4Reward 5Reward 6

EARN REWARDS FOR ASKING, ANSWERING, AND MORE.

Earn free swag for participating on the platform.


Avatar of alirezakavehalirezakaveh🇦🇪

ASKER

it can't be concluded from the case darkness and person detection will cause the light on?

ASKER CERTIFIED SOLUTION
Avatar of TommySzalapskiTommySzalapski🇺🇸

Link to home
membership
Log in or create a free account to see answer.
Signing up is free and takes 30 seconds. No credit card required.
Create Account
Programming Languages-Other

Programming Languages-Other

--

Questions

--

Followers

Top Experts

A programming language is a formal constructed language designed to communicate instructions to a machine, particularly a computer. Thousands of different programming languages have been created, mainly in the computer field, and many more still are being created every year. The description of a programming language is usually split into the two components of syntax (form) and semantics (meaning). Some languages are defined by a specification document (for example, the C programming language is specified by an ISO Standard), while other languages (such as Perl) have a dominant implementation that is treated as a reference. Some languages have both, with the basic language defined by a standard and extensions taken from the dominant implementation being common.