A Multiple Ant Colony Optimization Algorithm for Indoor Room Optimal Spatial Allocation

Indoor room optimal allocation is of great importance in geographic information science (GIS) applications because it can generate effective indoor spatial patterns that improve human behavior and efficiency. However, few research concerning indoor room optimal allocation has been reported. Using an office building as an example, this paper presents an integrative approach for indoor room optimal allocation, which includes an indoor room allocation optimization model, indoor connective map design, and a multiple ant colony optimization (MACO) algorithm. The mathematical optimization model is a minimized model that integrates three types of area-weighted costs while considering the minimal requirements of each department to be allocated. The indoor connective map, which is an essential data input, is abstracted by all floor plan space partitions and connectivity between every two adjacent floors. A MACO algorithm coupled with three strategies, namely, (1) heuristic information, (2) two-colony rules, and (3) local search, is effective in achieving a feasible solution of satisfactory quality within a reasonable computation time. A case study was conducted to validate the proposed approach. The results show that the MACO algorithm with these three strategies outperforms other types of ant colony optimization (ACO), Genetic Algorithm (GA), and particle swarm optimization (PSO) algorithms in quality and stability, which demonstrates that the proposed approach is an effective technique for generating optimal indoor room spatial patterns.


Introduction
Humans spend almost 87% of their time indoors [1].It is important to conduct research in indoor spaces.Some studies have already been performed, such as representation and space subdivision of indoor spaces [2,3], which provided a thorough technical foundation for further research, such as indoor room optimal allocation.
In the problem of indoor room optimal allocation, spatial search approaches are used to allocate specific objects (such as different office departments) to proper indoor space units (such as rooms) to achieve an optimal spatial layout by considering multiple factors, such as spatial convenience and personal preference.Skillful indoor spatial allocation, such as reasonably allocated departments in an office building, can effectively reduce the cost of office communication.Poor allocation can lead to increased office costs and waste.However, to the best of our knowledge, few studies have been conducted that focus on indoor room optimal allocation.
Previous studies for spatial optimal allocation involve urban planning, such as city land-use optimal allocation [4][5][6][7][8][9], protected ecological area partitioning [10], and farmland management [11].While establishing models for these problems, macroscopic factors, such as the natural environment (such as land use suitability, compatibility), economic development (such as land use conversion cost, travel time), and spatial/geometrical characteristics (such as distance, contiguity, and compactness) usually are considered [7].However human factors, such as the distribution of population and jobs, are always abstracted and simplified [12].However, in an indoor environment, human factors are important because human behavior is closely coupled with the indoor spatial layout [13].Therefore, human behavior, requirements, and their interaction with the indoor environment should be emphatically taken into consideration during problem modeling.
Moreover, similar to the spatial optimal allocation in urban planning, indoor room allocation is an non-deterministic polynomial-time hard (NP-hard) problem in the discrete domain, whose optimal solution often lies within innumerable combinations of allocable rooms and type alternatives and is hard to be found by traditional Geographic information sciences (GIS) functions within a reasonable time.Previous studies proved that the heuristic algorithm is effective at finding near-optimal solutions by obtaining a trade-off between the quality of solutions and the burden of computation.Numerous heuristic algorithms such as genetic algorithm (GA) [4,[14][15][16], simulated annealing (SA) [9,17], artificial immune system (AIS) [6], particle swarm optimization (PSO) [8,18], artificial bee colony (ABC) [5,10], and ant colony optimization (ACO) [7,19] have been proposed as approaches to spatial optimal allocation in urban planning.
Among these algorithms, ACO, which simulates a set of cooperating artificial ants seeking optimal routes (solutions) by local heuristics and knowledge from past experiences [20], is special because of its unique way of constructing solutions.Many heuristic algorithms, such as GA, AIS, PSO, and ABC, construct a new solution by neighborhood search manipulation (such as crossover and mutation) that changes parts of the current solution.Although the random neighborhood search manipulation increases the solution's diversity, it also leads to the generation of a large amount of low quality solutions because heuristic information cannot be generally used in the neighborhood search procedure, such as the commonly used crossover strategy.Different from it, ACO constructs a new solution by determining each element of a solution pseudo-randomly one by one.It means that heuristic information, which is helpful for obtaining an optimal solution of relative high quality [17], can be applied for the determination of each solution element.Potentially, ACO could be a more effective algorithm to tackle complex spatial optimization problems in certain areas.
In the area of spatial optimal allocation, ACO has been used to tackle this kind of problem.Li modified the ACO method for zoning protected natural areas by adjusting three strategies, route selection probability, heuristic information, and pheromone deposition [19].However, the proposed ACO can only be used to handle the land use allocation problem that involves only one land use type.Liu used a multi-type ant colony optimization (ACO) method to solve the problem with multiple land use types in large areas [7].In his modified ACO algorithms, the types of ants correspond to the types of land uses; the ant colony size equals the number of allocable units in study region, and each ant occupies a unit according to site selection probabilities.The locations of all the ants form a solution of the land use allocation problem.It can be seen that the colony size is not scalable and only one solution is obtained in each iteration, which is different from the essence of ACO that positively feeds back by the current-best solution among multiple solutions obtained by multiple ants in each iteration.Moreover, because only one solution is found in each iteration, it will reduce the solution's diversity, and will thus be trapped into the local optimal solution easily.Therefore, it is not suitable to introduce the modified ACO to solve the indoor room allocation problem directly.
Based on the above analysis, this paper presents an optimal model considering human interaction for indoor spatial allocation.A new multiple ant colony optimization (MACO) algorithm that is able to effectively allocate multiple objects to indoor space units is proposed to solve this NP-hard problem.The remainder of the paper is arranged as follows.Sections 2 and 3 introduce the details of the approach, including indoor spatial data organization, optimization model construction, and MACO resolution.The approach is tested and illustrated with a case study in Section 4. Finally, Section 5 presents the discussion and conclusions drawn based on previous experiments.

Indoor Room Optimal Allocation Model
The goal of establishing an indoor room optimal allocation model is to make the connectivity cost of people's communication minimized, the spatial layout of relative departments concentrated, and the energy consumption reduced.Different optimal allocation models could be established according to different requirements.For example, in this paper, the following demands are considered.
(1) To ensure the efficiency of internal communication, the rooms that are assigned to the same office department number should be relatively compact; (2) To enhance the convenience of daily work, the total connectivity cost of the business department's rooms to the public department's rooms should be minimized; (3) To reduce the energy consumption by utilizing elevators, the total connectivity cost of all allocated rooms to the building's exits is low; (4) Considering sustainable development, ensuring convenience and satisfying all department demands, the remaining rooms' area should be as large as possible.
In this paper, the mathematic symbols used in the model establishment are listed in Table 1.The number of public departments N b The number of business departments N e The number of building exits N r The number of allocable rooms The public departments The business departments Indoor spatial connectivity cost between two different rooms The allocation relationship between room i and department k.If room i is assigned to department k, x ik = 1; otherwise, x ik = 0.
Based on the first three requirements, three kinds of connectivity cost are defined, (1) Cost 1 (shown in Formula (1)), the connectivity cost within the same department, (2) Cost 2 (shown in Formula (2) ), the connectivity cost of all business departments' rooms to public departments', and (3) Cost 3 (shown in Formula (3)), the total connectivity cost from all allocated rooms to the building's exits.Meanwhile, considering the fourth requirement, all three connectivity costs are weighted by the room area.
Therefore, we can allocate departments with the minimum value for the following functions.
x ik ∈ {0, 1} Formula ( 5) is the area constraint, which requires that the total area of allocated rooms for each department must be larger than the department's minimum area demand.
The computation scale of the problem is (N p + N b ) N r , which will increase dramatically with the increase of N p , N b and N r .It is extremely difficult to find the best solution by greedy searches.Therefore, it is necessary to use a proper heuristic algorithm to find the optimal solution within reasonable time.

Indoor Spatial Data Model
The goal of designing indoor spatial data is to obtain the required parameters while solving the optimization problem, such as the connectivity cost between every two rooms d ij , and each room's area {A i }.
In order to be supportive for obtaining the connectivity cost d ij , the Geometric Network Model (GNM) [21] is imported to model the indoor spatial data.GNM is derived from a logical network, such as the Node-Relation Graph (NRG) in OGC IndoorGML [22], and is used to geometrically and realistically represent the indoor connectivity relationships.Similar to NRG, GNM represents 3D entities (such as rooms, exits, corridors) as nodes in a graph in dual space [23].However, different from the abstraction of a simple polygon (such as a hallway) to a node in NRG, GNM defines it as line segments.As shown in Figure 1, Figure 1b is the abstraction of an indoor building in primal space (Figure 1a) by the NRG models, but its two hallway nodes (H1 and H2) are represented as line features in the GNM models (shown as the blue line segments in Figure 1c).
In this paper, the main partitions in each floor plan, such as each room, exits, lift lobbies, and staircases, are abstracted as nodes located in each partition's entrance.In each floor plan and between floors, connections (such as hallways, stairs, and elevators) are abstracted as edges to represent the connectivity among different partitions.Notably, the area of each room A i and the connectivity costs of each connection d ij should be geographically calculated in primal geographic space.
ISPRS Int.J. Geo-Inf.2017, 6, 161 4 of 20 Formula ( 5) is the area constraint, which requires that the total area of allocated rooms for each department must be larger than the department's minimum area demand.
The computation scale of the problem is Therefore, it is necessary to use a proper heuristic algorithm to find the optimal solution within reasonable time.

Indoor Spatial Data Model
The goal of designing indoor spatial data is to obtain the required parameters while solving the optimization problem, such as the connectivity cost between every two rooms { } ij d , and each room's area {A }  i .In order to be supportive for obtaining the connectivity cost { } ij d , the Geometric Network Model (GNM) [21] is imported to model the indoor spatial data.GNM is derived from a logical network, such as the Node-Relation Graph (NRG) in OGC IndoorGML [22], and is used to geometrically and realistically represent the indoor connectivity relationships.Similar to NRG, GNM represents 3D entities (such as rooms, exits, corridors) as nodes in a graph in dual space [23].However, different from the abstraction of a simple polygon (such as a hallway) to a node in NRG, GNM defines it as line segments.As shown in Figure 1, Figure 1b is the abstraction of an indoor building in primal space (Figure 1a) by the NRG models, but its two hallway nodes (H1 and H2) are represented as line features in the GNM models (shown as the blue line segments in Figure 1c).
In this paper, the main partitions in each floor plan, such as each room, exits, lift lobbies, and staircases, are abstracted as nodes located in each partition's entrance.In each floor plan and between floors, connections (such as hallways, stairs, and elevators) are abstracted as edges to represent the connectivity among different partitions.Notably, the area of each room i A and the connectivity costs of each connection ij d should be geographically calculated in primal geographic space.Based on the indoor connectivity data, an origins and destinations (OD) cost matrix is obtained by setting the point features of all allocable rooms and building exits as origins and destinations.This matrix and each allocable room's area are used in the optimization computation as inputs.Based on the indoor connectivity data, an origins and destinations (OD) cost matrix is obtained by setting the point features of all allocable rooms and building exits as origins and destinations.This matrix and each allocable room's area are used in the optimization computation as inputs.

Basic ACO
ACO is a type of swarm intelligence heuristic algorithm that simulates the behaviors and communication of ants to solve complex optimization problems [20].In general, five phases are included in a basic ACO algorithm.
(1) Initializing pheromones.Usually, the pheromone on each node is initialized as the same value.
(2) Constructing solutions.Each artificial ant selects route nodes (solution's elements) successively and pseudo-randomly according to the transition probability to form a route (a solution).The transition probability is determined by the pheromones on all nodes and the heuristic information.Commonly, the more pheromone deposited on a node, the higher the probability that the node is selected by an ant.
(3) Updating solutions.If a better solution is constructed, the best-so-far solution will be recorded as the better one.
(4) Updating the pheromones on all nodes after new solutions are constructed by ants.This contains two kinds of pheromone updating strategies.One is pheromone reinforcement, which is used to increase the pheromone on each solution's nodes.The better the solution is, the larger the pheromone increment is.The other one is pheromone evaporation, which makes the pheromone on all nodes decrease at a predefined rate and is helpful for ants to "forget" the bad solutions in the previous iteration.By the combination of these two strategies and multiple repeated iterations, the pheromones on the optimal route's nodes increase, thus, the ants tend to converge to the optimal path (the optimal solution).
(5) Judging the algorithm's convergence.The convergent condition is usually defined as a maximum iteration number or maximum iteration time.If the convergent condition is not met, step 2 and step 3 will be executed again, otherwise, the algorithm stops.

Improvement Strategies
Based on the basic ACO algorithm, this paper proposes multiple ant colony optimization (MACO) to solve the problem of indoor spatial optimal allocation.Compared to basic ACO, MACO is improved from three aspects.First, three kinds of heuristic information that are influential to the transition probability calculation are proposed to navigate each ant's route selection to areas in the solution space where the global optimal solution is located.Second, a two-colony optimization rule is proposed to prevent the ants' route selection from being trapped in the local optimal solution.Third, a local search strategy is imported to improve the best solution's quality in each iteration and also the algorithm's overall performance.

Heuristic Information
When implementing indoor spatial allocation, if a fully random strategy is adopted, a large number of solutions with low quality will be generated, which makes it challenging to find the optimal solution within a reasonable time.Therefore, in this MACO, three types of connectivity costs in the problem's optimization model (the minimum connectivity cost of allocated rooms and exits, the minimum connectivity cost among rooms that are assigned to the same department, and the minimum connectivity costs between rooms that belong to different departments) can be treated as the heuristic information for assigning rooms to each department.
While evaluating the heuristic information, the mathematic symbols are listed as follows (Table 2).
Table 2.The mathematic symbols in evaluating the heuristic information.

Room number k, t
Department number θ(i) The department that room i is assigned to all the rooms that are assigned to department k Θ Θ = ∪Θ i , all the rooms that have been allocated T(k) The type of department k η(k, i) The heuristic information on node (k, i) Explicitly, heuristic information η(k, i) can be calculated based on the following three circumstances.

1.
If , which is the reciprocal of the minimum weighted connectivity cost between the allocated room i and the building exits.

2.
If , which is the reciprocal of the minimum weighted connectivity cost between the allocated room i and the allocated rooms whose department type is not T(k).

3.
If , which is the reciprocal of the minimum weighted connectivity cost between the allocated room i and the allocated rooms whose department number is k.

Two-Colony Optimization Strategy
Because of the usage of these three types of heuristic information, the order of allocating departments has a strong impact on the final allocation solution.In order to ensure more opportunities for generating solutions with a better order of allocating departments, a two-colony optimization rule has been imported to MACO.These two ant colonies are of the same size, N ant .
In the phase of solution generation, the first ant colony is used to pseudo-randomly determine the optimal order of allocating departments according to the transition probability based on the pheromone.The first-colony pheromone matrix is M 1 = {τ 1 (k, q)}, in which k is the number of the department and q is the allocation order.If the allocation order of department k is φ(k) and the former k − 1 departments' allocating order set is Φ = {φ(1), φ(2), • • • φ(k − 1)}, the transition probability that the allocating order of department k is set as q is: in which γ is the adjustment parameter of pheromone τ 1 (k, q).
Based on the order obtained by the first colony, the second ant colony assigns rooms to each department to form solutions (a sample of the solution is shown in Figure 2) according to its transition probability.The probability is highly related to the heuristic information mentioned in Section 3.2.1 and the second-colony's pheromones.The second-colony pheromone matrix is M 2 = {τ 2 (k, i)}, in which k is the number of departments and i is the number of rooms.The transition probability that a room i is assigned to department k can be expressed as Formula (8): in which α, β are the adjustment parameters of pheromone τ 2 (k, i) and heuristic information η(k, i) respectively.The meanings of and Θ can be found in Table 2.
and the second-colony's pheromones.The second-colony pheromone matrix is , in which k is the number of departments and i is the number of rooms.The transition probability that a room i is assigned to department k can be expressed as Formula (8): in which α , β are the adjustment parameters of pheromone 2 ( , ) k i τ and heuristic information ( , ) k i η respectively.The meanings of and Θ can be found in Table 2.In the phase of pheromone updating, the two colonies use the same elite ant strategy via two pheromone matrixes, M 1 and M 2 (Formulas ( 9)-( 11)):

( ) i
Here, the pheromone τ n 1 (i, k) and τ n 2 (i, k) of node (i, k) in M 1 and M 2 during the iteration n are represented by the same symbol τ n (i, k).ρ ∈ (0, 1) is the pheromone decay parameter, τ n (i, k) is the pheromone increment on all nodes of the current best solution in iteration n, τ bs (i, k) is the pheromone increment of the best-so-far solution X bs = x bs ik , f n is the best objective function value in iteration n, and f bs is the best function value of the best-so-far solution.Q is a predefined constant, which is used to ensure that the pheromone increments, τ n (i, k) and τ bs (i, k), are not too large to lead to a local optimal solution or too small to result in slow convergence relative to the pheromone τ n (i, k) and τ bs (i, k).

Local Search
In this MACO, if all ants finish constructing solutions, a greedy local search strategy, swap exchange, is used to further improve the solution quality.This strategy swaps two rooms that were originally assigned to different departments to generate a new solution (shown in Figure 3).Because a local search is a time consuming operation, it is only applied to the best solution in the current iteration X cb .In the phase of pheromone updating, the two colonies use the same elite ant strategy via two pheromone matrixes, 1 M and 2 M (Formulas ( 9)-( 11)): / 1 ( , ) 0 0 Here, the pheromone 1 ( , ) M during the iteration n are represented by the same symbol is the pheromone decay parameter, is the pheromone increment on all nodes of the current best solution in iteration n , is the pheromone increment of the best-so-far solution , n f is the best objective function value in iteration n , and bs f is the best function value of the best-so-far solution.Q is a predefined constant, which is used to ensure that the pheromone increments,

Local Search
In this MACO, if all ants finish constructing solutions, a greedy local search strategy, swap exchange, is used to further improve the solution quality.This strategy swaps two rooms that were originally assigned to different departments to generate a new solution (shown in Figure 3).Because a local search is a time consuming operation, it is only applied to the best solution in the current iteration cb X .The procedure of the local search can be expressed as follows.
1. Calculate the accumulated connectivity cost between each room that is assigned to department k and the other rooms.2. Select the number of rooms arg max { | 1} and all unallocated rooms The procedure of the local search can be expressed as follows. 1.

Calculate the accumulated connectivity cost
x jk between each room that is assigned to department k and the other rooms.

2.
Select the number of rooms i k = argmax i {h i |x ik = 1} and all unallocated rooms Randomly swap two rooms R i , R j , i ∈ I swap , j ∈ I swap , and calculate the new solution's objective function value.Find the swap operation with the largest improvement value, execute this swap to obtain a new solution X , and let X cb = X .

Overall Procedure
The overall procedure can be explicitly described as follows.
Input: (1) Indoor connective map, which includes allocable rooms, building exits, room areas, and connectivity costs; (2) allocation demand data, such as department types and each department's spatial area requirements; and (3) ACO parameters, such as population size SN, adjustment parameters of the pheromone and heuristic information γ, α, β, pheromone update constant Q and decay parameter ρ, and the maximum iteration number N iter .
Step 1: Initialize the data, such as the pheromone matrix M 1 and M 2 and the iteration number g = 0.
Step 2: Execute Steps 2.1-2.3 by each ant to construct solutions.
Step 2.1: The ant a in the first ant colony determines the departments' allocating order.Execute steps 2.1.1-2.1.5.
Step 2.1.2:If k ≤ N p + N b , go to step 2.1.3,otherwise, go to step 2.2.
Step 2.1.3:Calculate the transition probability by Formula (7) according to pheromone matrix M 1 .
Step 2.1.4:Generate a random number r, select the value q(q = argmin F q ≥ r ) as the allocating order of department k, φ(k) = q.
Step 2.1.5: Step 2.2: Based on the order obtained in Step 2.1, the ant a in the second colony assign rooms to each department to obtain a solution.Execute steps 2.2.1-2.2.10.
Step 2.2.1:Set departments' counter k = 1, the allocable rooms set R = {1, 2, • • • , N r }, and the allocation solution as a zero matrix X = 0 N r ,N p +N b .
Step 2.2.2:If k ≤ N p + N b , go to step 2.2.3, otherwise, go to step 2.3.
Step 2.2.3:Determine the department q that will be allocated in the current calculation, q = φ(k).
Step 2.2.4:Calculate the heuristic information according to Section 3.2.1.
Step 2.2.5:Calculate the transition probability by Formula (8) according to the pheromone matrix M 2 and the heuristic information obtained in step 2.2.4.
Step 2.2.6:Calculate the distribution of transition probabilities, Step 2.2.7:Generate a random number r, and select the value t(t = argmin{F t ≥ r}) as the room that was allocated to department q, x (a) tj = 1 j = q 0 j = q .
Step 2.2.8:Update the set of allocable rooms, R = R − {t}.
Step 2.2.9:Step 2.3.3:Update the current-best objective function value f cb = f , the current best allocating order of departments Φ cb = Φ, and the current-best room allocation solution Step 2.4: a = a + 1, if a ≤ N ant , go to step 2.1, otherwise, go to step 3.
Step 3: Apply local search to the best solution X cb in the current iteration to further improve the quality of the current-best solution.
Step 4: Update the best-so-far solution.
Step 4.1: If f cb < f bs , go to step 4,2, otherwise, go to step 5.
Step 4.2: Update the best-so-far objective function value f bs = f cb , the best-so-far allocating order of departments Φ bs = Φ cb , and the best-so-far room allocation solution X bs = X cb .
Output: The best-so-far solution X bs .

Time Complexity
In this paper, the quantities of departments and rooms are N p + N b and N r , respectively, the maximum iteration number is N iter , and the size of ant colony is N ant .The MACO algorithm's computational time complexity can be analyzed as follows.
As shown in Table 3, the time complexity of the objective function value calculation is , explicitly shown in Table 4.
Therefore, after N iter iterations, the total time complexity is

Main Steps Computational Complexity
Calculating Cost 1 using Formula (1) O(N p + N b ) Calculating Cost 2 using Formula (2) O (N p + N b ) 2 Calculating Cost 3 using Formula (3) O(N r ) Table 4. Computational time complexity of ants' behaviors in each iteration.

Main Steps Computational Complexity
For the first ant colony Determine the optimal order of allocating departments For the second ant colony Assigning rooms to each department and calculating the objective function value Applying local search to the current-best solution and calculating the objective function value

Experiment
In this experiment, the proposed MACO algorithm is coded in MATLAB 2012b software and implemented on a PC with an Intel (R) Xeon (R) CPU E3-1230 @ 3.3 GHz and 16 GB RAM using the Windows 7 64-bit operating system.

Experimental Data Description
This paper uses an office building as a case study.The building contains five floors, three elevators, and three staircases.There are 145 allocable rooms of different areas.The total area is 3089 m 2 , the smallest area is 8 m 2 , and the largest area is 36 m 2 .Considering factors such as electric energy savings and strenuous stair climbing, the connectivity cost of each elevator that connects two adjacent floors is 10 meters, and each staircase's connectivity cost is 12 m.The connectivity cost of rooms on the same floor is set as its practical connective distance.
The office building's indoor connective map can be obtained through the software of ARCGIS 10.0, which is shown in Figure 4.There are 16 departments to be allocated, and their minimum area requirements are listed in Table 5.There are 16 145 total candidate solutions in this case study.

Experiment
In this experiment, the proposed MACO algorithm is coded in MATLAB 2012b software and implemented on a PC with an Intel (R) Xeon (R) CPU E3-1230 @ 3.3 GHz and 16 GB RAM using the Windows 7 64-bit operating system.

Experimental Data Description
This paper uses an office building as a case study.The building contains five floors, three elevators, and three staircases.There are 145 allocable rooms of different areas.The total area is 3089 m 2 , the smallest area is 8 m 2 , and the largest area is 36 m 2 .Considering factors such as electric energy savings and strenuous stair climbing, the connectivity cost of each elevator that connects two adjacent floors is 10 meters, and each staircase's connectivity cost is 12 meters.The connectivity cost of rooms on the same floor is set as its practical connective distance.
The office building's indoor connective map can be obtained through the software of ARCGIS 10.0, which is shown in Figure 4.There are 16 departments to be allocated, and their minimum area requirements are listed in Table 5.There are 145  16 total candidate solutions in this case study.

MACO Parameter Selection
The main parameters concerning MACO include SN, α, β, γ, ρ, Q, and N iter .In this experiment, the converging condition is set as N iter = 500, or the current-best solution is the best-so-far solution for ten successive times.Based on the preliminary experiment and experiences [19,24,25], an orthogonal experimental approach was used to determine the values of these parameters among the following value ranges: SN ∈ {20, 40, 60, 80, 100}, α ∈ {1, 3, 5, 7, 9}, β ∈ {1, 3, 5, 7, 9}, γ ∈ {1, 3, 5, 7, 9}, ρ = {0.9, 0.95, 0.99, 0.995, 0.999}, and Q ∈ 10 3 , 10 4 , 10 5 , 10 6 , 10 7 .The parameter selection experiments were designed as shown in Table 6.Each experiment was run ten times.Based on the range analysis method of orthogonal experiments [26], the results are summarized in Table 7. Ki is the average value of all solutions' objective function value, while the corresponding parameter value is set as the ith value in its candidate value range.For example, the number 25.39355 in the first row and first column refers to the average objective value of all solutions with SN = 20.The range R is the gap between the maximum and minimum value, which reflects the objective's fluctuation range with the change of a single parameter's value.A larger value of R implies a more important influence of the corresponding parameter on the final results.Therefore, the primary order of the six parameters is β > Q > α > γ > ρ > SN.The optimal parameters' value is the ith value in its candidate range if Ki maintains the minimum objective value.Therefore, the suggested parameter values are SN = 80, α = 1, β = 5, γ = 1, ρ = 0.9, and Q = 1000.

Experimental Results and Analysis
Based on the parameter selection experiments, we obtain a set of parameters SN = 80, α = 1, β = 5, γ = 1, ρ = 0.9, and Q = 1000, that are expected to achieve favorable results.
One optimal MACO solution was selected for result analysis, and its statistic result is summarized in Table 8.Because of the area-weighted connectivity cost in the optimization model, it is impossible for an optimal solution to assign too many rooms to a department.From the table, we find that the area of each department's allocated rooms is close to its required minimal area.This result is reasonable for meeting the sustainable development requirement; the remaining rooms' area should be as large as possible, while ensuring convenience and satisfying all department demands.The solution's spatial allocation is depicted in Figure 5. From the figure, it can be found that almost all of the public departments are centered on the middle floors to reduce the connectivity cost to other business departments, which matches our common experience.Besides, we find that the rooms assigned to the same department are concentrated on the same floor; this condition arises because of the sufficient allocable rooms in each floor and relatively large connectivity cost settings of elevators and staircases between two adjacent floors while considering factors such as electric energy saving and stair climbing.As a result, the unallocated rooms on one floor are not assigned to a department if their areas cannot satisfy any department's minimal requirements.Thus, it is reasonable that some rooms are unallocated on low floors, even though they may increase the connectivity cost of all allocated rooms to building exits.Notably, a few department rooms are not closely concentrated, shown as the rooms in red ovals in Figure 6.In Figure 6A, the rooms of department 3, R1 in the red circle, are not effectively spatially close to other rooms with the same department number, because all the connectivity costs are weighted by room areas.The area of all rooms labeled as department 3 is 80 m 2 , equal to the department's minimal area demand.If room R2 (16 m 2 ) or room R3 (14 m 2 ) but not room R1 (11 m 2 ) are assigned to department 3, the area-weighted connectivity costs would increase and result in a worse objective function value, which was approved by executing local search operations.Similar to the situation that occurred in the third floor (Figure 6B), rooms R4 and R6 with the same department number are separated.From the perspective of spatial aggregation, if the types of rooms R4 and R5 were exchanged, or the types of rooms R6 and R7 were exchanged, the costs within the same department, Cost 1 , would be reduced.However, the exchange trials show that the cost between business and public departments, Cost 2 , will increase at a greater rate, which can be seen in Table 9.It proves the optimality and reasonability of the solution generated by MACO.The proposed MACO algorithm is compared with three other types of ACO methods with different strategies (shown in Table 10).ACO-1 does not use the heuristic information while calculating the transition probability to form a solution.Compared to MACO's overall procedure, ACO-1 will not execute step 2.2.4,and the probability's calculation in step 2.2.5 is based on Formula (7) rather than Formula (8).ACO-2 does not use the local search strategy to further improve the current-best solution's quality, whose procedure is the same as MACO's procedure without step 3. ACO-3 utilizes only one ant colony to construct a solution.Instead of the first ant colony determining the order of allocating departments pseudo-randomly in MACO, the order of allocating departments is totally determined randomly in ACO-3.It means that its overall procedure does not contain all the operations on the first colony in MACO, which mainly include step 2.1 and step 5 concerning the updating pheromone matrix M 1 .
Table 11 clearly shows that MACO using the strategies proposed in this paper outperforms other types of ACO algorithms in quality and stability.The importance of each strategy can be observed.
(1) The experiment of ACO-1 that lacks heuristic information produced the worst results, which indicates that heuristic information plays the most important role in achieving a solution of high quality.(2) The strategy of local search also plays an essential role for satisfactory results since ACO-2 that lacks local search can only obtain results ranking as second best.(3) Relative to the two strategies discussed above, the strategy of a two-colony rule plays a relatively small role in solution quality because ACO-3's results are nearest to the MACO results.However, ACO-3 exhibited the least stability with the largest standard deviation.
The approximate computation time of these three strategies, heuristic information, local search, and two-colony rules was 0.7963, 0.2436, and 0.1849 s per iteration, respectively.These values are shown in Figure 7 with the objective function value gap from MACO without using one of these strategies.Figure 7 shows that the heuristic information strategy is relatively time consuming, but it is the most effective strategy to improve the solution quality.The total computation time of MACO is acceptable for practical application.The approximate computation time of these three strategies, heuristic information, local search, and two-colony rules was 0.7963, 0.2436, and 0.1849 s per iteration, respectively.These values are shown in Figure 7 with the objective function value gap from MACO without using one of these strategies.Figure 7 shows that the heuristic information strategy is relatively time consuming, but it is the most effective strategy to improve the solution quality.The total computation time of MACO is acceptable for practical application.Taking each experiment's best result as an example, the best-so-far solution found in each iteration of each algorithm is depicted in Figure 8. Taking each experiment's best result as an example, the best-so-far solution found in each iteration of each algorithm is depicted in Figure 8. Taking each experiment's best result as an example, the best-so-far solution found in each iteration of each algorithm is depicted in Figure 8.The curve of ACO-1 shows that this algorithm always has the worst solution with the largest objective function value during the optimization procedure, which implies that it cannot achieve a satisfactory result without the incorporation of the heuristic information.The curves of MACO, ACO-2, and ACO-3 indicate that the objective function values are evidently optimized before the 200th iteration and that these three algorithms have similar performance while exploring new solutions.However, with the implementation of optimization, if the iteration is more than 300, MACO can achieve better solutions than ACO-2 and ACO-3.Different from ACO-2 and ACO-3, both MACO and ACO-1 provide convergence because the optimal solution is found ten successive times within 500 iterations, which means that the strategies of heuristic information and two-colony rules can effectively reduce a solution's randomness while ensuring its diversity.

Comparison of the Different Algorithms
In order to validate the algorithm's generality and effectiveness, we use three sets of simulated data and two different intelligent algorithms, Genetic Algorithm (GA) and Particle Swarm Optimization (PSO), to make comparisons.The simulated data include randomly generated indoor spatial data (shown in Figure 9) and allocation requirements (Table 12).exchange the department types of two randomly selected rooms with the same position in two solutions, and mutation operations that swap the department types of two randomly selected rooms with different positions in a solution, are combined together to generate new solutions.Similar to [8], the PSO in this comparison experiment adopts a solution neighborhood search rule with the same genetic reproduction mechanisms as GA, namely crossover and mutation, to generate new solutions.It is notable that non-feasible solutions will be easily generated by such neighborhood search strategies.Therefore, the following two steps will be adopted to adjust the non-feasible solution to being feasible.
Step 1.For each department k whose allocated room area A allocated k is larger than its minimal requirement A min k , randomly select a room with the department type k and set its status as unallocated until A allocated k ≤ A min k .
Step 2. For each department k (A allocated k < A min k ), pseudo-randomly assign a room to it according to the probabilities determined by heuristic information mentioned in Section 3.2.1 until the department's area demand is satisfied.
After thirty calculations with the convergent condition that the current-best solution is the best-so-far solution for ten successive times, the statistical results are listed in Table 13.It clearly shows that MACO outperforms GA and PSO in the problem of indoor room allocation with smaller objective function values and standard deviations.

Discussion and Conclusions
Similar to city land use allocation, indoor spatial optimal allocation is a complex process in which the complexity of searching for an optimum solution increases enormously with increases in the number of objects to be allocated and the size of the data set.However, indoor spatial optimal allocation has its own distinguishing characteristics.One is that human behavior should be considered in optimization modeling.The other is that the solving algorithm for this discrete domain problem is different since the constraints of the optimization model are more complex.Therefore, this paper derives an indoor spatial allocation model by minimizing certain area-weighted connectivity costs and proposes a MACO algorithm to solve the problem.The proposed algorithm contains three effective strategies, heuristic information, two-colony rules, and local search.A series of experiments proves that MACO is an efficient technique for generating alternative indoor allocation patterns.
This paper focused primarily on the application of an office building's indoor spatial optimal allocation.Based on the model proposed in this paper, the objective function and constraints could be added or modified for different allocation demands in other application scenarios.The solution is easily extended to other indoor spatial allocation problems, such as allocation in school buildings and commercial centers.The indoor map processing and model optimization algorithm proposed in this paper is versatile and can accommodate other indoor spatial allocation problems.
However, some potential limitations exist that can be summarized from two points of view.First, the proposed model of indoor spatial optimal allocation is a simple version of a practical problem.For example, (1) only two types of departments, business and public, are considered in this model, (2) the tightness differences between different business departments and public departments are not considered, and (3) the demand differences of different departments for floors are not considered.Based on certain supportive data, these limitations could be eliminated.For the first limitation, the parameters of department type could be extended.For the second, the connectivity costs between business and public departments could have different weights.The higher the weight is, the closer the two departments are.For the third limitation, an index of demand suitability could be proposed, and an objective function that maximizes the total suitability could be established.
Second, ACO is a type of random algorithm, which means that it does not necessarily find the best solution; it can only provide a set of optimal solutions for the decision maker.In addition, as the scale of the data rises, the computation time of ACO increases dramatically.Methods to improve its calculation efficiency are a recommended topic for further study.
is extremely difficult to find the best solution by greedy searches.

Figure 1 .
Figure 1.Representation of indoor spatial data.

Figure 1 .
Figure 1.Representation of indoor spatial data.

Figure 2 .
Figure 2. Solution representation of indoor spatial allocation.The solution can be represented as a vector of N r dimensions.The assigned department number of zero indicates that the room is not assigned to any department.

Figure 2 .
Figure 2. Solution representation of indoor spatial allocation.The solution can be represented as a vector of Nr dimensions.The assigned department number of zero indicates that the room is not assigned to any department.
too large to lead to a local optimal solution or too small to result in slow convergence relative to the pheromone

Figure 3 .
Figure 3. Swap move of the local search.

Figure 3 .
Figure 3. Swap move of the local search.
which is governed by the calculation of Cost 2 and Cost 3 .The time complexity of the ant's behavior is O N ant × (N b + N p ) 4 + N r 3

Figure 4 .
Figure 4. Indoor connective map of the office building in the case study.

Figure 4 .
Figure 4. Indoor connective map of the office building in the case study.

Figure 5 .
Figure 5.The spatial representation of the multiple ant colony optimization (MACO) solution.Figure 5.The spatial representation of the multiple ant colony optimization (MACO) solution.

Figure 5 .
Figure 5.The spatial representation of the multiple ant colony optimization (MACO) solution.Figure 5.The spatial representation of the multiple ant colony optimization (MACO) solution.

Figure 5 .
Figure 5.The spatial representation of the multiple ant colony optimization (MACO) solution.

Figure 6 .
Figure 6.The plans of two floors in which the departments in red ovals are not spatially aggregate.Figure 6.The plans of two floors in which the departments in red ovals are not spatially aggregate.

Figure 6 .
Figure 6.The plans of two floors in which the departments in red ovals are not spatially aggregate.Figure 6.The plans of two floors in which the departments in red ovals are not spatially aggregate.
ISPRS Int.J. Geo-Inf.2017, 6, 161 16 of 20 quality because ACO-3's results are nearest to the MACO results.However, ACO-3 exhibited the least stability with the largest standard deviation.

Figure 7 .
Figure 7.Comparison of the objective function value gap from MACO without using one of these strategies and each strategy's computation time.

Figure 7 .
Figure 7.Comparison of the objective function value gap from MACO without using one of these strategies and each strategy's computation time.

Figure 7 .
Figure 7.Comparison of the objective function value gap from MACO without using one of these strategies and each strategy's computation time.

Figure 8 .
Figure 8. Best-so-far solutions during 500 iterations.MACO and ACO-1 stopped at the 383rd and 257th iteration, respectively, because of the convergence condition: the current-best solution is the best-so-far solution for ten successive times.

Figure 8 .
Figure 8. Best-so-far solutions during 500 iterations.MACO and ACO-1 stopped at the 383rd and 257th iteration, respectively, because of the convergence condition: the current-best solution is the best-so-far solution for ten successive times.

Table 1 .
The mathematic symbols in indoor room optimal allocation.
k Each office department's demand, the minimum working area A iThe area of each allocable room TB Department type-business departments TP Department type-public departments N p to step 2.2.10, otherwise, go to step 2.2.4.Step 2.2.10: k = k + 1. Go to step 2.2.2.Step 2.3: Update the current-best solution.Step 2.3.1:Calculate the objective function value f according to Formulas (1)-(4).Step 2.3.2:If f < f cb , go to step 2.3.3,otherwise, go to step 2.4.

Table 3 .
Computational time complexity of the objective function value calculation.

Table 5 .
The allocation requirements of the office building in the case study.

Table 7 .
Results of the orthogonal experiments.The bold numbers are the minimal value in each column in the first five rows.

Table 8 .
Statistics of each department's allocated rooms.
Note: * A department ID of zero refers to the unallocated rooms.

Table 9 .
Comparison of the exchange trials while validating the optimality of the solution generated by MACO.The bold numbers are the minimal value among all comparisons.

Table 13 .
Statistical results of the different algorithms' comparison experiments.