Drones - Target Convergence

No preview image

1 collaborator

Tags

artificial intelligence 

Tagged by Carlos Pedro S. Gonçalves about 5 years ago

drones 

Tagged by Carlos Pedro S. Gonçalves about 5 years ago

Visible to everyone | Changeable by the author
Model was written in NetLogo 6.1.1 • Viewed 743 times • Downloaded 44 times • Run 0 times
Download the 'Drones - Target Convergence' modelDownload this modelEmbed this model

Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)


WHAT IS IT AND HOW IT WORKS?

This is the first of a series of drone simulation models, and examples of multiagent Artificial Intelligence, in particular Swarm Artificial Intelligence (SAI) applied to robotics.

In this first example, the mission for the drones is to find a target and converge upon it.

The game stops when all the drones have arrived at the target's location.

The user can control the maximum number of steps that a drone can take in its search for a target, the drone's sight range and amplitude, the number of drones, and whether or not drones communicate with each other.

If the communication is turned off, then, the drones wander around until they find the target, whenever a drone finds the target then it moves to the target and stops.

When the communication switch is turned turn on, then, when a drone finds a target it activates a signal, the drones, even those that have not found the target, converge to the one of the drones that activated the signal and, thus, arrives at the site.

This is a first basic illustration of the effect of communication in swarm artificial intelligence. In future versions we will introduce further elements to illustrate the development of SAI.

The target counts the number of drones that have arrived at its location, when all the drones have arrived the game stops.

HOW TO USE IT

The user should first run the model without the communication, evaluating how the different drone sight characteristics and maximum number of steps affect the time it takes for the drones to reach the target.

Then the user should run the model with the communication turned on to see what happens.

The user can also run the model without the communication and then activate or even deactivate the communication at any time.

The ticks count the time, the plots show the evolution of the number of drones that arrived at the target's site.

THINGS TO NOTICE

Look at the plot and how its shape changes with the drone characteristics and the communication.

NETLOGO FEATURES

The model is the first of a series aimed at exploring the SAI.

CREDITS AND REFERENCES

Carlos Pedro Gonçalves, (2020) Drones - Target Convergence

Comments and Questions

Please start the discussion about this model! (You'll first need to log in.)

Click to Run Model

breed [drones drone]

breed [targets target]

drones-own [see_target signal at_site]

targets-own [drones_here]

to setup
  ca
  reset-ticks
  ask patches [ set pcolor white ]
  set-default-shape targets "circle"
  create-targets 1
  ask patch max-pxcor max-pycor [sprout-drones num_drones]
  ask drones [ set color blue
               set see_target False
               set signal "Inactive"
               set at_site False
               move_around
                ]
  ask targets [ set color green ]
end 

to go

  ; Each drone that is not at the target's site starts by scanning the environment within its sight range cone,
  ; if it sees the target, then, it changes the internal variable see_target from False to True
  ; if the communication is active then the drone activates the signal
  ask drones with [at_site = False] [ if any? targets in-cone sight_range amplitude_sight
                                        [ set see_target True
                                         if communication = True [set signal "Active"] ]
                                       ]

  ; If a drone that is not at the target's site sees the target, then, it implements the "seek"
  ; method of moving otherwise it  implements the "wander method of moving
  ask drones with [at_site = False] [ifelse see_target = True [seek] [wander]]

  ; The target counts the drones that have arrived at its location
  ask target 0 [set drones_here count drones-here]

  ; Plot the number of drones that have arrived at the target
  do_plot

  tick

  ; If all the drones have arrived stop the game
  if [drones_here] of target 0 = num_drones [stop]
end 

to wander
  ; Wander is the method for drones who do not have the target in sight

  ; When the communication is set to active...
  ifelse communication = True
  ;... then if there are any drones with an active signal
  ; move to the place of one of these drones, otherwise move around
  [ ifelse any? drones with [signal = "Active"] [ move-to one-of drones with [signal = "Active"] ] [ move_around ] ]
  ; When the communication is not set to active, the drone moves around
  [ move_around ]
end 

to move_around
  ; Move randomly on the world to search for the target
  ; future versions will change this method
  rt random 180
  fd max_step
end 

to seek
  ; The seek method expresses the seeking behavior where
  ; the drone has found the target location and moves to the target
  move-to target 0
end 

to do_plot
  set-current-plot "Number of Drones on Target"
  plot [drones_here] of target 0
end 

There is only one version of this model, created about 5 years ago by Carlos Pedro S. Gonçalves.

Attached files

File Type Description Last updated
view.jpg jpeg View about 5 years ago, by Carlos Pedro S. Gonçalves Download

This model does not have any ancestors.

This model does not have any descendants.