You are on page 1of 10

AI314

Autonomous Multiagent Systems


2nd Report

Greenhouse Monitoring & Controlling Agent


NAME ID
ABDELRAHMAN KHALED 20180142
AMAL SHERIF 20180053
MAHMOUD HOSSAM 20180251
NYAVOR JEAN-PIERRE 20180448

Spring 2021
I- Defining the Problem
The job of the monitoring and controlling agent is to maintain microclimate by
controlling its variables. To be able to maintain microclimate variables the agent
must monitor a set of factors:

• Inner greenhouse microclimate (soil and air temperature, relative humidity,


carbon dioxide CO2 concentrations, electrical conductivity and soil moisture)

• Outer climate (temperature, relative humidity, solar radiation, wind speed, wind
direction and rainfall rate)

• Actuators and equipment status (ex: vents and curtains position)


To be able to control these variables the agent must be connected to :

• Heating system (for temperature and humidity control)

• Ventilation and fogging system (for temperature, humidity, and CO2 control)

• Lighting and shading system (for Light intensity and solar radiation control)

• Irrigation and nutrition system (for soil composition and moisture control)

• CO2 injection system (for CO2 control)

our problem is to build and agent that can find the combination of actions to be
taken that will result in a microclimate that maximizes production and reduces
costs.
Problem Formulation:

• Goal test: Checking whether the estimated measures of temperature and humidity are within the required
range.

• States: The state is determined by the previous actions that has been taken upon each variable (Increased,
Decreased, Maintained). The total number of states is 9 states.

• Initial State: Both variables are maintained as they are in the measurements at the corresponding moment.

• Actions: Each state has 4 actions, increase temperature, decrease temperature, increase humidity, decrease
humidity.

• Transition model: each action would lead to a change in each environmental variable. Changes are estimated
for each action depending on the values of the environmental variables.

• Path cost: Every action has a cost that is defined at the beginning depending on how much resources it’s
going to consume (i.e., electricity, time, etc.)
State Space Diagram
Solving the Problem

Solving Using DFS


At each state the agent can apply the goal test to check whether it had reached the
optimal values or not. The agent also saves the states it had reached in all the states
to make sure it does not check a state that has been already checked, and in case it
did not find an optimal solution, it can simply look up the nearest one to it among
the solutions it has reached.
The agent will get the measurements of the variables at the corresponding moment.
Then at the first state it will maintain the variables as they are and apply the goal
test. If it didn’t pass the test it is going to continue going down the search tree and
apply the goal test at each state.
The below diagram shows a part of the search tree and how the agent acts.
Solving Using DFS

The complexity of this solution at the worst case (Agent had to go through all
states before it finds optimal solution) is O(bm) where b is the branching factor
and m is the maximum depth of search tree and the total number of iterations
will be the number of states.

The space complexity is O(bm) where b is the branching factor and m is the
maximum depth of search tree. In our case the branching factor is 4 and
maximum depth is going to be 3.
Solving using BFS

When applying the BFS technique on our problem, the agent is going to
traverse in the search tree layer wise by checking all the possible states that
can be reached from the current state.

The same strategy used in DFS can be applied here, which is applying the goal
test at each state and terminate if the optimal solution was reached.

In contrast with DFS, BFS stores newly discovered nodes in a FIFO queue
which in turn increases the space complexity. The space complexity of BFS
search is O(bd) where b is the branching factor and d the depth of the
shallowest solution. In our case it will be O(43).
The below diagram shows how the agent is going to explore solutions through the search tree.

You might also like