Artificial Bee Colony for Traveling Salesman Problem

 Abstract—Travelling Salesman Problem (TSP) belongs to the class of NP-Complete problems. It has been proved that evolutionary algorithms are effective and efficient, with respect to the traditional methods for solving NP-Complete problems like TSP, with avoidance trapping in local minima areas. Artificial Bee Colony (ABC) is a new swarm-based optimization algorithm, which inspired by the foraging behavior of honey bees. In ABC, the neighborhood search strategy is employed in order to find better solutions around the previous ones.

The TSP represents the salesman who wants to visit a set of cities exactly once and finally turns back to the starting city. The objective is to determine the tour with minimum total distance.

To solve TSP using ABC algorithm, the position of a food source represents a possible tour and the nectar amount of a food source corresponds to the quality of the tour. In ABC model, the colony consists of three groups of bees: employed bees, onlookers and scouts.


Each employed bee goes to the food source area in her memory and determines a neighbor source, and then come back to the hive and begin dance in dance area. This dance is essential for colony communication, and contains three pieces of information regarding a flower patch: the direction in which it will be found, its distance from the hive and its quality rating (fitness). Provided that the nectar amount of the new selected source is higher than the previous one, the bee memorizes the new source position and forgets the old one. Otherwise she keeps the previous position in her memory. Each onlooker watches the dances of employed bees, and makes decision to choose the food source through the shared information from the dances. Then, some employed bees which found high quality solutions, are chosen as scouts. For each scout, some employed bees are determined to search for finding new food sources in the neighborhood of the solution of the scout.

Problem Representation

TSP can be represented as a graph 𝐺=(𝑉,𝐸), where 𝑉={1,2,...,𝑁} is a set of nodes, and 𝐸= 𝑖,𝑗 𝑖,𝑗 πœ– 𝑉} is the set of all connection edges between them. Each node represents a city, and each edge means the possible path between two related cities. The distance 𝑑𝑖𝑗 is associated with edge (𝑖,𝑗) and represents the Euclidean distance from city 𝑖 to city 𝑗 “Eq. (1)”. The heuristic information is calculated before performing the main algorithm. So, the distances of all edges were calculated and saved.

𝑑𝑖𝑗= sq((π‘₯𝑖−π‘₯𝑗)^2+(𝑦𝑖−𝑦𝑗)^2)            -----1

Iteratively, after construction the solutions, the qualities of the gathered solutions are evaluated by the cost function, which is calculated by sum of the Euclidean distances of the consecutive edges within the our as “Eq. (2)”. Note that the πΆπ‘œπ‘ π‘‘π‘˜ is corresponding to the π‘π‘’π‘’π‘˜.

Secure Software Development Life Cycle (SecSDLC) || Identity Access Management (IAM)


6.3.9 Secure Software Development Life Cycle (SecSDLC) 

The SecSDLC involves identifying specific threats and the risks they represent, followed by design and implementation of specific controls to counter those threats and assist in managing the risks they pose to the organization and/or its customers. The SecSDLC must provide consistency, repeatability, and conformance. The SDLC consists of six phases, and there are steps unique to the SecSLDC in each of phases: 

Phase 1.Investigation: Define project processes and goals, and document them in the program security policy. 

Phase 2.Analysis: Analyze existing security policies and programs, analyze current threats and controls, examine legal issues, and perform risk analysis. 

Phase 3.Logical design: Develop a security blueprint, plan incident response actions, plan business responses to disaster, and determine the feasibility of continuing and/or outsourcing the project. 

Phase 4.Physical design: Select technologies to support the security blueprint, develop a definition of a successful solution, design physical security measures to support technological solutions, and review and approve plans. 

Phase 5.Implementation: Buy or develop security solutions. At the end of this phase, present a tested package to management for approval. 

Phase 6.Maintenance: Constantly monitor, test, modify, update, and repair to respond to changing threats.8 

In the SecSDLC, application code is written in a consistent manner that can easily be audited and enhanced; core application services are provided in a common, structured, and repeatable manner; and framework modules are thoroughly tested for security issues before implementation and continuously retested for conformance through the software regression test cycle. Additional security processes are developed to support application development projects such as external and internal penetration testing and standard security requirements based on data classification. Formal training and communications should also be developed to raise awareness of process enhancements.


 6.3.25 Identity Access Management (IAM) 

As discussed in Chapter 5, identity and access management is a critical function for every organization, and a fundamental expectation of SaaS customers is that the principle of least privilege is granted to their data. The principle of least privilege states that only the minimum access necessary to perform an operation should be granted, and that access should be granted only for the minimum amount of time necessary.17 However, business and IT groups will need and expect access to systems and applications. The advent of cloud services and services on demand is changing the identity management landscape. Most of the current identity management solutions are focused on the enterprise and typically are architected to work in a very controlled, static environment. User-centric identity management solutions such as federated identity management, as mentioned in Chapter 5, also make some assumptions about the parties involved and their related services.

Monk and Inversions

using System; public class Solution { public static void Main () { int T = Convert . ToInt32 ( Console . ReadLine...