A new algorithm for finding minimum spanning trees with undirected neutrosophic graphs

In this paper, we discuss the minimum spanning tree (MST) problem of an undirected neutrosophic weighted connected graph in which a single-valued neutrosophic number, instead of a real number/fuzzy number, is assigned to each arc as its arc length. We define this type of MST as neutrosophic minimum spanning tree (NMST). We describe the utility of neutrosophic numbers as arc lengths and its application in different real world MST problems. Here, a new algorithm for designing the MST of a neutrosophic graph is introduced. In the proposed algorithm, we incorporate the uncertainty in Kruskal algorithm for designing MST using neutrosophic number as arc length. A score function is used to compare different NMSTs whose weights are computed using the addition operation of neutrosophic numbers. We compare this weight of the NMST with that of an equivalent classical MST with real numbers as arc lengths. Compared with the existing algorithms for NMST, the proposed algorithm is more efficient due to the fact that the addition operation and the ranking of neutrosophic number can be done in straightforward manners. The proposed algorithm is illustrated by numerical examples.

1 Introduction Zadeh (1965) introduced the theory of fuzzy sets, which capture natural phenomenon of imprecision and uncertainty.The characteristic of fuzzy set, namely the membership function, is a function whose range is between 0 and 1.Since then, fuzzy sets has been used to model many real life problems in various fields.Classical fuzzy set (type-1 fuzzy set), whose membership degrees/functions are single values/classical sets, is not able to handle different kinds of uncertainty that appears in real life scenarios.Turksen (1986) introduced the idea of interval valued fuzzy sets and Atanassov (1986) proposed the intuitionistic fuzzy sets to handle with the lack of non-membership degrees of fuzzy sets.Intuitionistic fuzzy sets have been widely used in optimization problems, decision making, neural network, medical diagnosis, and so forth.An intuitionistic fuzzy set is an extension of standard fuzzy set that assigns not only to each element a membership degree and but also a non-membership degree.It is more flexible to handle the uncertainty of real life scenarios than the standard fuzzy set.The membership degree, non-membership degree and hesitation degree of an element in the intuitionistic fuzzy set may not be a real number.Atanassov and Gargov (1989) extended the concept of intuitionistic fuzzy sets to the interval valued intuitionistic fuzzy sets to handle more uncertainty than intuitionistic fuzzy sets.To handle the uncertainty due to the hesitance in representing their preference over elements in an optimization, hesitant fuzzy sets were proposed by Torra (2010) and Torra and Narukawa (2009).
Although the fuzzy set and fuzzy logic have been applied to solve many real life problems, it cannot represent many type of uncertainties properly.For example, uncertainties in the inconsistent information and indeterminate information cannot be expressed by fuzzy set.If we want to know the opinion of a decision maker about a statement, decision maker may say that the possibility of truthfulness in the statement is 0.6, the possibility of false in the statement is 0.7 and the possibility of not sure is 0.4.This type of real life scenarios cannot be represented by fuzzy set.Therefore, we need some a new concept to handle this scenarios.Smarandache (1998) proposed the concept of neutrosophic set (NS) from the philosophical point of view, to represent uncertain, imprecise, incomplete, inconsistent, and indeterminate information that exist in the real world problems.NS is characterized by a truth-membership function (t), an indeterminate-membership function (i) and a falsemembership function (f) independently, which are within the real standard or non-standard unit interval ]0, 1+[.The neutrosophic set model is an important tool for dealing with real scientific and engineering applications because it can handle not only incomplete information but also the inconsistent information and indeterminate information as shown in Broumi et al. (2016), Ngan et al. (2016), Wijayanto et al. (2016), Thanh et al. (2017), Phong and Son (2017), Ali et al. (2017Ali et al. ( , 2018a, b, c), b, c).
Minimum spanning tree (MST) is a fundamental and well-known optimization problem in graph theory (Chen and Chang 2001;Dey et al. 2015;Dey and Pal 2013).It aims to find the minimum weighted spanning tree of a weighted connected graph.MST has many real life applications, including communications, transportation, image processing, logistics, wireless telecommunication networks, cluster analysis, data storage and speech recognition.In the classical MST problem, the arc lengths are assumed to be fixed and decision maker uses crisp values to represent the arc lengths of a connected weighted graph.However, in real world scenarios, the arc length of a graph may represent a parameter which may not have a precise value, e.g., demand, cost, time, traffic frequencies, capacities, etc. (Pedrycz and Chen 2011, 2014, 2015;Dey et al. 2016).As an example on road networks, even though the geometric distance is fixed, arc length representing the vehicle travel time may fluctuate due to different weather condition, traffic flow or some other unexpected factors (Dey et al. 2016).Therefore, it becomes hard for decision makers to estimate proper edge cost in crisp values.
In general, decision makers use possible values of arc lengths in linguistic terms, approximate intervals, etc.In such real time scenarios, the arc lengths can be expressed as about 30 minute, around 30-90 min, nearly 90 min, between 90 and 110 min, etc. Fuzzy set is one of the most important mathematical tools to handle the uncertainty of the model (Chen 1996;Chen et al. 1997Chen et al. , 2001Chen et al. , 2006;;Chen and Hsiao 2000;Wang and Chen 2008;Horng et al. 2005;Chen and Hong 2014).Most of the researchers have used type-1 fuzzy set to express those uncertain arc weights.Type-1 fuzzy set is unable to directly model properly such uncertainties because their membership values are totally crisp.Neutrosophic graph can be introduced as an alternative to fuzzy graph to deal with this uncertain situation.
The MST problem has received researchers attention over last decades and several approaches have been proposed to solve MST problem in deterministic graphs.[See Kruskal (1956), Prim (1957), Bondy and Murty (1976), Dijkstra (1959) and Harel and Tarjan (1984)].Kruskal (1956) algorithm is one of the simple and effective algorithm to find the MST.We can calculate the MST using Kruskal algorithm if the arc costs of a graph are fixed.Uncertainty exists in almost every real life applications of MST problems.Uncertainty of parameters come from two different sources: randomness and vagueness or incomplete information.The randomness of a stochastic problem can be handled by probability theory.Due to this reason, some researches represent the arc of a MST problem as a random variables.Ishii et al. (1981) described the MST problem with random arc costs.Ishii and Matsutomi (1995) proposed a polynomial time algorithm to solve the MST problem.In this algorithm, the parameters of the probability distributions of the arc costs are unknown and the parameters are estimated by applying a confidence region from stochastic data.However, in many real world problems, the parameter values are vague or incomplete in nature.Itoh and Ishii (1996) first proposed the MST problem with fuzzy arc costs as a chance-constrained programming.Their idea was based on necessity measure.Chang and Lee (1999) introduced the MST problem whose arc costs are fuzzy.They used three approaches based on the overall existence ranking index for ranking fuzzy arc costs.Based on fuzzy set and probability theory, de Almeida et al. ( 2005) introduced a genetic algorithm for MST problem with fuzzy parameters.Janiak and Kasperski (2008) proposed the MST where the arc costs are represented by fuzzy intervals.They applied the possibility theory to characterize and chose the arcs of a MST for a graph.Zhao et al. (2012) used intuitionistic fuzzy variables to represent the arc length of a intuitionistic fuzzy graph and developed an algorithm to solve this problem.Zhang and Xu (2012) described the MST problem with hesitant fuzzy variables and introduced an algorithmic approach to solve it.
Recently, few researchers have used neutrosophic methods to find minimum spanning tree in neutrosophic environment.Ye (2014) presented a method to find minimum spanning tree of a graph where nodes were samples are represented in the form of NSs and distance between two nodes represents the dissimilarity between the corresponding samples.Kandasamy (2016) proposed a double-valued neutrosophic minimum spanning tree (DVN-MST) clustering algorithm to cluster the data represented by doublevalued neutrosophic information.Mandal and Basu (2016) proposed a new approach of optimum spanning tree problems considering the inconsistency, incompleteness and indeterminacy of the information.They considered a network problem with multiple criteria represented by weight of each edge in neutrosophic sets.It should be noted that the triangular fuzzy numbers and single-valued neutrosophic numbers are similar in mathematical notations, but totally different.To the best of our knowledge, no algorithm exists for MST with neutrosophic arc lengths.
The minimum spanning tree (MST) problem is one of the most well-known optimization problems in graph theory due to its importance to various applications.The uncertainty in the application of MST makes it difficult to find the edge weights exactly.Neutrosophic set and neutrosophic logic are renowned theories, with which one can handle and capture the natural phenomenon of the imprecision and uncertainty in the edge weights of the spanning tree.Neutrosophicness is explored as an alternative to fuzziness for describing uncertainty.The motivation of this work is to find an algorithm for the minimum spanning tree of undirected neutrosophic graph which will be simple enough and efficient in real world scenarios or real life problems.In the past years, there were few methods in Ye (2014), Kandasamy (2016) and Mandal and Basu (2016), to find the MST of a neutrosophic graph.In these algorithms, they can obtain either the cost or the MST of the neutrosophic graph.It is the purpose of this paper to propose a new algorithm that can obtain both of them.
In this paper, we work on MST problem of undirected weighted graph whose arc lengths are represented by neutrosophic number.This work is unique of its kind as there is no such work in the literature done before.An undirected connected neutrosophic graph is considered whose arc length is represented by neutrosophic number.We define this problem as the neutrosophic minimum spanning tree (NMST) problem.The NMST problem, involving addition and comparison operation of neutrosophic numbers, is quite different from the classical MST problem, which involves real numbers only.In an NMST problem, the weights of MST are neutrosophic numbers, and the task is to determine a spanning tree which is smaller than the others.It is not easy, as the comparison of neutrosophic numbers as an operation can be described in a wide variety of ways.We have introduced a modified Kruskal algorithm to solve the NMST problem.The proposed algorithm is used to compute the MST of the neutrosophic graph and its cost.We use the score-based ranking method to choose the minimum arc associated with the lowest value of score.Compared with existing algorithms for NMST, the proposed algorithm is more efficient due to the fact that the addition operation and the ranking of neutrosophic number can be done is a easy and straight manner.A numerical example illustrates the proposed algorithm.
The rest of the paper is organized as follows.Section 2 briefly introduces the concepts of neutrosophic sets, singlevalued neutrosophic sets and the score function of singlevalued neutrosophic number.A mathematical formulation of the NMST problem is given in Sect.3. Section 4 proposes a novel approach for finding the minimum spanning tree of neutrosophic undirected graph.In Sect.5, an illustrative example is presented to illustrate the proposed method.Finally, Sect.6 concludes the paper.

Preliminary
Definition 1 Let be an universal set.The neutrosophic set A on the universal set categorized in to three membership functions called the true T A (x) , indeterminate I A (x) and false F A (x) contained in real standard or non-standard subset of ] − 0, 1 + [ , respectively (Smarandache 1998).
Definition 2 Let be a universal set.The single-valued neutrosophic sets (SVNs) A on the universal is denoted as following (Wang et al. 2010), The functions T A (x) ∈ [0, 1] , I A (x) ∈ [0, 1] and F A (x) ∈ [0, 1] are named as degree of truth, indeterminacy and falsity membership of x in A, satisfy the following condition: Definition 3 Let A = (T, I, F) be a SVNs, a score function S, based on the truth-membership degree (T), an indeterminacy membership degree (I) and a falsity membership degree (F) is defined as follows (Garg 2016):

Problem formulation for NMST
A spanning tree of a connected graph G is a connected acyclic maximum sub-graph which includes all the nodes of G. Every spanning tree has exactly n − 1 arcs, where n is the number of nodes of graph G.A MST problem is to find a spanning tree such that the sum of all its arc length is minimum.The classical MST problem considers the exact weights associated with the arcs of the graph.However, in real world scenarios the arc lengths may be imprecise due to lack of evidence or incompleteness.The effective way to handle with these imprecision is to consider a neutrosophic graph.Consider a neutrosophic graph G, consisting of n number of nodes V = v 1 , v 2 , … , v n and a finite set of m number of arcs E ⊆ V × V .Each arc of the graph is denoted by e, which is an order pair (i, j), where i, j ∈ V and i ≠ j .
If the arc e is present in the NMST then x e = 1, otherwise x e = 0.The cost of all the arcs of graph G is represented by number.We defined the MST of this neutrosophic graph as neutrosophic minimum spanning tree (NMST).The NMST is expressed as the following linear programming problem.

Subject to
Here, A e is a neutrosophic set that represents the length of the arc e ∈ E and ∑ in Eq. ( 5) is the sum of a neutrosophic sets.Equation ( 6) ensures that the number of edges in the NMST is n − 1 .In Eq. ( 7), (s) = {(i, j|i ∈ s, j ∉ s)} is used for the cutset of a subset of vertices s, i.e., the arcs that have one node in the set s and the other one outside the s.Thus, a spanning tree must have at least one arc in the cutset of any subset of the nodes.

Proposed algorithm for NMST
The proposed algorithm is an extension of the Kruskal algorithm for MST problem.We have incorporated the concept of uncertainty in Kruskal algorithm using neutrosophic number as an edge weight.The classical Kruskal algorithm is a MST algorithm which determines an arc of the minimum cost that connects any two trees in the forest.This algorithm is a type of greedy algorithm in graph theory as it determines a MST for a connected weighted graph adding increasing cost arcs at each step.Two key matters are needed to address to modify the Kruskal algorithm to solve the NMST problem.The first is determining the addition operation of two edges to find the cost of the spanning and the second is to compare the costs of the spanning trees of two different spanning trees.Based on the score function of neutrosophic number, the classical Kruskal algorithm can be easily modified to a neutrosophic Kruskal algorithm as follows.
In this algorithm, the variable T is used to represent the NMST and A is the set of all unvisited arc that are to be removed.n is the total number of vertices in the neutrosophic graph G.The main steps of the neutrosophic Kruskal algorithm are shown as follows: Step 1 The score value are computed for all the arc e ∈ E of G, using Eq. ( 4).
Step 2 Arrange all the arcs e ∈ E of G by their correspond- ing score values: least score value first and largest score value last.The score values are used as the edge weights of the neutrosophic graph G.
Step 3 Choose the not-examined edge from the graph G.
Add this chosen arc to the NMST if this will not make a cycle.
Step 4 Stop the process whenever n − 1 arcs have been added to the NMST.The pseudocode of the proposed algorithm is given in Algorithm 1.We use an adjacency matrix to describe the neutrosophic graph.The linear searching method is used to determine the minimum weight edge based on the concept of score of neutrosophic number.The computational complexity of the proposed algorithm is O(V 2 ).

Numerical example
We demonstrate our modified Kruskal algorithm step by step considering an example graph, shown in Fig. 2. The graph G 1 consists of four nodes and five edges.The costs of all edges of the network are in the form of neutrosophic number.We do not find any graph in the literature whose edge costs are given in terms of neutrosophic number.For the graph, shown in Fig. 2, we have generated the values of neutrosophic number and assigned those values to the arcs of the graph randomly.We have to find the MST of the graph G.
Step 1.There are five possible arcs in the graph G.They are, respectively: We have also computed the MST of neutrosophic graph using binary programming.The result for same graph using binary programming with the same arc cost is computed.
Our computed MST is same as the binary programming.It shows the effectiveness of the proposed approach.Here, we consider binary programming as we did not find, best of our knowledge, any existing algorithm for MST on neutrosophic graph.
Compared with existing algorithms for NMST, the proposed algorithm is more efficient due to the fact that the addition operation and the ranking of neutrosophic number can be done is a easy and straight manner.In the existing literature, the works on neutrosophic graph were done by Ye (2014) and Mandal and Basu (2016) where similarity approaches were used to compare the path in a graph with neutrosophic set.The similarity measure of neutrosophic set approach has the limitation of time consumption.In these algorithms, they can obtain either the cost or the MST of the neutrosophic graph.However, the proposed method in this research can obtain both of them.This shows the advantages of the proposal.

Conclusion
This paper investigated the minimum spanning tree problem whose edges weights are represented by neutrosophic numbers.The main contribution of this study is to provide an algorithmic approach to find the minimum spanning tree in uncertain environment using neutrosophic numbers as arc lengths.We have incorporated the concept of uncertainty in Kruskal algorithm using neutrosophic number as an edge weight.The proposed algorithm finds the MST under neutrosophic edge weights based on the score values of neutrosophic numbers.A numerical example was presented to illustrate the mechanism of the proposed algorithm.The proposed algorithm for minimum spanning tree is simple enough and effective for real world scenarios.This work can be extended to the case of directed neutrosophic graphs and other types of neutrosophic graphs such as bipolar neutrosophic graphs, interval valued neutrosophic graphs.
In the future, the proposed algorithm can be applied to real world problems such as in supply chain management, transportation, etc. (Tsai et al. 2008;Chen and Chien 2011;Tsai et al. 2012;Chen and Kao 2013).It should be noted that the uncertainty in the arc length of a MST problem is not limited to the geometrical distance.For example, due to the several reason, the travel cost between two cities may be expressed as a neutrosophic numbers, even if the geometrical distance is fixed.This observation further gives the light for possible expansion.

First
, we consider an undirected weighted graph shown in Fig. 1 and apply Kruskal algorithm to find the MST of G.The Kruskal algorithm finds the MST= {(a, c), (c, d), (b, d)} and the effective weight is 190.
i. (a, b) ii.(a, c) iii.(a, d) iv.(b, d) v. (c, d) Now we compute the score of every arc based on score function, as defined in Eq. (4).The ranks are, respectively, 0.27, −0.73 , 0.115, −0.06 and 0.66 for the arcs (a, b), (a, c), (a, d), (c, d) and (b, d).A stores this five arcs with their corresponding costs.Step 2. The arc (a, c) is the smallest arc as its score −0.73 is lowest among all the values of score of all the arcs in A. The arc (a, c) is inserted in T and the (a, c) is removed from A. Now, the NMST T is {(a, c)}.Step 3. The arc (c, d) is the smallest arc as its score −0.06 is lowest among all the values of score of all the arcs in A. The arc (c, d) is inserted in T and the (c, d) is removed from A. Now, the NMST T is {(a, c), (c, d)}.Step 4. The arc (a, d) is the smallest arc as its score 0.115 is lowest among all the values of score of all the arcs in A. The arc (a, d) is not inserted in T because it creates a cycle.The arc (a, d) is removed from A. The arc (a, b) is the next smallest arc as its score 0.27 is lowest among all the values of score of all the arcs in A and the (a, d) is removed from A. Now, the NMST T is {(a, c), (c, d), (c, d)} .The cost of the NMST is −0.52.

Fig. 1
Fig. 1 An undirected weighted connected classical graph