-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMain.m
More file actions
38 lines (35 loc) · 883 Bytes
/
Main.m
File metadata and controls
38 lines (35 loc) · 883 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
%% Main - Start multirobot
close all
clear
clc
addpath('Utility-Mapping')
compilemexlibrary
%% Generate Map
% build a new map with:
% map = Map("New", width, heigth);
% map = Map("New", width, heigth, #landmark, "auto");
% map = Map("New", width, heigth, #landmark, "manual");
% or load an existing one:
% map = Map("Load");
% map = Map("Load", #landamark);
% map = Map("Load", #landamark, "auto");
% map = Map("Load", #landamark, "manual");
map = Map('new', 60, 60);
figure('units','normalized','outerposition',[0 0 1 1]); axis equal
axis([0, 100, 0, 100])
map.plotMap();
print('map100x100','-depsc','-r0')
%% Set-up paramaters simulation
% define number of robots to use
numrobot = 4;
% define base time
basetime = 200;
% increment of time
step = 9;
parfor (k = 1:step, 4)
for n = 1:numrobot
multirobot(n, k * basetime, map, 1)
end
end
%% analysis result
Result