WO2020135218A1 - 网络拓扑的确定方法、装置及系统 - Google Patents
网络拓扑的确定方法、装置及系统 Download PDFInfo
- Publication number
- WO2020135218A1 WO2020135218A1 PCT/CN2019/126612 CN2019126612W WO2020135218A1 WO 2020135218 A1 WO2020135218 A1 WO 2020135218A1 CN 2019126612 W CN2019126612 W CN 2019126612W WO 2020135218 A1 WO2020135218 A1 WO 2020135218A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- network element
- ring
- network
- tree
- subnet
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Ceased
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L45/00—Routing or path finding of packets in data switching networks
- H04L45/02—Topology update or discovery
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L12/00—Data switching networks
- H04L12/28—Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
- H04L12/42—Loop networks
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/04—Processing captured monitoring data, e.g. for logfile generation
- H04L43/045—Processing captured monitoring data, e.g. for logfile generation for graphical visualisation of monitoring data
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W40/00—Communication routing or communication path finding
- H04W40/24—Connectivity information management, e.g. connectivity discovery or connectivity update
- H04W40/246—Connectivity information discovery
Definitions
- the invention relates to the field of network technology, and in particular to a method, device and system for determining a network topology.
- Network topology is the physical layout of each network element connected to each other through a transmission medium.
- the network topology is usually obtained according to the connection method of each network element in the network. Obtaining the network topology is an important basis for evaluating, planning, and maintaining the network. Therefore, obtaining the network topology quickly and clearly is an urgent requirement for all services.
- the energy model of the entire network can be established through Hooke's law according to the connection method, and then the network element can be moved iteratively, and the energy When the energy of the model obtains the minimum value, the position corresponding to the minimum value is determined as the position of the network element to obtain the network topology of the network.
- This application provides a method and device for determining a network topology, which can improve the efficiency of acquiring the network topology.
- the technical solutions provided by this application are as follows:
- an exemplary embodiment of the present application provides a method for determining a network topology.
- the method includes: acquiring a connection relationship between a plurality of network elements constituting a network and a network level of each network element.
- the network level uses To reflect the importance of network elements in the network; based on the connection relationship between multiple network elements and the network level of each network element, determine multiple sub-networks; in accordance with the order of network level of network elements in the network from high to low Based on the connection relationship between each network element in each sub-network, the location information of each network element is determined; based on the connection relationship between multiple network elements and the location information of each network element, a network topology is established.
- This application provides a method for determining the network topology. Based on the connection relationship between multiple network elements and the network level of each network element, multiple sub-networks are separately determined, and the network level of the network elements in the network is increased from Low order, based on the connection relationship between each network element in each sub-network, determine the location information of each network element, and establish the network topology based on the connection relationship between multiple network elements and the location information of each network element Compared with related technologies, it can automatically obtain the location information of the network element without manually adjusting the network topology, which effectively improves the efficiency of obtaining the network topology.
- the information realization process may include: sorting the multiple core network elements constituting the core subnet to obtain a first network element queue, and the core network element is the network element with the highest network level among the multiple network elements; obtaining the first network The first spacing between every two adjacent core network elements in the element queue; based on the first spacing and the total number of core network elements, the location information of each core network element is determined.
- multiple core network elements are arranged on the boundary of the first graphic, and the location information of each core network element is determined based on the first distance and the total number of core network elements, including: based on the total number of core network elements, determining The first fixed-length parameter of a graph.
- the first fixed-length parameter is used to reflect the geometric characteristics of the points on the first graph; according to the order of each core network element in the first network element queue, based on the first fixed-length parameter With the first distance, the position information of the core network element is determined in turn.
- the first figure includes: a circle, an ellipse, or a regular polygon.
- obtaining the first distance between every two adjacent core network elements in the first network element queue includes: determining the first distance based on the first total number of drop-down network elements between the two core network elements.
- the first distance is characterized by the first angle between the connection between each core network element and the designated point in the two core network elements, based on the drop network between the two core network elements
- the first total number of elements, determining the first spacing includes: determining the proportion of the first total number to the first total number of the second total number, the second total number is the total number of all down-link network elements of all core network elements; The product of the ratio and 360 degrees is determined as the first included angle.
- the same core network can be guaranteed There is no crossover between all the connected NEs under the yuan.
- the network element whose position information is to be determined is a secondary network element, in accordance with the order of the network level of the network element in the network from high to low, based on the connection relationship between each network element in each sub-network, determine the Location information, including: based on the connection relationship between the network elements, the multiple secondary network elements of the secondary sub-network are divided into multiple first network element groups, and the secondary network elements are directly connected to the core network element among the multiple network elements Connected network elements, the core network element is the network element with the highest network level among multiple network elements; sort at least one secondary network element in each first network element group to obtain a second network element queue; for multiple Sort the first network element group to obtain the network element group queue; determine the layout width of each first network element group based on the third total number of down-linking network elements of all secondary network elements in each first network element group ; Based on the layout width of each first network element group and the order of any first network element group in the network element group queue, determine the layout start position of any first network element group; based
- multiple secondary network elements are arranged on the boundary of at least one second graphic, based on the layout width, the layout start position, the total number of multiple first network element groups, the second network element queue, and the network element group
- the total number of queues and secondary network elements in each first network element group to determine the location information of each secondary network element, including: based on the first network element group where each secondary network element is located in the network element group
- the sequence in the queue determines the second graphic where each secondary network element is located; based on the total number of secondary network elements and the total number of first network element groups, the second fixed-length parameter of each second graphic is determined,
- the second fixed-length parameter is used to reflect the geometric characteristics of the corresponding points on the second graph; in accordance with the order of each secondary network element in the second network element queue and the network element group queue, based on the correspondence of the secondary network elements
- the second fixed-length parameter, layout width, layout start position, and the total number of secondary network elements in the first network element group where each secondary network element is located determine the location information
- each second graphic is located outside the first graphic corresponding to the core network element; and when at least one second graphic is a second graphic, the second graphic includes: A circle, an ellipse, or a regular polygon; when at least one second figure is a plurality of second figures, the overall figure formed by the plurality of second figures includes: concentric circles, concentric ellipses, or concentric regular polygons.
- sorting a plurality of first network element groups to obtain a network element group queue includes: according to the order of the third total number corresponding to each first network element group from large to small, for many The first network element group is initially sorted to obtain the initial network element group queue; according to the order of the target distance corresponding to each first network element group from large to small, the initial network element group queue is reordered to obtain the network element In the group queue, the target distance is the distance from the position of the first network element group in the initial network element group queue to the center position of the initial network element group queue.
- the layout width of each first network element group is characterized by the second included angle between the connection between the two outermost network elements in the first network element group and the designated point, based on each The third total number of down-link network elements of all secondary network elements in a network element group, determining the layout width of each first network element group, including: determining that the third total number corresponding to any first network element group is in the fourth The second total is the proportion of the total, and the fourth total is the total number of down-linking network elements of all secondary network elements in multiple first network element groups; based on the proportion of the second total number corresponding to any first network element group, Determine the second angle of any first network element group.
- the layout start position of each first network element group is characterized by the layout start angle, and the layout start angle is an offset angle of the line connecting the layout start position and the specified point with respect to the specified 0 degree, based on each first network
- the layout width of the tuple and the order of any first network element group in the network element group queue to determine the layout start position of any first network element group including: based on any first network element group in the network element group
- the order in the queue and the layout width of other first network element groups that are located before any first network element group in the network element group queue obtain the layout start angle of any first network element group.
- the position of each network element is determined based on the connection relationship between each network element in each sub-network in the order of the network level of the network element from high to low Information, including: dividing at least one ring-shaped subnet into at least one second network element group, the network elements in the ring-shaped subnet are connected in a ring, and the network elements belonging to the ring-shaped subnet are ring network elements; based on each The fifth total number of ring-shaped subnets in the second network element group determines the layout width of any ring-shaped subnet; determines the graphic parameters of the third graph corresponding to the ring network element of any ring-shaped subnet to form any ring-shaped subnet
- the ring network elements of the subnet are laid out on the boundary of the corresponding third graphics, and the graphics parameters are used to reflect the geometric characteristics of the points on the corresponding third graphics; based on the sixth of the down-linking network elements in any ring-shaped subnet
- the network elements in the network are distributed from top to bottom according to the order of the network hierarchy, based on the sixth total number of bottom-mounted network elements in any ring-shaped subnet, the corresponding graphic parameters, the corresponding layout width, and The location information of the start ring network element and the end ring network element of any ring subnet, to determine the location information of each ring network element in any ring subnet, including: The sixth total number of elements, the corresponding graphic parameters, the corresponding layout width, and the position information of the start ring network element and the end ring network element of any ring-shaped subnet.
- Position information of each ring network element in the first direction based on the corresponding graphic parameters and the position information of any ring network element in the first direction, the position information of any ring network element in the second direction is determined, the second The direction is perpendicular to the first direction.
- the method before determining the graphic parameter of the third graphic corresponding to the ring network element of any ring-shaped subnet, the method further includes: based on the start ring network element of each ring-shaped subnet in any second network element group And the location information of the end ring network element, sort at least one ring-shaped subnet in any second network element group to obtain the first network queue.
- determining the graphic parameters of the third graphic corresponding to the ring network element of any ring-shaped subnet includes: based on the location information of the start ring network element and the end ring network element of the ring-shaped subnet in any second network element group , Determine the position information of the first center of gravity of any second network element group; based on the position information of the first center of gravity of any second network element group, the layout width of any ring-shaped subnet, The sequence in the first network queue and the ring level of any ring-shaped subnet determine at least one target ring network of the ring network element directly connected to the start ring network element and the ring network element directly connected to the end ring network element Position information of the element; based on the position information of the target ring network element corresponding to any ring-shaped subnet and the functional relationship satisfied by the corresponding third figure, the figure parameter is determined.
- the network elements in the network are laid out in a centrifugal layered layout, based on the sixth total number of network elements in any ring-shaped subnet, the corresponding graphic parameters, the corresponding layout width, and any ring-shaped subnet
- the location information of the start ring network element and the end ring network element of the network to determine the location information of each ring network element in any ring subnet, including: the start ring network element and the end ring network based on any ring subnet
- the position information of the element determine the third graphics coordinate system corresponding to any ring-shaped subnet; based on the sixth total number corresponding to any ring-shaped subnet, and the corresponding third graphic coordinate system and corresponding graphic parameters, determine any Location information of each ring network element in the ring-shaped subnet.
- the position information of each ring network element in any ring-shaped subnet is determined, including: The layout width, corresponding sixth total number, corresponding graphic parameters of a ring-shaped subnet, and the distance between the start ring network element and the end ring network element in any ring-shaped subnet Among the included multiple ring network elements, determine the target ring network element that is the apex of any ring-shaped subnet; based on the layout width corresponding to any ring-shaped subnet, the target ring network element is multiple in any ring-shaped subnet The order in the ring network element, the distance between the start ring network element and the end ring network element in any ring-shaped subnet, the third graphics coordinate system corresponding to any ring-shaped subnet and the corresponding graphics parameters, determine each Location information of ring network elements.
- determining the target ring network element as a vertex of any ring-shaped subnet includes: based on the graphic parameters corresponding to any ring-shaped subnet and the corresponding layout width, And the distance between the start ring network element and the end ring network element in any ring-shaped subnet, determine the first arc length and the second arc length of the third graph corresponding to any ring-shaped subnet, and the sum of the first arc length
- the second arc length is the length of the arc located on both sides of the vertex of the third figure; based on the first arc length and the second arc length corresponding to any ring-shaped subnet, and the sixth total number corresponding to any ring-shaped subnet
- determining the third graphical coordinate system corresponding to any ring-shaped subnet includes: The midpoint of the start ring network element and end ring network element of the subnet is determined as the coordinate origin of the third graphics coordinate system corresponding to any ring subnet; to determine the correspondence of the second network element group where any ring subnet is located
- the reference graphic is a circle with the specified fixed length as the radius and the coordinate origin of the corresponding third graphic coordinate system as the center of the circle; determine the target intersection point corresponding to any ring-shaped subnet, and the target intersection point is any ring-shaped sub
- the intersection of the reference graphic corresponding to the second network element group where the net is located and the third connection of any ring-shaped subnet, the vertex of any ring-shaped subnet and the designated point are located on the third connection; the corresponding third The direction of the line connecting the coordinate origin of the graphics coordinate system and the target intersection is determined
- determining the third graphic coordinate system corresponding to any ring-shaped subnet based on the location information of the start ring network element and the end ring network element of any ring-shaped subnet includes: The graphic parameters corresponding to the ring-shaped subnet, determine the first relative position of the geometric center of the third graphic corresponding to any ring-shaped subnet in the third graphic; based on the first relative position and correspondence corresponding to any ring-shaped subnet The width of the layout, determine the second relative position of the geometric center of any ring-shaped subnet in the target second network element group where any ring-shaped subnet is located; based on the second relative position and attribution of any ring-shaped subnet The position information of the point determines the position information of the geometric center corresponding to any ring-shaped subnet.
- the attribution point is a ring network element coexisting in at least one ring-shaped subnet in the target second network element group;
- the position information of the geometric center corresponding to the net is determined as the position information of the origin of the corresponding third graphics coordinate system, and the direction of the connection line between the geometric center corresponding to any ring-shaped subnet and the corresponding attribution point is determined to be any ring
- the first direction of the third graphics coordinate system corresponding to the type subnet determines the direction perpendicular to the first direction as the second direction of the third graphics coordinate system corresponding to any ring-shaped subnet.
- determining the graphic parameters of the third graphic corresponding to the ring network element of any ring-shaped subnet includes: estimating the third corresponding to any ring-shaped subnet based on the sixth total number corresponding to any ring-shaped subnet The first perimeter of the graphic; based on the perimeter formula of the third graphic corresponding to any ring-shaped subnet, determine the second perimeter of the third graphic; based on the first and second perimeters, obtain any ring type Graphic parameters corresponding to the subnet.
- obtaining the graphic parameters corresponding to any ring-shaped subnet includes: based on the first perimeter and the second perimeter corresponding to any ring-shaped subnet, obtaining any ring The first sub-parameter in the graphic parameters corresponding to the subnet of the type; based on the first subparameter corresponding to any ring-shaped subnet, the layout width corresponding to any ring-shaped subnet, and the start ring network in any ring-shaped subnet The distance between the element and the end ring network element determines the other sub-parameters in the graphics parameters corresponding to any ring-shaped subnet to obtain the graphic parameters corresponding to any ring-shaped subnet.
- At least one ring-shaped subnet is divided into at least one second network element group, including: the ones with the same start ring network element and the same end ring network element
- the ring-shaped subnets are divided into the same second network element group to obtain at least one second network element group.
- At least one ring-shaped subnet is divided into at least one second network element group, including: ring-shaped subnets with the same ring level Divide into the same second network element group to obtain at least one second network element group.
- the layout width of any ring-shaped subnet is characterized by the third angle of any ring-shaped subnet, and any ring-shaped subnet is determined based on the fifth total number of ring-shaped subnets in each second network element group
- the layout width of the network includes: determining the quotient of 180 degrees corresponding to the fifth total number corresponding to any second network element group as the third included angle occupied by each ring-shaped subnet in any second network element group.
- the layout width of any ring-shaped subnet is characterized by the third angle of any ring-shaped subnet. Based on the fifth total number of ring-shaped subnets in each second network element group, the Layout width, including: determining the fourth angle formed by the first connection and the second connection, the first connection is the connection between the ring network element and the specified point in any second network element group, and the second connection The line is the connection between the ring network element and the designated point in any second network element group;
- the quotient of the fourth angle and the total number of targets is determined as the third connection of every two adjacent ring-shaped subnets in any second network element group At the third angle between the lines, the vertex of the ring-shaped subnet and the designated point are located on the third connection, and the total number of targets is equal to the fifth total corresponding to any second network element group minus one.
- the layout width of any ring-shaped subnet is characterized by the third angle of any ring-shaped subnet, based on each second
- the fifth total number of ring-shaped subnets in the network element group to determine the layout width of any ring-shaped subnet includes: determining the layout width of any ring-shaped subnet based on the sixth total number corresponding to any ring-shaped subnet.
- the position of each network element is determined based on the connection relationship between each network element in each sub-network in the order of the network level of the network element from high to low Information, including: determining the first root network element among the multiple tree network elements that make up the tree-shaped subnet, the network elements in the tree-shaped subnet are connected in a tree shape, and the network elements that belong to the tree-shaped subnet are tree network elements ; Get the layout start position and layout width of each tree network element; based on the layout start position and layout width of any other tree network element, and the location information of the first network element, determine the location information of any other tree network element
- the other tree network element is a tree network element except the first root network element among the multiple tree network elements.
- the method before determining the location information of any other tree network element based on the layout start position and layout width of any other tree network element and the location information of the first network element, the method further includes: obtaining each other network element depth.
- the layout start position and layout width of any other tree network element determines the location information of any other tree network element, including: based on the depth of any other tree network element, The layout start position and layout width, and the location information of the first network element determine the location information of any other tree network element.
- the layout start position of each tree network element is characterized by the layout start angle
- the layout start position of each tree network element is obtained, including: based on the location information of the first root network element, the first root network element and the designated The straight line where the point is located is determined as the target straight line; the angle between the target ray and the specified straight line is determined as the layout start angle of the first network element.
- the target ray is a ray perpendicular to the target straight line and the emission direction deviates from the specified point; or,
- the starting angle of a network element layout is -180 degrees.
- the layout start position of each tree network element is characterized by the layout start angle
- the layout start position of each tree network element is obtained, including: according to the connection relationship between the tree network elements, multiple children connected to the same parent network element
- the network elements are sorted to obtain the third network element queue; based on the layout start angle, layout width and width of the parent network element connected to any other tree network element, and the sequence is located in any other tree network in the third network element queue
- the width of other tree network elements before the element determines the starting angle of the layout of any other tree network element.
- the layout width of each tree network element is characterized by a fifth angle
- obtaining the layout width of each tree network element includes: the fifth angle of the first network element is 180 degrees; and /Or determine any other tree network element based on the connection relationship between the tree network elements, based on the width of any other tree network element, and the fifth angle and width of the parent network element to which any other tree network element is connected The fifth angle.
- the order of the network levels of the network elements in the network from high to low based on the connection relationship between each network element in each sub-network, determine the location information of each network element, and also include: The second network element in the subnet is sorted to obtain a fourth network element queue.
- the network elements in the isolated tree subnet are connected in a tree shape, and the network elements belonging to the isolated tree subnet are isolated tree network elements and isolated trees. There is no connection path between the network element and the core network element.
- the core network element is the network element with the highest network level among multiple network elements; based on the specified radius, the sum of the widths of all second network elements, and the fourth network The sum of the widths of other second network elements that are located before any second network element in the element queue in sequence determines the location information of any second network element.
- the layout start position of each tree network element is characterized by the layout start angle, and obtaining the layout start position of each tree network element includes: based on the order of any second in the fourth network element queue The width of other second root network elements before the root network element determines the starting position of the layout of the second root network element.
- the layout width of each tree network element is characterized by a fifth angle
- obtaining the layout width of each tree network element includes: obtaining each tree according to the connection relationship between the tree network elements The width of the network element; based on the width of each tree network element, determine the layout width of each tree network element.
- multiple other tree network elements connected to the same first root network element are arranged on a circle with the first root network element as the center and a specified length as the radius.
- the layout width of the tree network elements can be allocated according to the width of the tree network elements, thereby ensuring that no crossover occurs between all tree network elements under the same root network element.
- the network level of the network element in the network is from high to low, based on each network element in each subnetwork.
- To determine the location information of each network element including: acquiring the location information of the second center of gravity of the overall network composed of multiple tree subnets; acquiring the width of each tree subnet; according to each tree subnet
- the location information of the third network element of the network sorts multiple tree subnets to obtain a second network queue; based on the width of each tree subnet, the location information of the second center of gravity, and the second network queue
- the width of the other tree-type subnets in the order before any tree-type subnet is determined, and the position information of the third network element of any tree-type subnet is determined; according to the connection relationship between the tree network elements, the same parent
- the multiple sub-network elements connected to the network element are sorted to obtain the fifth network element queue; based on the location information of the parent network
- multiple sub-networks are separately determined, including: determining the network composed of core network element connections as the core sub-network, the core network element is the network with the highest Network element at the level.
- a plurality of sub-networks further including: determining a network composed of other network elements connected in a ring as a ring-shaped sub-network , Other network elements are network elements other than the core network element in the network; and/or, the network composed of other network elements connected in a tree shape is determined as a tree-shaped subnet.
- the network elements in the network topology start with the network element with the highest network level and are distributed from inside to outside in the order of the network level from high to low. At this time, the distribution positions of multiple network elements in the obtained network topology are more uniform, which can make the layout of the network topology more beautiful, and when constructing the network according to the network element topology, the interference between the network elements can be reduced.
- the network elements in the network topology start with the network element with the highest network level and are distributed from top to bottom in the order of network level from high to low. At this time, the topology level of the network element in the obtained network topology is clearer, and the structure of the network, the network layer of the network element, and the relationship between different subnets can be presented more clearly.
- an exemplary embodiment of the present application provides an apparatus for determining a network topology.
- the apparatus includes: an acquiring module configured to acquire a connection relationship between a plurality of network elements used to form a network and a network of each network element Level, the network level is used to reflect the importance of network elements in the network; the first determination module is used to determine multiple sub-networks based on the connection relationship between multiple network elements and the network level of each network element; second The determining module is used to determine the location information of each network element based on the connection relationship between each network element in each sub-network according to the order of the network level of the network elements in the network from high to low; The connection relationship between each network element and the location information of each network element establish the network topology.
- the second determining module is configured to: sort the multiple core network elements constituting the core subnet to obtain a first network element queue, and the core network element is the network element with the highest network level among the multiple network elements; Obtain the first distance between every two adjacent core network elements in the first network element queue; based on the first distance and the total number of core network elements, determine the location information of each core network element.
- the second determination module is used to determine the location information of each core network element based on the first distance and the total number of core network elements, specifically: Based on the total number of core network elements, the first fixed-length parameter of the first figure is determined, and the first fixed-length parameter is used to reflect the geometric characteristics satisfied by the points on the first figure; according to each core network element in the first network element queue , Based on the first fixed-length parameter and the first spacing, determine the location information of the core network element in sequence.
- the first graphic includes: a circle, an ellipse, or a regular polygon.
- the second determining module when used to obtain the first distance between every two adjacent core network elements in the first network element queue, it is specifically used to: based on the drop network between the two core network elements The first total number of yuan determines the first spacing.
- the first distance is characterized by the first angle between the connection between each core network element and the designated point in the two core network elements, and the second determination module is used to determine the distance between the two core network elements
- the first total number of hanging network elements when determining the first distance, is specifically used to determine the proportion of the first total number in the second total number, and the second total number is the total number of the down-linking network elements of all core network elements;
- the product of the first total proportion and 360 degrees is determined as the first included angle.
- the second determining module is configured to divide multiple secondary network elements of the secondary sub-network into multiple first network element groups based on the connection relationship between the network elements, and the secondary network elements are multiple networks
- the network element directly connected to the core network element in the element, the core network element is the network element with the highest network level among multiple network elements; at least one secondary network element in each first network element group is sorted to obtain the second Network element queue; sort multiple first network element groups to obtain a network element group queue; determine the number of each network element based on the third total number of the down-linked network elements of all secondary network elements in each first network element group
- the layout width of a network element group based on the layout width of each first network element group and the order of any first network element group in the network element group queue, determine the layout start position of any first network element group; Based on the layout width, layout start position, the total number of multiple first network element groups, the second network element queue, the network element group queue, and the total number of secondary network elements in each first network element group, determine each Location information of two secondary
- a plurality of secondary network elements are arranged on the boundary of at least one second graphic, and the second determination module is used to determine the width of the layout, the start position of the layout, the total number of groups of the plurality of first network element groups, the second network
- the total number of element queues, network element group queues, and secondary network elements in each first network element group, when determining the location information of each secondary network element, is specifically used: based on the location of each secondary network element
- the order of the first network element group in the network element group queue determines the second graphic where each secondary network element is located; based on the total number of secondary network elements and the total number of first network element groups, each The second fixed-length parameter of the two graphics.
- the second fixed-length parameter is used to reflect the geometric characteristics of the corresponding point on the second graphic; according to each secondary network element in the second network element queue and the network element group queue Sequence, based on the second fixed length parameter corresponding to the secondary network element, the layout width, the layout start position, and the total number of secondary network elements in the first network element group where each secondary network element is located, determine the secondary network element’s location information.
- each second graphic is located outside the first graphic corresponding to the core network element; when at least one second graphic is a second graphic, the second graphic includes: a circle, an ellipse, or a regular polygon; When at least one second figure is a plurality of second figures, the overall figure formed by the plurality of second figures includes: concentric circles, concentric ellipses or concentric regular polygons.
- the second determining module is used to sort the plurality of first network element groups to obtain a network element group queue, which is specifically used to: according to the third total number corresponding to each first network element group from large to small Sequence of multiple first network element groups to obtain an initial network element group queue; according to the order of the target distance corresponding to each first network element group from large to small, re-initialize the initial network element group queue Sorting to obtain the network element group queue, the target distance is the distance from the position of the first network element group in the initial network element group queue to the center position of the initial network element group queue.
- the layout width of each first network element group is characterized by a second included angle between the connection between the two outermost network elements in the first network element group and the designated point
- the second determination module It is used to determine the layout width of each first network element group based on the third total number of down-linking network elements of all secondary network elements in each first network element group, and is specifically used to: determine any first network element The third total number corresponding to the group accounts for the second total number of the fourth total number.
- the fourth total number is the total number of the down-linking network elements of all secondary network elements in multiple first network element groups; based on any first network element The proportion of the second total corresponding to the group determines the second angle of any first network element group.
- the layout start position of each first network element group is characterized by the layout start angle.
- the layout start angle is the offset angle of the line connecting the layout start position and the specified point with respect to the specified 0 degree.
- the second determination module is used to When determining the starting position of the layout of any first network element group based on the layout width of each first network element group and the order of any first network element group in the network element group queue, it is specifically used: based on any The sequence of the first network element group in the network element group queue, and the layout width of other first network element groups in the network element group queue before any first network element group, to obtain any first network element The starting angle of the group's layout.
- the second determining module is configured to divide at least one ring-shaped subnet into at least one second network element group, the network elements in the ring-shaped subnet are connected in a ring, and the network elements belonging to the ring-shaped subnet Is a ring network element; based on the fifth total number of ring-shaped subnets in each second network element group, determine the layout width of any ring-shaped subnet; determine the third graphic corresponding to the ring network element of any ring-shaped subnet Graphic parameters, the ring network elements that constitute any ring-shaped subnet are arranged on the boundary of the corresponding third graphic, and the graphic parameters are used to reflect the geometrical characteristics of the points on the corresponding third graphic; based on any ring-shaped subnet
- the sixth total number of mid-to-bottom network elements, the corresponding graphics parameters, the corresponding layout width, and the position information of the start ring network element and end ring network element of any ring-shaped subnet determine The location information of each ring network element.
- the second determining module is based on the sixth total number of down-linking network elements in any ring-shaped subnet, the corresponding graphics parameter, the corresponding layout width, and the starting ring network element and
- the location information of the ring network element is ended, and the location information of each ring network element in any ring-shaped subnet is determined, it is specifically used: based on the sixth total number of down-linking network elements in any ring-shaped subnet, the corresponding graph
- the position information of any ring network element in the second direction being perpendicular to the first direction.
- the second determining module is further configured to: based on the location information of the start ring network element and the end ring network element of each ring-shaped subnet in any second network element group, for any second network element group At least one ring-shaped subnet is sorted to obtain the first network queue.
- the second determining module when used to determine the graphic parameter of the third graphic corresponding to the ring network element of any ring-shaped subnet, it is specifically used to: start the ring network based on the ring-shaped subnet in any second network element group The location information of the element and the end ring network element, determine the location information of the first center of gravity of any second network element group; based on the location information of the first center of gravity of any second network element group, the layout of any ring-shaped subnet The width, the order of any ring-shaped subnet in the first network queue, and the ring level of any ring-shaped subnet determine the ring network element directly connected to the start ring network element and the ring directly connected to the end ring network element The location information of at least one target ring network element in the network element; based on the location information of the target ring network element corresponding to any ring-shaped subnet and the functional relationship satisfied by the corresponding third graphic, the graphic parameter is determined.
- the second determining module is based on the sixth total number of down-linking network elements in any ring-shaped subnet, the corresponding graphic parameters, the corresponding layout width, and the start ring network element of any ring-shaped subnet and
- the position information of the end ring network element is determined and the position information of each ring network element in any ring-shaped subnet is determined, it is specifically used for: based on the position information of the start ring network element and the end ring network element of any ring-shaped subnet , Determine the third graphics coordinate system corresponding to any ring-shaped subnet; based on the sixth total number corresponding to any ring-shaped subnet, and the corresponding third graphic coordinate system and corresponding graphic parameters, determine any ring-shaped subnet The location information of each ring network element in the network.
- the second determining module is used to determine each ring network element in any ring-shaped subnet based on the sixth total number corresponding to any ring-shaped subnet, and the corresponding third graphics coordinate system and corresponding graphics parameters
- the specific location information is used for: based on the layout width corresponding to any ring-shaped subnet, the corresponding sixth total number, the corresponding graphic parameters, and the start ring network element and end ring network element in any ring-shaped subnet.
- the sequence of network elements in multiple ring network elements in any ring-shaped subnet, the distance between the start ring network element and the end ring network element in any ring-shaped subnet, the third figure corresponding to any ring-shaped subnet The coordinate system and corresponding graphic parameters determine the location information of each ring network element.
- the second determination module is configured to be based on the layout width corresponding to any ring-shaped subnet, the corresponding sixth total number, the corresponding graphics parameter, and the start ring network element and the end ring network element in any ring-shaped subnet.
- the second determining module is used to determine the third graphics coordinate system corresponding to any ring-shaped subnet based on the position information of the start ring network element and the end ring network element of any ring-shaped subnet, specifically : Determine the midpoint of the start ring network element and end ring network element of any ring-shaped subnet as the coordinate origin of the third graphics coordinate system corresponding to any ring-shaped subnet;
- the reference graphic corresponding to the two network element groups, the reference graphic is a circle with the specified fixed length as the radius and the coordinate origin of the corresponding third graphic coordinate system as the center of the circle; determine the target intersection point corresponding to any ring-shaped subnet, the target intersection point is The intersection of the reference graphic corresponding to the second network element group where any ring-shaped subnet is located and the third connection of any ring-shaped subnet, the vertex and the designated point of any ring-shaped subnet are located on the third connection;
- the direction of the line connecting the coordinate origin of the corresponding third graphics coordinate system and the target intersection is
- the second determining module is used to determine the third graphics coordinate system corresponding to any ring-shaped subnet based on the position information of the start ring network element and the end ring network element of any ring-shaped subnet, specifically : Based on the graphic parameters corresponding to any ring-shaped subnet, determine the first relative position of the geometric center of the third graphic corresponding to any ring-shaped subnet in the third graphic; based on the first corresponding position of any ring-shaped subnet Relative position and corresponding layout width, determine the second relative position of the geometric center of any ring-shaped subnet in the target second network element group where any ring-shaped subnet is located; based on the second corresponding position of any ring-shaped subnet The relative position and the position information of the home point determine the position information of the geometric center corresponding to any ring-shaped subnet.
- the home point is a ring network element coexisting in at least one ring-shaped subnet in the target second network element group;
- the position information of the geometric center corresponding to a ring-shaped subnet is determined as the position information of the origin of the corresponding third graphics coordinate system, and the direction of the connection line between the geometric center corresponding to any ring-shaped subnet and the corresponding home point is determined
- the first direction of the third graphic coordinate system corresponding to any ring-shaped subnet is determined as the second direction of the third graphic coordinate system corresponding to any ring-shaped subnet.
- the second determining module when used to determine the graphic parameter of the third graphic corresponding to the ring network element of any ring-shaped subnet, it is specifically used to: estimate the task based on the sixth total number corresponding to any ring-shaped subnet The first perimeter of the third graphic corresponding to a ring-shaped subnet; based on the perimeter formula of the third graphic corresponding to any ring-shaped subnet, determine the second perimeter of the third graphic; based on the first perimeter and the first Two perimeters, to obtain the graphics parameters corresponding to any ring-shaped subnet.
- the second determining module is used to obtain the graphic parameters corresponding to any ring-shaped subnet based on the first perimeter and the second perimeter, specifically: based on the first week corresponding to any ring-shaped subnet Length and second perimeter, obtain the first sub-parameter in the graphics parameter corresponding to any ring-shaped subnet; based on the first sub-parameter corresponding to any ring-shaped subnet, the layout width corresponding to any ring-shaped subnet, And the distance between the start ring network element and the end ring network element in any ring subnet, determine the other subparameters in the graphic parameters corresponding to any ring subnet, and obtain the graphic parameters corresponding to any ring subnet .
- the second determining module when used to divide at least one ring-shaped subnet into at least one second network element group, it is specifically used to: divide the ring-shaped subnet having the same start ring network element and the same end ring network element Divide into the same second network element group to obtain at least one second network element group.
- the second determining module when used to divide at least one ring-shaped subnet into at least one second network element group, it is specifically used to divide ring-shaped subnets with the same ring level into the same second network element group, At least one second network element group is obtained.
- the layout width of any ring-shaped subnet is characterized by the third included angle of any ring-shaped subnet, and the second determination module is used to based on the fifth total number of ring-shaped subnets in each second network element group,
- the layout width of any ring-shaped subnet it is specifically used to determine the quotient of the fifth total number corresponding to any second network element group at 180 degrees as each ring-shaped subnet in any second network element group The third angle occupied by the net.
- the layout width of any ring-shaped subnet is characterized by the third included angle of any ring-shaped subnet, and the second determination module is used to based on the fifth total number of ring-shaped subnets in each second network element group, When determining the layout width of any ring-shaped subnet, it is specifically used to determine the fourth angle formed by the first connection and the second connection.
- the first connection is the start of the ring in any second network element group
- the connection between the element and the specified point, the second connection is the connection between the end ring network element and the specified point in any second network element group; the quotient of the fourth angle and the total number of targets is determined as any second network element
- the third angle between the third links of every two adjacent ring-shaped subnets in the group, the vertices of the ring-shaped subnet and the designated points are located on the third link, the total number of targets is equal to any second network element group
- the corresponding fifth total is reduced by one.
- the layout width of any ring-shaped subnet is characterized by the third included angle of any ring-shaped subnet, and the second determination module is used to based on the fifth total number of ring-shaped subnets in each second network element group, When determining the layout width of any ring-shaped subnet, it is specifically used to determine the layout width of any ring-shaped subnet based on the sixth total number corresponding to any ring-shaped subnet.
- the second determining module is configured to: determine the first root network element among the multiple tree network elements constituting the tree-shaped subnet, and the network elements in the tree-shaped subnet are connected in a tree shape and belong to the tree-shaped subnet
- the network element of the network is a tree network element; obtain the layout start position and layout width of each tree network element; based on the layout start position and layout width of any other tree network element, and the position information of the first network element, determine any Location information of other tree network elements.
- the other tree network elements are tree network elements except the first root network element among the multiple tree network elements.
- the second determination module is also used to: obtain the depth of each other network element.
- the second determining module is used to determine the location information of any other tree network element based on the layout start position and layout width of any other tree network element and the location information of the first root network element, specifically: Based on the depth of any other tree network element, the layout start position and layout width, and the location information of the first network element, the location information of any other tree network element is determined.
- the layout start position of each tree network element is characterized by the layout start angle.
- the second determination module is used to obtain the layout start position of each tree network element, it is specifically used: based on the position information of the first root network element , The line between the first network element and the specified point is determined as the target line; the angle between the target ray and the specified line is determined as the layout start angle of the first network element, the target ray is perpendicular to the target line, and the emission direction Rays that deviate from the specified point; or, the layout start angle of the first network element is -180 degrees.
- the layout start position of each tree network element is characterized by the layout start angle.
- the second determination module is used to obtain the layout start position of each tree network element, it is specifically used: according to the connection relationship between the tree network elements , Sort multiple child network elements connected to the same parent network element to obtain the third network element queue; based on the layout start angle, layout width and width of the parent network element connected to any other tree network element, and in the third The width of the other tree network elements in sequence in the network element queue before any other tree network element determines the starting angle of the layout of any other tree network element.
- the layout width of each tree network element is characterized by a fifth included angle.
- the second determination module is used to obtain the layout width of each tree network element, it is specifically used as: the fifth included angle of the first network element 180 degrees; and/or, based on the connection relationship between the tree network elements, based on the width of any other tree network element, and the fifth angle and width of the parent network element to which any other tree network element is connected, determine any The fifth angle of the other tree network element.
- the second determining module is further configured to: sort the second root network elements in all the isolated tree subnets to obtain a fourth network element queue, and the network elements in the isolated tree subnets are connected in a tree shape ,
- the network element that belongs to the isolated tree subnet is an isolated tree network element, there is no connection path between the isolated tree network element and the core network element, and the core network element is the network element with the highest network level among multiple network elements; based on the designation
- the sum of the radius, the sum of the widths of all the second network elements, and the widths of the other second network elements in the fourth network element queue before any second network element in sequence determine any second root network Meta location information.
- the layout start position of each tree network element is characterized by the layout start angle.
- the second determination module is used to obtain the layout start position of each tree network element, it is specifically used: based on the order in the fourth network element queue The width of the other second network element before any second network element determines the starting position of the layout of the second network element.
- the layout width of each tree network element is characterized by a fifth included angle.
- the second determination module obtains the layout width of each tree network element, it is specifically used to: obtain each location according to the connection relationship between the tree network elements The width of each tree network element; based on the width of each tree network element, determine the layout width of each tree network element.
- multiple other tree network elements connected to the same first root network element are arranged on a circle with the first root network element as the center and a specified length as the radius.
- the second determining module is configured to: obtain the position information of the second center of gravity of the overall network composed of multiple tree-shaped subnets; obtain the width of each tree-shaped subnet; The location information of the three network elements sorts multiple tree-type subnets to obtain a second network queue; based on the width of each tree-type subnet, the location information of the second center of gravity, and the order of the second network queue The width of other tree-type subnets before any tree-type subnet, determine the position information of the third network element of any tree-type subnet; according to the connection relationship between the tree network elements, connect to the same parent network element Sort the multiple sub-NEs to get the fifth NE queue; based on the location information of the parent NE connected to any other tree NE, the width of any other tree NE, and the order in the fifth NE queue The position information and width of the other tree network elements located before any other tree network element determine the position information of any other tree network element.
- the first determining module is configured to determine the network composed of core network element connections as the core sub-network, and the core network element is the network element with the highest network level.
- the first determining module is configured to: determine the network composed of other network elements connected in a ring as a ring-shaped sub-network, and the other network elements are network elements other than the core network element in the network; and/or, A network composed of other network elements connected in a tree shape is determined as a tree subnet.
- the network elements in the network topology start with the network element with the highest network level and are distributed from inside to outside in the order of the network level from high to low.
- the network elements in the network topology start from the network element with the highest network level and are distributed from top to bottom in the order of network level from high to low.
- an exemplary embodiment of the present application provides an apparatus for determining a network topology, including a processor and a memory.
- the processor executes the computer program stored in the memory
- the network topology determination device executes any of the network topology determination methods of the first aspect.
- an exemplary embodiment of the present application provides a storage medium in which a computer program is stored, and the computer program instructs a file transmission detection apparatus to perform any method of determining the network topology of the first aspect.
- the method and device for determining the network topology determine multiple sub-networks based on the connection relationship between multiple network elements and the network level of each network element, and the network level of the network element To the lowest order, based on the connection relationship between each network element in each sub-network, determine the location information of each network element, and based on the connection relationship between multiple network elements and the location information of each network element, establish a network Compared with related technologies, topology can automatically obtain the location information of the network element without manually adjusting the network topology, which effectively improves the efficiency of acquiring the network topology.
- the obtained network topology can clearly present the structure of the network and the network of network elements Hierarchy and the relationship between different subnets.
- the graphics used in determining the location information of the network element are all graphics with good symmetry, the obtained network topology has good symmetry.
- it can reduce the time-consuming determination of the location information of the network element and solve the related algorithm The problem of non-convergence and low efficiency.
- FIG. 1 is a schematic structural diagram of a ring-shaped subnet provided by an exemplary embodiment of the present application
- FIG. 2 is a flowchart of a method for determining a network topology provided by an embodiment of the present application
- FIG. 3 is a schematic structural diagram of a tree subnet provided by an embodiment of the present application.
- FIG. 4 is a schematic diagram of a centrifugal layered layout provided by an embodiment of the present application.
- FIG. 5 is a schematic diagram of a process sequence for performing step 204 provided by an embodiment of the present application.
- FIG. 6 is a schematic diagram of a distribution from top to bottom according to the order of network hierarchy provided by an embodiment of the present application.
- step 7 is a schematic diagram of another process sequence for performing step 204 provided by an embodiment of the present application.
- FIG. 8 is a flowchart of a method for determining location information of a core network element provided by an embodiment of the present application
- FIG. 9 is a schematic diagram of an arc model provided by an embodiment of the present application.
- FIG. 10 is a schematic diagram of a core network element arranged on a circle provided by an embodiment of the present application.
- FIG. 11 is a flowchart of a method for determining location information of a secondary network element provided by an embodiment of the present application.
- FIG. 12 is a flowchart of a method for determining location information of a secondary network element when multiple secondary network elements are laid out on a boundary of at least one second graphic provided by an embodiment of the present application;
- FIG. 13 is a schematic diagram of a double-layer circular shape provided by an embodiment of the present application.
- FIG. 14 is a flowchart of a method for determining location information of a ring network element provided by an embodiment of the present application
- 15 is a schematic diagram of a third included angle provided by an embodiment of the present application.
- 16 is a schematic diagram of five ring-shaped subnets distributed on the boundary of a double parabola provided by an embodiment of the present application;
- 17 is a schematic diagram of a ring network element of a plurality of ring-shaped subnets provided on an embodiment of the present application, respectively arranged on boundaries of a plurality of ellipses;
- FIG. 18 is a flowchart of a method for determining a graphic parameter of a third graphic corresponding to a ring network element of any ring-shaped subnet provided by an embodiment of the present application;
- 19 is a schematic diagram of a ring network element of a plurality of ring-shaped subnets provided on an embodiment of the present application, respectively arranged on a boundary of a plurality of double paraboloids;
- FIG. 20 is a flowchart of another method for determining a graphic parameter of a third graphic corresponding to a ring network element of any ring-shaped subnet according to an embodiment of the present application;
- FIG. 21 is a partial schematic diagram of FIG. 16 provided by an embodiment of the present application.
- FIG. 22 is a schematic diagram of a ring network element of a plurality of ring-shaped subnets provided on an embodiment of the present application, respectively arranged on boundaries of a plurality of single parabola;
- FIG. 23 is a flowchart of another method for determining a graphic parameter of a third graphic corresponding to a ring network element of any ring-shaped subnet according to an embodiment of the present application;
- 24 is a flowchart of a method for determining location information of each ring network element in any ring-shaped subnet provided by an embodiment of the present application;
- 25 is a flowchart of a method for determining a third graphical coordinate system corresponding to any ring-shaped subnet provided by an embodiment of the present application;
- 26 is a flowchart of another method for determining a third graphical coordinate system corresponding to any ring-shaped subnet provided by an embodiment of the present application;
- FIG. 27 is a flowchart of another method for determining location information of each ring network element in any ring-shaped subnet provided by an embodiment of the present application;
- FIG. 28 is a flowchart of a method for determining a target ring network element as a vertex of any ring-shaped subnet provided by an embodiment of the present application;
- 29 is a flowchart of another method for determining the location information of each ring network element in any ring-shaped subnet provided by an embodiment of the present application;
- FIG. 30 is a schematic diagram of clustering network elements according to an exemplary embodiment of the present application.
- 31 is a flowchart of determining location information of a tree network element provided by an exemplary embodiment of the present application.
- FIG. 32 is a schematic diagram of a tree network element in a tree-shaped subnet provided on an arc tree model provided by an exemplary embodiment of the present application;
- FIG. 33 is a schematic diagram of a principle for obtaining a layout start angle of a first network element provided by an exemplary embodiment of the present application.
- 34 is a schematic diagram of the width of a tree network element in a tree-shaped subnet provided by an exemplary embodiment of the present application.
- 35 is a flowchart of another method for determining location information of a tree network element provided by an exemplary embodiment of the present application.
- FIG. 36 is a schematic diagram of an isolated network element disposed outside the circular area where the non-isolated network element is provided according to an exemplary embodiment of the present application;
- FIG. 37 is a flowchart of determining location information of a tree network element according to another exemplary embodiment of the present application.
- FIG. 38 is a schematic structural diagram of a straight-line tree model provided by an exemplary embodiment of the present application.
- 39 is a schematic diagram of a network topology provided by an exemplary embodiment of the present application.
- FIG. 40 is a schematic diagram of another network topology provided by an exemplary embodiment of the present application.
- 41 is a schematic structural diagram of an apparatus for determining a network topology according to an exemplary embodiment of the present application.
- FIG. 42 is a structural block diagram of an apparatus for determining a network topology provided by an exemplary embodiment of the present application.
- Network level In the network, it is usually graded according to the importance of the network element in the entire topology.
- the network level is used to reflect the importance of the network element in the network. That is, the higher the network level of the network element, the more important the network element is in the network .
- Ring subnet (also called ring): A ring network formed by a network element that starts from a ring network element through a link and passes through one or more network elements to an end ring network element.
- the network elements in the ring-shaped subnet are ring network elements, one of the ring network elements located at the two end points of the ring network is the start ring network element of the ring network, and the other is the end ring of the ring network Network element.
- the network elements except the start ring network element and the end ring network element are ring-mounted network elements.
- both the start ring network element and the end ring network element may be referred to as the home point of the corresponding ring-shaped subnet.
- the home point of the single-homed ring is the same.
- a single-homed ring subnet (also called a single-homed ring) is a ring-shaped subnet where the start ring network element and the end ring network element are the same network element.
- the dual-homed ring subnet (also called dual-homed ring subnet) is a ring-shaped subnet in which the start ring network element and the end ring network element are not the same network element.
- the same-layer ring-shaped subnet also called the same-layer ring
- a cross-layer ring-shaped subnet (also called a cross-layer ring) is a ring-shaped subnet in which the network level of the start ring network element and the end ring network element are different.
- Tree subnet A network of network elements connected in a tree.
- the network elements belonging to the tree-shaped subnet are tree network elements.
- Core network element The network element with the highest network level among the network elements included in the network.
- Secondary network element a lower-level network element directly connected to the core network element among multiple network elements included in the network.
- Isolated network element also referred to as an isolated tree network element in this article: a network element that does not have a connection path with the core network element.
- Cross-ring link Among the network elements located at both ends of the link, one network element belongs to the ring network element, and one link does not belong to the ring network element.
- each remaining network element is divided into the corresponding The group where the secondary network elements are located.
- the set of network elements and links included in each group is called a cluster.
- the remaining network elements are network elements whose network level is lower than the secondary network elements.
- Cross-cluster links The network elements at both ends of the link belong to different cluster links.
- Downlink network element of any network element a network element connected to any network element.
- Ring level The level of the ring-shaped subnet is equal to the maximum value of the network level of the start ring network element and the network level of the end ring network element of the ring-shaped subnet plus one.
- FIG. 1 shows four ring-shaped subnets, respectively: ring-shaped subnet 1 including ring network element a1, ring network element a4, and ring network element a2, including ring network element a2, ring network element a5 , Ring sub-network 2 of ring network element a6 and ring network element a3, including ring sub-network 3 of ring network element a4, ring network element a7 and ring network element a5, including ring network element a7, ring network element a8 and The ring-shaped subnet 4 of the ring network element a6.
- the network level of ring network element a1, ring network element a2 and ring network element a3 are all 1, the network level of ring network element a4, ring network element a5 and ring network element a6 are all 2, the network level of ring network element a7 If the level is 3, it can be determined that the ring levels of ring-shaped subnets 1 and 2 are 1, the ring level of ring-shaped subnet 3 is 2, and the ring level of ring-shaped subnet 4 is 3.
- the network topology of the network is usually obtained according to a force-oriented layout algorithm.
- the implementation process includes: after obtaining the connection method of each network element in the network, you can first establish the energy model of the entire network according to the connection method, through Hooke's law, and then iteratively move the network element and make the network element When the energy of the energy model obtains the minimum value, the position corresponding to the minimum value is determined as the position of the network element to obtain the network topology of the network.
- the process of moving the network element according to energy it is easy to cause vibration of the network element, resulting in the algorithm not converging and the process of acquiring the network topology taking a long time.
- the location of the network element is determined through iteration, when acquiring the network topology, the iteration process needs to be terminated by specifying the number of iterations.
- the initial position of the network element needs to be specified, resulting in the uncertainty of the acquired topology structure, and the acquisition process of the topology structure will be affected by the initial position.
- the specified initial position is compared
- the layout result of the obtained network topology is poor, and it is difficult to obtain satisfactory results.
- the network topology is a pure energy layout, the network topology has many crossovers and chaotic structures. It cannot clearly and completely show the structure and hierarchy of the network and the relationships between different subnets. The efficiency of acquiring the network topology is low.
- the present application provides a method for determining the network topology, which determines multiple sub-networks based on the connection relationship between multiple network elements and the network level of each network element, according to the network of network elements in the network Hierarchical order, based on the connection relationship between each network element in each subnetwork, determine the location information of each network element, and based on the connection relationship between multiple network elements and the location information of each network element
- it can automatically obtain the location information of the network element, without manually adjusting the network topology, which effectively improves the efficiency of obtaining the network topology.
- FIG. 2 is a flowchart of a method for determining a network topology according to an embodiment of the present application. As shown in FIG. 2, the method may include:
- Step 201 Obtain the connection relationship between multiple network elements used to form a network and the network level of each network element.
- the network level is used to reflect the importance of network elements in the network.
- connection relationship between network elements and the network level of each network element are usually determined according to the deployment requirements of the network, and the network topology is obtained according to the connection relationship and the network level of each network element. Therefore, when determining the network topology At this time, you need to first obtain the connection relationship and the network level of each network element.
- Step 202 Determine the core network elements in the network topology, and divide the network according to the connectivity between each network element and the core network element.
- the network element that has a connection link with the core network element can be determined as a non-isolated network element.
- the non-isolated network element usually includes secondary network elements, ring network elements, and tree network elements. at least one.
- the subnet composed of non-isolated network elements is a non-isolated subnet.
- the network element that does not have a connection link between the network and the core network element can be determined as an isolated network element, and the subnetwork composed of isolated network elements is an isolated subnet.
- Step 203 Based on the connection relationship between multiple network elements and the network level of each network element, determine multiple sub-networks respectively.
- the network topology usually includes: core network elements and other network elements.
- the other network element may include at least one of a secondary network element, a ring network element, a tree network element, and an isolated network element.
- the implementation process of step 203 may include: determining the network composed of the core network element connections as the core sub-network.
- the implementation process of step 203 may further include: determining a network composed of other network elements connected in a ring as a ring-shaped subnetwork, and the other network elements are network elements other than the core network element in the network.
- the network composed of other network elements connected in a tree shape is determined as a tree subnet.
- the isolated subnet since the network elements in the isolated subnet are arranged according to the tree connection, the isolated subnet may also be called an isolated tree subnet, and the network elements in the isolated tree subnet may be It is called an isolated tree network element.
- the implementation process of step 203 may further include: acquiring the depth of each network element in the tree subnet, and according to the depth of each network element in the tree subnet,
- the tree subnet is divided into a short tree subnet and a long tree subnet, so as to lay out the long tree subnet and the short tree subnet according to different layout models respectively, so as to reduce the crossover in the tree subnet.
- the depth of each network element in the tree subnet is equal to the total number of network elements included in the shortest path from the network element to the root network element of the tree subnet.
- the implementation manner of dividing the long tree and the short tree may include: in a tree-shaped subnet, determine the network element with a network element depth greater than a specified depth threshold as the long tree network element in the long tree subnet, and The network element whose element depth is less than or equal to the specified depth threshold is determined as the short tree network element in the short tree subnet, and the subnet composed of the long tree network element is determined as the long tree subnet, and the subtree composed of the short tree network element The network is determined to be a short tree subnet.
- the first network element is a tree network element b1
- its depth is 1, the tree
- the depths of sub-network element b2, sub-network element b3, sub-network element b4 and sub-network element b5 of network element b1 are 2, sub-network element b6 of tree network element b2, sub-network elements b7 and b8 of tree network element b3,
- the depths of the sub-network elements b9 and b10 of the tree network element b5 are 3, the sub-network elements b11 and b12 of the tree network element b7, the sub-network elements b13 and b14 of the tree network element b9, and the subnets of the tree network element b10
- the depths of the elements b15 and b16 are 4, and the depth of the sub-network element b17 of the tree network
- Step 204 Determine the location information of each network element based on the connection relationship between each network element in each sub-network according to the order of the network level of the network element in the network from high to low.
- the layout of network elements in the network topology may include at least the following two types:
- the first layout method The network elements in the network topology can start from the network element with the highest network level, and be distributed from inside to outside according to the order of the network level from high to low.
- the obtained network topology can be called a mesh Topology. That is, the network elements in the network topology can be arranged in a centrifugal layered layout.
- the distribution position of multiple network elements in the obtained network topology is more uniform, which can make the layout of the network topology more beautiful, and when the network construction is performed according to the network element topology, Reduce interference between network elements.
- the core network element may be laid out on the boundary of the first graphic.
- the first figure may be a closed figure such as a circle, an ellipse, or a regular polygon whose geometric center is at a specified point.
- the secondary network element may be arranged on the boundary of at least one second graphic.
- the second graphic may include: a circle, an ellipse, or a regular polygon whose geometric center is located at a specified point.
- the overall figure formed by the plurality of second figures may include: a concentric circle, a concentric ellipse, or a concentric regular polygon whose geometric center is located at a specified point. And the second figure is located outside the first figure.
- the ring network elements of the ring-shaped subnet may be arranged on the boundary of the third figure.
- the third figure may include: an ellipse or a double parabola.
- FIG. 4 is a schematic diagram of the centrifugal layered layout
- the black dots in FIG. 4 are network elements
- the solid line between the two network elements in FIG. 4 indicates that there is a connection relationship between the two network elements
- the network level of the network element closer to the geometric center of the network topology shown in FIG. 4 is higher. Therefore, it can be seen that the network element in FIG. 4 starts from the core network element with the highest network level.
- the order of the hierarchy is divergently distributed from the inside to the outside.
- the sequence of its execution flow is shown in FIG. 5, after the network is divided into networks, it can be divided into non-isolated subnets Determine the core subnet, secondary subnet, ring subnet, and tree subnet. Then determine the location information of the core network element in the core subnet. According to the location information of the core network element, the location information of the secondary network element is determined in the secondary subnet. Then, according to the location information of the core network element and/or the secondary network element, the location information of the ring network element is determined in the ring-shaped subnet.
- the location information of the tree network element is determined in the tree-type subnet.
- the position information of the isolated tree network element is determined in the isolated tree type subnet according to the location information of the core network element, the secondary network element, the ring network element and/or the tree network element.
- the second layout method The network elements in the network topology can start with the network element with the highest network level, and be distributed from top to bottom in the order of network level from high to low. At this time, the obtained network topology can be called a tree Topology.
- the topology level of the network elements in the obtained network topology is clearer, and the network structure and the network hierarchy of the network elements can be presented more clearly And the relationship between different subnets.
- the core network element may be laid out on the boundary of the first graphic.
- the first figure may be a closed figure such as a circle, an ellipse, or a regular polygon.
- the ring network elements of the ring-shaped subnet may be arranged on the boundary of the third figure.
- the third graph may include: a single parabola and the like.
- FIG. 6 is a schematic diagram of network elements distributed from top to bottom according to the order of network hierarchy.
- the black dots in FIG. 6 are network elements, and the solid lines between the two network elements in FIG. 6 indicate There is a connection relationship between the two network elements, and the network level of the network element closer to the top of the network topology shown in FIG. 6 is higher. Therefore, it can be seen that the network element in FIG. 6 has the highest network
- the network elements at the level are the starting point, and they are distributed from top to bottom in the order of network level from high to low.
- the sequence of its execution flow is shown in FIG. 7, after the network is divided into networks, it can be divided into non-isolated subnets Determine the core subnet, ring subnet, and tree subnet. Then determine the location information of the core network element in the core subnet. According to the location information of the core network element, the location information of the ring network element is determined in the ring-shaped subnet. According to the location information of the core network element and/or the ring network element, the location information of the tree network element is determined in the tree-shaped subnet.
- step 204 when the type of the network elements are different, the implementation manner of the step 204 is different.
- the implementation manners of the step 204 are described below for different types of network elements:
- step 204 may include:
- Step 2041a Sort the multiple core network elements constituting the core subnet to obtain a first network element queue.
- the length of the link of each core network element can be obtained, and the multiple core network elements can be sorted according to the length of the link.
- the size of the ring-shaped subnet with each core network element as a starting ring network element and/or an end ring network element may be determined in the network where the core network element is located, and the number of ring network elements included in the ring type subnet
- the multiple core network elements are sorted in an ascending order.
- the core subnet is ranked in the first network element queue according to the number of ring network elements of the ring-shaped subnet. tail.
- the certain core subnet When there is no ring-shaped subnet in the network where all core network elements are located, determine the length of the longest link including each core subnet, and follow the order of the longest link corresponding to the core subnet from long to short To sort the multiple core network elements.
- the certain core subnet When there is no corresponding longest link in the network of a certain core subnet, the certain core subnet is sequentially arranged at the tail of the first network element queue that is sorted according to the length of the longest link.
- Step 2042a Obtain a first distance between every two adjacent core network elements in the first network element queue.
- the first distance may be a specified value determined according to actual needs.
- the first distance between every two core network elements in the network topology can be determined according to actual needs.
- the plurality of core network elements may be arranged on an arc whose center angle is less than 180 degrees, that is, the plurality of core network elements are arranged according to the arc model shown in FIG. 9.
- the first distance may be characterized by the first included angle between the connection between each core network element and the specified point in every two adjacent core network elements, and the first included angle may be equal to the specified core network element The angle constant of the layout.
- the first distance may be determined based on the first total number of drop network elements between the two core network elements.
- the first distance when the first distance is characterized by the first included angle between the connection between each core network element and the designated point in each adjacent two core network elements, the The implementation of the first total number of network elements to determine the first distance may include: determining the first total proportion of the first total in the second total, and then determining the product of the first total proportion and 360 degrees as the first An angle.
- the second total number is the total number of down-link network elements of all core network elements.
- the multiple core network elements may be laid out on the circle shown in FIG. 10.
- the first included angle ⁇ ij , the first total number N ij and the second total number ⁇ N ij between the connection between each core network element i and the core point in the core network element i and the core network element j can satisfy the following formula:
- Step 2043a Determine the location information of each core network element based on the first distance and the total number of core network elements.
- step 2043a may include:
- Step 2043a1 based on the total number of core network elements, determine the first fixed-length parameter of the first figure.
- the first fixed-length parameter is used to reflect the geometric characteristics satisfied by the points on the first figure.
- the first fixed-length parameter is the radius of the circle.
- the radius R and the total number of core network elements I1 can satisfy the following formula:
- k1 is the radius ratio constant of the core network element layout.
- the first fixed-length parameter is the radius of the circle.
- the radius R, the total number of core network elements I1, and the first included angle ⁇ ij between the connection between each core network element and the designated point in every two adjacent core network elements can satisfy the following formula:
- k1 is the radius ratio constant of the core network element layout.
- the first included angle is a specified value.
- Step 2043a2 According to the order of each core network element in the first network element queue, based on the first fixed-length parameter and the first distance, position information of the core network element is determined in sequence.
- the position coordinates (xt, yt) of the t-th core network element in the first network element queue, the The radius R of the circle and the first included angle ⁇ ij corresponding to the core network element i and the core network element j can satisfy:
- the position coordinates (xt, yt) are the coordinates in the coordinate system shown in FIG. 4, and the designated point is the origin of the coordinate system.
- k1 is the radius magnification constant of the core network element layout.
- I1 is the total number of core network elements.
- step 2043a1 when the first graph is a circle centered at a specified point, the position coordinates (xt, yt) of the t-th network element in the first network element queue, the The radius R of the first circle and the angle constant ⁇ 2 of the core network element layout can satisfy:
- the position coordinates (xt, yt) are the coordinates in the coordinate system shown in FIG. 6, and the designated point is the origin of the coordinate system.
- k1 is the radius magnification constant of the core network element layout.
- I1 is the total number of core network elements.
- the same core network can be guaranteed There is no crossover between all the connected NEs under the yuan.
- step 204 may include:
- Step 2041b Based on the connection relationship between the network elements, divide the multiple secondary network elements of the secondary sub-network into multiple first network element groups.
- the secondary network elements and their links may be grouped according to network connectivity.
- secondary network elements directly connected may be divided into the same first network element group, and secondary network elements not directly connected may be divided into different first network element groups.
- Step 2042b Sort at least one secondary network element in each first network element group to obtain a second network element queue.
- the links may be sorted in order from longest to shortest, and the implementation process may refer to the implementation process of step 2041a accordingly.
- Step 2043b Sort the multiple first network element groups to obtain a network element group queue.
- step 2043b may include:
- Step 2043b1 Perform an initial sorting on the plurality of first network element groups according to the order of the third total number corresponding to each first network element group from large to small to obtain an initial network element group queue.
- the third total number is the total number of the down-linking network elements of all secondary network elements in the first network element group.
- Step 2043b2 Reorder the initial network element group queue according to the order of the target distance corresponding to each first network element group from large to small to obtain the network element group queue.
- the target distance is the distance from the position of the first network element group in the initial network element group queue to the center position of the initial network element group queue.
- the first network element group 1 and the second network element The order of the group 2, ..., the I2-1 network element group I2-1 and the I2 network element group I2 in the initial network element group queue are 1, 2, 3, ..., I2, after reordering the initial network element group queue according to the order of the target distance corresponding to each first network element group, the first network element group 1, the second network element group 2, ...., the order of the I2-1 network element group I2-1 and the I2 network element group I2 in the network element group queue are 1, I2, 2, I2-1, 3, ... .
- the plurality of first network element groups are sorted in a large and small interleaved manner, which can make the uniformity of the network topology determined according to the network element group queue better, and the network elements The network level between is more obvious.
- Step 2044b Determine the layout width of each first network element group based on the third total number of down-link network elements of all secondary network elements in each first network element group.
- step 2044b the layout width of the first network element group is characterized by the second included angle between the connection between the two outermost secondary network elements in the first network element group and the designated point.
- Step 2044b1 Determine the proportion of the third total number corresponding to any first network element group in the second total number of the fourth total number.
- the fourth total number is the total number of down-linking network elements of all secondary network elements in multiple first network element groups.
- Step 2044b2 Determine the second included angle of any first network element group based on the proportion of the second total number corresponding to any first network element group.
- the second angle may be regarded as an angle occupied by each first network element group.
- the second included angle ⁇ i , the third total number N i , the fourth total number ⁇ N i of the i-th first network element group and the total number I1 of core network elements satisfy:
- ⁇ is the constant of the angle difference between groups, that is, ⁇ is the constant of the angle difference between each adjacent two first network element groups, Proportion for the second total.
- Step 2045b Based on the layout width of each first network element group and the order of any first network element group in the network element group queue, determine a layout start position of any first network element group.
- each first network element group when the layout start position of each first network element group is characterized by the layout start angle, it may be based on the order of any first network element group in the network element group queue and in the network element group queue
- the layout width of other first network element groups before any first network element group is obtained as the layout start angle of any first network element group.
- the layout start angle may be regarded as the group start layout angle of any first network element group.
- the layout start angle of the t-th first network element group in the network element group queue is ⁇ t
- the layout of other first network element groups before any first network element group in the network element group queue The width ⁇ i satisfies:
- ⁇ is a constant angle difference between two adjacent first network element groups.
- Step 2046b based on the layout width, the layout start position, the total number of multiple first network element groups, the second network element queue, the network element group queue, and the total number of secondary network elements in each first network element group To determine the location information of each secondary network element.
- step 2046b when multiple secondary network elements are laid out on the boundary of at least one second graphic, the implementation process of step 2046b may include:
- Step 2046b1 based on the order of the first network element group where each secondary network element is located in the network element group queue, determine the second figure where each secondary network element is located.
- step 2046b1 may include: according to the order of the first network element group in the network element group queue, according to the The second graphic where a network element group is located is arranged in a circular manner from inside to outside, and the second graphic where each first network element group is located is determined in turn.
- the second graphic where the first network element group is located is the The second figure where the secondary network element in the first network element group is located.
- the overall figure formed by the two second figures is a concentric circle (also called a double-layer circle, please refer to FIG. 13 for its schematic diagram)
- the circle in which the first network element group is located it can be determined that the first network element group in the odd order in the network element group queue is located on the inner circle, that is, in the first network element group in the odd order
- the secondary network elements are located on the inner circle.
- the first network element group in the even order is located on the outer circle, that is, the secondary network elements in the first network element group in the even order are located on the outer circle. Metaphysically.
- Step 2046b2 Determine a second fixed-length parameter of each second figure based on the total number of secondary network elements and the total number of first network element groups.
- the second fixed-length parameter is used to reflect the geometric characteristics that the corresponding point on the second graph satisfies.
- the second fixed-length parameter is the radius of the circle.
- each second figure is a rotationally symmetric figure
- the a is the ratio of the circumference of the second innermost figure divided by the innermost second figure.
- step 2046b2 may include: determining the two circles separately The radius of the shape, and the radius of the circle located outside is N times the radius of the circle located inside.
- the radius r t of the t-th circle in the network element group queue and the total number of secondary network elements M and the total number I3 of the first network element group can satisfy:
- k2 is the radius magnification constant of the secondary network element layout.
- ⁇ is the constant of the angle difference between each adjacent two first network element groups.
- Step 2046b3 According to the order of each secondary network element in the second network element queue and the network element group queue, based on the second fixed-length parameter, layout width, and layout start position of the second graphic where the secondary network element is located, And the total number of secondary network elements in the first network element group where each secondary network element is located to determine the location information of the secondary network element.
- the second fixed-length parameter ri of the second graph where the secondary network element is located is the layout width ⁇ i , the layout start position ⁇ i , is the total number of secondary network elements Mi of the i-th group, and the network element group queue
- the coordinates (x ij , y ij ) of the j-th secondary network element in the i-th first network element group in can satisfy:
- step 204 may include:
- Step 2041c Divide at least one ring-shaped subnet into at least one second network element group.
- step 2041c may include: dividing the ring-shaped subnets having the same start ring network element and the same end ring network element into the same The second network element group obtains at least one second network element group.
- step 2041c may include: dividing ring-shaped subnets with the same ring level into the same second network element group to obtain at least one The second network element group.
- Step 2042c Determine the layout width of any ring-shaped subnet based on the fifth total number of ring-shaped subnets in each second network element group.
- the layout width of any ring-shaped subnet can be characterized by the third included angle of any ring-shaped subnet.
- the layout mode satisfied by the ring network element is different, the implementation of this step 2042c is different.
- a variety of realizable methods are used as examples to illustrate:
- the ring network elements in the ring-shaped subnet are laid out according to the first layout method, and the ring network elements are laid out on the boundary of the ellipse, 180 degrees can be connected to any second network
- the quotient of the fifth total number corresponding to the tuple is determined as the third angle occupied by each ring-shaped subnet in any second network element group.
- the third included angle can be regarded as the included angle between the two endpoints of the short axis of the ellipse and the attribution point.
- the third included angle is the included angle between the two ends of the short axis of the ellipse and the belonging point O′
- the first connection and the second The fourth angle formed by the connection, and the quotient of the fourth angle and the total number of targets is determined as the third between the third connections of every two adjacent ring-shaped subnets in any second network element group Angle.
- the third angle between the third links of each adjacent two ring-shaped subnets can be determined. Since the third connection is the connection determined by the vertex of the ring-shaped subnet and the specified point, and because the specified point is a known point, after determining the third angle, each ring-shaped child can be determined.
- the vertices of the double parabola corresponding to the net are arranged in the direction of the third straight line.
- the target total number is equal to the fifth total number corresponding to any second network element group minus one.
- the first connection is the connection between the start ring network element and the specified point in any second network element group
- the second connection is the connection between the end ring network element and the specified point in any second network element group.
- the third link corresponding to the ring-shaped subnet 1 is the second link OA2.
- the connection between the vertex C2 of the ring-shaped subnet 2 and the specified point O is the third connection OC2
- the connection between the vertex C3 of the ring-shaped subnet 3 and the specified point O is the third connection OC3, the ring
- the connection determined by the vertex C4 of the subnet 4 and the designated point O is the third connection OC4. It can be seen from FIG. 16 that the five third links corresponding to the five ring-shaped subnets are equivalent to bisect the fourth angle, and the angle after the bisection is corresponding to each adjacent two ring-shaped subnets The third angle.
- the ring-shaped subnet may be determined based on the sixth total number corresponding to any ring-shaped subnet The layout width of the net.
- the ring-shaped subnet when laid out on a parabola and the distance between every two adjacent ring network elements in the ring-shaped subnet is equal, it can be based on all ring network elements in any ring-shaped subnet The sum of the spacing and the constant term of the parabola determine the layout width of any ring-shaped subnet.
- any ring-shaped subnet can be determined by the principle of the Pythagorean theorem based on the sum of the spacing and the constant term
- Office width that is, the layout width w ij of the j-th ring-shaped subnet in the i-th second network element group, and the number of drop-down network elements M of the j-th ring-shaped subnet in the i-th second network element group ij , the constant D of the ideal distance between adjacent ring network elements, and the constant b of the parabola satisfy:
- Step 2043c Determine the graphic parameter of the third graphic corresponding to the ring network element of any ring-shaped subnet.
- the graphic parameters of the third graphic are used to reflect the geometric characteristics satisfied by the points on the corresponding third graphic.
- the third graph may include: an ellipse, a double parabola, or a parabola (also called a single parabola).
- the figure parameter is an ellipse parameter.
- the graph parameter is a double parabola parameter.
- the graph parameter is a single parabola parameter.
- step 2043c when the ring-shaped subnet is a single-homed ring, the ring-shaped subnet may be distributed on the boundary of an ellipse or other figure.
- the implementation process of this step 2043c may include:
- Step 2043c1 based on the sixth total number corresponding to any ring-shaped subnet, estimate the first perimeter of the third figure corresponding to any ring-shaped subnet.
- the third figure corresponding to the ring-shaped subnet can be estimated according to the sixth total number I4 of the down-linking network elements of the ring-shaped subnet, and the distance constant between two adjacent ring network elements in the ring-shaped subnet The first girth.
- the sixth total number I4 of the down-link network elements of the i-th ring subnet in the second network element group, the distance constant D between two adjacent ring network elements in the ring subnet, and the first perimeter L1 can satisfy:
- Step 2043c2 Determine the second perimeter of the third graph based on the perimeter formula of the third graph corresponding to any ring-shaped subnet.
- a and b are ellipse parameters
- k3 is an ellipse control parameter
- Step 2043c3 Based on the first perimeter and the second perimeter, obtain graphic parameters corresponding to any ring-shaped subnet.
- the two should be equal, and both contain the ellipse parameters a and b, so by assuming that they are equal, And according to the proportional relationship between a and b, the ellipse parameters of the ellipse can be determined as:
- step 2043c when the ring-shaped subnet is a dual-homed ring-shaped subnet, the ring-shaped subnet may be distributed on the boundary of the double parabola.
- the implementation process of this step 2043c may include:
- Step 2043c4 Based on the sixth total number corresponding to any ring-shaped subnet, estimate the first perimeter of the third figure corresponding to any ring-shaped subnet.
- the sixth total number I4 of the down-link network elements of the i-th ring subnet in the second network element group can be obtained.
- the distance constant D between two adjacent ring network elements in the ring subnet is the same as that of the first
- the perimeter L1 can satisfy:
- Step 2043c5 Determine the second perimeter of the third graph based on the perimeter formula of the third graph corresponding to any ring-shaped subnet.
- a1, a2 and b are double parabolic parameters.
- the second perimeter of the double parabola can be estimated according to the perimeter formula of the single parabola.
- d is the distance between two home points of any ring-shaped subnet, that is, the distance between the start ring network element and the end ring network element of any ring-shaped subnet.
- Step 2043c6 Based on the first perimeter and the second perimeter corresponding to any ring-shaped subnet, obtain the first sub-parameter in the graphics parameter corresponding to any ring-shaped subnet.
- Step 2043c7 based on the first sub-parameter corresponding to any ring-shaped subnet, the layout width corresponding to any ring-shaped subnet, and the distance between the start ring network element and the end ring network element in any ring-shaped subnet, Determine the other sub-parameters in the graphic parameters corresponding to any ring-shaped subnet to obtain the graphic parameters corresponding to any ring-shaped subnet.
- the other sub-parameters a1 and a2 in the double parabola, the first sub-parameter b, and the distance d between the start ring network element and the end ring network element in any ring-shaped subnet can satisfy:
- FIG. 21 is a partial schematic diagram of FIG. 16. Please refer to the connection between the vertex C2 of the ring-shaped subnet 2 and the designated point O as the third connection OC2. The left end of the line A1A2 where the two home points are located is counterclockwise The angle passed to the third connection OC2 is ⁇ 3.
- the determination process of the included angle ⁇ 3 includes: after determining the third included angle corresponding to the any ring-shaped subnet, it can be determined that the second network element group where the any ring-shaped subnet is located is arranged in the any ring-shaped The ring-shaped subnet on the left side of the subnet, and the third angle corresponding to the ring-shaped subnet on the left side, and then the third angle corresponding to any ring-shaped subnet and the ring-shaped subnet on the left side The sum of the third included angles corresponding to the net is determined as the included angle ⁇ 3.
- step 2043c when the ring-shaped subnet is a dual-homed ring-shaped subnet, the ring-shaped subnet may be distributed on the boundary of a single parabola.
- the ring-shaped subnet may be distributed on the boundary of a single parabola.
- FIG. 22 for schematic diagrams of the ring network elements of multiple ring-shaped subnets having the same home point respectively arranged on the boundaries of multiple single parabola.
- the implementation process of this step 2043c may include:
- Step 2043c8 Sort at least one ring-shaped subnet in any second network element group based on the location information of the start ring network element and the end ring network element of each ring-shaped subnet in any second network element group, Get the first network queue.
- the start ring network element and the end ring network element of each ring-shaped subnet can be calculated according to the position information of the start ring network element and the end ring network element of each ring-shaped subnet in a coordinate direction.
- the average value of the coordinates and then sort the at least one ring-shaped subnet in any second network element group according to the order of the average value from small to large to obtain the first network queue.
- At least one ring-shaped subnet may be sorted according to the average value of the x coordinates of the ring network elements.
- Step 2043c9 Determine the position information of the first center of gravity of any second network element group based on the position information of the start ring network element and the end ring network element of the ring-shaped subnet in any second network element group.
- the implementation process of step 2043c9 may include: determining The position information of the first center of gravity of any second network element group in the x coordinate direction, correspondingly, the first center of gravity of any second network element group can be understood as the x coordinate direction of any second network element group Center of gravity.
- the position information of the first center of gravity of any second network element group in the x coordinate direction is equal to the sum of the coordinates of the start ring network element and the end ring network element of all ring subnets in the group in the x coordinate direction and the A fifth total quotient corresponding to a second network element group.
- Step 2043c10 based on the position information of the first center of gravity of any second network element group, the layout width of any ring-shaped subnet, the order of any ring-shaped subnet in the first network queue, and any ring-shaped subnet
- the ring level of the network determines the position information of at least one target ring network element in the ring network element directly connected to the start ring network element and the ring network element directly connected to the end ring network element.
- the ring network element whose position information is to be calculated in the ring-shaped subnet may be any ring network element in the ring-shaped subnet in which the ring network elements except the start ring network element and the end ring network element are reorganized in the ring type subnet .
- the layout position of any second network element group can be determined.
- the layout position of any second network element group can be determined.
- Position information of the ring and then determine the position information of the ring network element in the y-coordinate direction of the ring-shaped subnet according to the ring level of the ring-shaped subnet.
- the ring network element whose position information is to be calculated may be a start ring network element and an end ring network element of the reorganized ring-shaped subnet.
- the position information of the start ring network element of the reorganized ring-shaped subnet (x s it , y s it )
- the layout width w ij of each ring-shaped subnet in the first network queue the layout width w ij of each ring-shaped subnet in the first network queue
- the position information z i of the first center of gravity of the second network element group in the x coordinate direction and the The ring grade k4 of the ring-shaped subnet meets:
- ymin1 is the minimum value of the y-coordinate of the core network element
- drw is the distance constant of the ring-shaped subnet in the x-coordinate direction
- drh is the value of the second network element group where the ring-shaped subnet is located in the y-coordinate direction Spacing constant.
- the location information (x e it , y e it ) of the end ring network element of the reorganized ring subnet and the layout width w it of the reorganized ring subnet satisfy:
- step 2042c for the implementation process of obtaining the layout width of any ring-shaped subnet accordingly.
- Step 2043c11 Determine the graphics parameters based on the functional relationship satisfied by the location information of the target ring network element corresponding to any ring-shaped subnet and the corresponding third graphics.
- b is a constant.
- the position information of all ring network elements in the reorganized ring-shaped subnet should satisfy the standard equation, so the reorganized ring-shaped
- the ring network element whose position information in the subnet is known is brought into the standard equation to obtain the single parabolic parameter a. Any one of the location information of the ring network start-membered ring recombinant subnet (x s it, y s it ) and the end ring element (x e it, y e it ) the position information (x s , y s ) into the standard equation, we can get:
- Step 2044c Based on the sixth total number of down-linking network elements in any ring-shaped subnet, corresponding graphic parameters, corresponding layout width, and the position information of the start ring network element and end ring network element of any ring-shaped subnet To determine the location information of each ring network element in any ring subnet.
- the implementation manner of this step 2044c may include:
- Step 2044c1 based on the position information of the start ring network element and the end ring network element of any ring-shaped subnet, determine the third graphic coordinate system corresponding to any ring-shaped subnet.
- step 2044c1 may include:
- Step 2044c11 Based on the graphic parameters corresponding to any ring-shaped subnet, determine the first relative position of the geometric center of the third graphic corresponding to any ring-shaped subnet in the third graphic.
- the ellipse parameters a and b of the ellipse correspond to the long axis and short axis of the ellipse, respectively. Therefore, after obtaining the ellipse parameters a and b, the shape of the ellipse can be determined, and accordingly, the geometry of the ellipse can be determined.
- Step 2044c12 Based on the first relative position corresponding to any ring-shaped subnet and the corresponding layout width, determine that the corresponding geometric center of any ring-shaped subnet is the second in the target second network element group where any ring-shaped subnet is located relative position.
- the first relative position of the geometric center of the ellipse arranged in any ring-shaped subnet is determined in the ellipse, and all ring-shaped subnets in the target second network element group where the any ring-shaped subnet is located correspond to After the width of the layout, you can determine the size of the ellipse corresponding to each ring-shaped subnet, that is, you can determine the size of the ellipse corresponding to each ring-shaped subnet.
- any ring-shaped subnet The order in the first network queue corresponding to the target second network element group and the size of the ellipse corresponding to each ring-shaped subnet can determine that any ring-shaped subnet is in the target second network element group
- the second relative position can be regarded as the relative position of the geometric center of the ring-shaped subnet relative to the home point in the target second network element group.
- Step 2044c13 Determine the position information of the geometric center corresponding to any ring-shaped subnet based on the second relative position corresponding to any ring-shaped subnet and the position information of the home point.
- the location information of the home point is used to indicate the specific layout position of the target second network element group. After determining the second relative position of any ring-shaped subnet in the target second network element group, due to the second relative position It can be regarded as the relative position of the geometric center of the ring-shaped subnet relative to the attribution point in the target second network element group. Therefore, the location information of the geometric center can be determined according to the location information of the attribution point.
- Step 2044c14 Determine the location information of the geometric center corresponding to any ring-shaped subnet as the location information of the origin of the corresponding third graphics coordinate system, and connect the geometric center corresponding to any ring-shaped subnet with the corresponding home point
- the direction of the line is determined as the first direction of the third graphics coordinate system corresponding to any ring-shaped subnet, and the direction perpendicular to the first direction is determined as the second direction of the third graphics coordinate system corresponding to any ring-shaped subnet direction.
- the third graphics coordinate system corresponding to each ring-shaped subnet is the coordinate system established for the ring-shaped subnet. Therefore, the geometric center corresponding to the ring-shaped subnet can be determined as the origin of the third graphic coordinate system.
- the direction where the line connecting the geometric center and the corresponding home point is located is determined as the first direction of the third graphics coordinate system where the corresponding ring-shaped subnet is located.
- the direction perpendicular to the first direction is determined as the second direction of the third graphics coordinate system where the ring-shaped subnet is located.
- the first direction may be the x coordinate direction.
- the y coordinate direction may be determined according to the principle of the right-hand coordinate system.
- the implementation process of this step 2044c1 may include:
- Step 2044c15 Determine the midpoint of the start ring network element and the end ring network element of any ring-shaped subnet as the coordinate origin of the third graphics coordinate system corresponding to any ring-shaped subnet.
- Step 2044c16 Determine a reference pattern corresponding to the second network element group where any ring-shaped subnet is located.
- the vertices of multiple ring-shaped subnets in each second network element group may be distributed on the boundary of the reference graph.
- the reference graphic may be a circle with a specified fixed length as the radius and the coordinate origin of the corresponding third graphic coordinate system as the center of the circle.
- the specified fixed length may be equal to the constant term in the standard equation of the double parabola distributed by the ring-shaped subnet.
- the vertex layout of the double parabola corresponding to each ring-shaped subnet is in the direction where the corresponding third straight line is located.
- the position of the intersection point of the third straight line corresponding to the ring-shaped subnet and the reference figure can be determined as the ring The position of the vertex of the double parabola corresponding to the type subnet.
- Step 2044c17 Determine the direction of the line connecting the coordinate origin of the corresponding third graphics coordinate system and the target intersection as the second direction of the corresponding third graphics coordinate system, and determine the direction perpendicular to the second direction as the corresponding first The first direction of the three graphics coordinate system.
- the circle shown by the dotted line is the reference graphic corresponding to the second network element group, and the origin of the reference graphic is the midpoint A3 of the start ring network element A1 and the end ring network element A2.
- the coordinate origin of the third graphic coordinate system corresponding to the ring-shaped subnet 4 is also located at the midpoint A3 of the start ring network element and the end ring network element of the ring-shaped subnet 4. According to FIG. 16, it can be seen that the third connection OC4 corresponding to the ring-shaped subnet 4 has a target intersection point with the reference figure.
- the vertex of the double parabola corresponding to the ring-shaped subnet 4 is located at the target intersection point, and the The y-coordinate direction of the third graphics coordinate system corresponding to the ring-shaped subnet 4 may point to the direction of the origin of the third graphics coordinate system along the target intersection point.
- the x coordinate direction of the third graphic coordinate system can be used.
- Step 2044c2 Based on the sixth total number corresponding to any ring-shaped subnet, the corresponding third graphic coordinate system and corresponding graphic parameter, and the corresponding layout width, determine the position of each ring network element in any ring-shaped subnet information.
- any ring-shaped subnet can be determined according to the sixth total number corresponding to each ring-shaped subnet, the corresponding third graphic coordinate system and the corresponding graphic parameter, and the corresponding layout width
- the location information of each ring network element in the network can be determined according to the following two principles according to the approximate location of the ring network element whose position information is to be determined:
- the sixth total number I4 corresponding to any ring-shaped subnet, the corresponding third graphics coordinate system and the corresponding ellipse graphics parameters a and b, and any ring type The location information (x i , y i ) of each ring network element i in the subnet can satisfy:
- the sixth total number I4 corresponding to any ring-shaped subnet, the corresponding third graphics coordinate system and the corresponding ellipse graphics parameters a and b, and the any ring-shaped can satisfy:
- the implementation process of this step 2044c2 may include:
- Step 2044c21 based on the layout width corresponding to any ring-shaped subnet, the corresponding sixth total number, the corresponding graphic parameters, and the distance between the start ring network element and the end ring network element in any ring-shaped subnet, in any Among the multiple ring network elements included in the ring-shaped subnet, the target ring network element that is the vertex of any ring-shaped subnet is determined.
- step 2044c21 may include:
- Step c211 Based on the graphic parameters corresponding to any ring-shaped subnet and the corresponding layout width, and the distance between the start ring network element and the end ring network element in any ring-shaped subnet, determine the correspondence of any ring-shaped subnet The first arc length and the second arc length of the third graph.
- the first arc length is the length of the arc located on the left side of the vertex of the third figure
- the second arc length is the length of the arc located on the right side of the vertex of the third figure.
- the calculation formula of the first arc length L l and the second arc length L r can be:
- ⁇ 4 is the layout width of the double parabola
- d is the distance between the start ring network element and the end ring network element in any ring-shaped subnet
- a1 and a2 are the graphical parameters of the double parabola, respectively.
- Step c212 Based on the first arc length and the second arc length corresponding to any ring-shaped subnet, and the sixth total number corresponding to any ring-shaped subnet, determine the target ring network element that is the vertex of any ring-shaped subnet .
- the vertex of the any ring-shaped subnet may be determined Target ring network element.
- the order t of the target ring network element among the plurality of attached network elements, the sixth total number I4 of the plurality of attached network elements, the first arc length L l and the second arc length L r may satisfy:
- round is a rounding function.
- counting can be started from the start ring network element to the end ring network element, and the ring network element counted to t can be determined as the The target ring network element of the vertex of any ring-shaped subnet.
- Step 2044c22 Based on the layout width corresponding to any ring-shaped subnet, the order of the target ring network element in multiple ring network elements in any ring-shaped subnet, the start ring network element and the end ring network in any ring-shaped subnet The distance between the elements, the third graphic coordinate system corresponding to any ring-shaped subnet and the corresponding graphic parameters determine the position information of each ring network element.
- the x coordinate of the ring network element should satisfy the following equation, and since the equation is a monotonic function within the respective interval,
- the layout width and the distance can be brought into the equation and passed through the dichotomy Iteratively solve the x coordinate of each ring network element, and then substitute the x coordinate into the standard equation of the double parabola to obtain the y coordinate corresponding to the x coordinate, and then obtain the position information of each ring network element.
- ⁇ 5 is the layout width corresponding to any ring-shaped subnet
- d is the distance between the start ring network element and the end ring network element in any ring-shaped subnet
- t is the target ring network element in the any
- a1 and a2 are the graphical parameters of the double parabola respectively
- I4 is the sixth total number of down-linking network elements of any ring-shaped subnet
- L l is the The first arc length of the double parabola corresponding to any ring-shaped subnet
- L r is the second arc length of the double parabola corresponding to any ring-shaped subnet.
- the ring network element when the ring network elements are laid out according to the first layout method, since the positional relationship of each ring network element is determined according to the third graphical coordinate system corresponding to each ring-shaped subnet, therefore, After obtaining the position information of each ring network element in the third graphics coordinate system, the ring network element needs to be located in the third graphics coordinate according to the corresponding third image coordinate system and the global coordinate system corresponding to the network topology The position information in the system is converted into the global coordinate system to obtain the position information under the same reference standard.
- the coordinates (x, y) of the ring network element before conversion and the coordinates (x', y') after conversion may satisfy:
- ⁇ is the rotation angle of the third image coordinate system relative to the global coordinate system
- dx is the x-axis offset of the third image coordinate system relative to the global coordinate system
- dy is the third image coordinate system relative to the global The size of the y coordinate direction of the coordinate system.
- step 2044c may include:
- the x coordinate of the ring network element should satisfy the following equation, and since the equation is in the interval [-w/2, w/2]
- the monotone function within, therefore, after determining the sixth total number of network elements hanging under any ring-shaped subnet, the corresponding graphics parameters and the corresponding layout width, the layout width and the distance can be brought into the equation, where Within the range defined by the position information of the start ring network element and the end ring network element of any ring-shaped subnet, the position information of each ring network element in any ring-shaped subnet in the first direction is solved by bisection iteration .
- the equation that the x coordinate of the ring network element should satisfy is:
- I4 is the sixth total number of network elements hanging under the any ring-shaped subnet
- a is the graphic parameter of the any ring-shaped subnet
- w is the layout width of the any ring-shaped subnet.
- Step 2044c4 Based on the corresponding graphic parameters and the position information of any ring network element in the first direction, determine the position information of any ring network element in the second direction.
- the position information of the ring network element in the first direction can be brought into the third figure corresponding to the ring type subnet
- the position information of the ring network element in the second direction is obtained by solving the equation.
- the network usually includes multiple ring-shaped subnets.
- the position information of the next ring network element is usually determined by traversing and iterating. And in the process of this traversal iteration, the network element corresponding to the shortest path of the current network element is determined as the next ring network element that needs to calculate position information, but when the network structure is more complicated, the performance of this iterative calculation method is lower , Resulting in lower efficiency of network element location information in the network.
- the network can be divided into several clusters according to the network connectivity and the shortest path principle, and the location information of the ring network elements in the ring subnet belonging to the same cluster can be calculated first. Then calculate the location information of the ring network elements in the ring subnet between different clusters.
- the implementation process of clustering the network may include: dividing directly connected secondary network elements into the same group, and then dividing each remaining network element to the nearest path according to the distance of each remaining network element to the secondary network element After the grouping of the secondary network elements in the group is completed, the set of network elements and links included in each group is a cluster. In addition, if the path from some other network element to the secondary network elements in different groups is equal, the network element can be divided into any group. And the core network element can be used as a public network element and belongs to each cluster. Exemplarily, as shown in FIG.
- network element F1 and network element F2 belong to the core network element
- network element F4, network element F3, network element F5 and network element F6 belong to the secondary network element
- network elements F7 to F16 belong to the lower level
- the network element can be divided into four clusters as shown in FIG. 30: cluster 1, cluster 2, cluster 3, and cluster 4. Among them, the network elements located in the same dotted circle belong to the same cluster.
- cross-cluster links can be incorporated into the ring subnet by the following strategy, so that in the calculation process of the ring subnet, each ring network element is connected according to the connection relationship between the ring network elements Perform traversal to improve the efficiency of traversal, and then improve the efficiency of calculating the location information of ring network elements.
- the process of incorporating the cross-ring link into the ring-shaped subnet may include: using any cross-ring link as an initiating point, searching for any network element on the link to other network elements except the link network element route of.
- the path from any network element to the ring network element in the cluster is the shortest path from the path of any network element to other network elements, it can be determined that the link and all network elements passing through the shortest path form a minimum ring
- the network element on the smallest ring structure can be determined as the ring network element newly added to the ring-shaped subnet, that is, the process of merging the cross-ring link into the ring-shaped subnet is completed.
- the path from any network element to the ring network element in the cluster is not the shortest path from the path of any network element to other network elements, continue to traverse other cross-ring links until all the spans in the cluster are traversed Ring link. And during the traversal process, the traversal can be performed in order from the highest network level. And in the process of calculating the shortest path, priority can be given to the same-layer ring subnet, dual-homed ring subnet, and then single-homed ring subnet and cross-layer ring subnet to reduce link crossover in the network To make the ring structure more obvious.
- the process of merging the cross-cluster link into the ring-shaped subnet may include: first finding network elements that are not ring network elements in the cross-cluster link, and calculating the shortest path to the ring network element in any cluster,
- the network element passing through the shortest path and the cross-cluster link may form a cross-layer ring.
- the network element passing through the shortest path may be updated to a new ring network element on the ring where the ring network element is located, and the The process of merging cross-cluster links into a ring-shaped subnet.
- the lower ring of the newly entered ring network element in the corresponding cluster is calculated. Then continue to traverse other cross-cluster links until all cross-cluster links are traversed.
- the network element whose location information is to be determined is a tree network element
- the location information of type network elements can effectively reduce the crossover between network element links in the obtained network topology.
- step 204 is different. The following describes the implementation of step 204 for different types of tree subnets:
- step 204 may include :
- Step 2041d1 among the multiple tree network elements constituting the tree-shaped subnet, determine the first root network element.
- the network element with the highest network level is the first network element of the tree subnet. And there is usually only one first network element in each tree-shaped subnet. Therefore, when the step 2041d1 is performed, the tree network element with the highest network level in the tree-type subnet may be determined as the first root network element of the tree-type subnet.
- Step 2042d1 Acquire the layout start position of each tree network element.
- multiple other tree network elements connected to the same first root network element are arranged on a circle with the first root network element as the center and a specified length as the radius. That is, the tree network elements at the same depth in the tree-shaped subnet can be laid out on an arc with a specified radius and the first network element as the center, and the tree network elements of different depths can be respectively laid out at different radii And on the arc with the first network element as the center. And the greater the depth of the tree network element, the larger the radius of the arc corresponding to the tree network element. At this time, it can be considered that the tree network elements in each tree-shaped subnet are laid out on the arc tree model. For a schematic diagram, please refer to FIG. 32. The black dots in FIG.
- FIG. 32 are tree network elements.
- the solid line between is used to indicate that there is a connection relationship between the two tree network elements.
- FIG. 32 tree network elements with the same depth are laid out on the arc of the same circle, and tree tree elements with different depths are laid out with the same center but different radii.
- the other tree network element is a tree network element outside the root network element in the tree-shaped subnet.
- the layout start position of each tree network element can be characterized by the layout start angle.
- the implementation method of obtaining the layout start angle can include:
- the layout start angle of the first root network element may be -180 degrees.
- the first root network element is a non-isolated network element in the first layout mode, as shown in FIG. 33, based on the location information of the first root network element A and the designated point O, the first root network element A and The straight line where the specified point O is located is determined as the target straight line, and the angle between the target ray OZ and the specified straight line is determined as the layout start angle ⁇ of the first network element A.
- the target ray OZ is a ray perpendicular to the target straight line, and the emission direction is away from the specified point.
- the specified straight line may be a straight line in the x coordinate direction in the global coordinate system.
- the tree-shaped subnet to which other tree network elements belong is a short tree subnet, or other tree network elements are non-isolated network elements in the first layout mode
- you can match Multiple child network elements connected to the same parent network element are sorted to obtain a third network element queue.
- layout width and width of the parent network element connected to any other tree network element, and the width of other tree network elements that are located before the any other tree network element in the third network element queue Determine the starting angle of the layout of any other tree network element.
- the other tree network element is a tree network element except the first root network element among the multiple tree network elements.
- the width w c i of the other tree network elements i before the tree network element, and the layout start angle a c t of any other tree network element can satisfy:
- each tree network element is equal to the sum of the widths of the sub-network elements of the tree network element, and the width of the tree network element without sub-network elements is 1.
- the tree-shaped subnet includes: tree network element e1, tree network element e2, tree network element e3, tree network element e4 and tree network element e5, and tree network element e4 and tree network element e5 are
- the tree network element e3 is a sub-network element, and the tree network element e2 and the tree network element e3 are sub-network elements of the tree network element e1.
- the tree network element e2, the tree network element e4 and the tree network element e5 have no sub-network elements, it can be determined that the width of the tree network element e2, the tree network element e4 and the tree network element e5 are all 1, and the width of the tree network element e3 is The sum of the width of the tree network element e4 and the width of the tree network element e5, that is, the width of the tree network element e3 is 2, and the width of the tree network element e1 is the width of the tree network element e2 and the width of the tree network element e3 And, that is, the width of the tree element e1 is 3.
- Step 2043d1 Obtain the layout width of each tree network element.
- the layout width of each tree network element can be characterized by the fifth angle.
- the fifth angle of the first network element is 180 degrees.
- the fifth angle between the parent network element connected to any other tree network element and The width determines the fifth angle of any other tree network element.
- the fifth angle ⁇ c t of the any other tree network element t , the width w c t of any other tree network element, and the fifth angle ⁇ of the parent network element to which the other tree network element is connected f and width w f can satisfy:
- the layout width of the tree network elements can be allocated according to the width of the tree network elements, thereby ensuring that no crossover occurs between all tree network elements under the same root network element.
- Step 2044d1 Obtain the depth of each other network element.
- the depth of each network element in the tree subnet is equal to the total number of network elements included in the shortest path from the network element to the root network element of the tree subnet. Therefore, when this step 2044d1 is performed, for any other network element, the shortest path from any other network element to the root network element of the tree subnet where the other other network element is located can be determined first, and the shortest path can be counted The total number of network elements included in the path. The total number is the depth of any other ring network element.
- Step 2045d1 based on the depth of any other tree network element, the start position and the width of the layout, and the position information of the first network element, determine the position information of any other tree network element.
- the depth p of the any other tree network element, the layout start position ⁇ , the layout width ⁇ 6, the position information of the first network element (x 0 , y 0 ), and the position of the any other tree network element Information (x, y) can satisfy:
- h is the height constant of each layer of the tree.
- the isolated network elements can be connected in a tree type.
- the following takes the isolated network elements as tree network elements in a tree subnet as an example.
- the implementation process is explained. As shown in FIG. 35, the implementation process of step 204 may include:
- Step 2041d2 Determine the second root network element among the multiple tree network elements constituting the tree-shaped subnet.
- step 2041d2 For the implementation process of this step 2041d2, please refer to the implementation process of step 2041d1 accordingly.
- Step 2042d2 Sort the second root network elements in all the isolated tree subnets to obtain a fourth network element queue.
- the multiple second root network elements in the network can be randomly ordered initially, and according to the multiple second root
- the depth of the network element adjusts the initial sorting result to obtain the fourth network element queue.
- the process of adjusting the initial sorting result may be performed according to the principle of diverging the second network element corresponding to multiple isolated tree subnets with a greater depth.
- the depth of the isolated tree-type subnet may be equal to the depth of the tree network element with the maximum depth in the isolated tree-type subnet.
- Step 2043d2 Obtain the layout width of each tree network element.
- the layout width of each tree network element may be characterized by a fifth angle.
- the width of each tree network element may be obtained according to the connection relationship between the tree network elements, and the layout width of each tree network element may be determined based on the width of each tree network element.
- the width of the tree network element there is a correspondence between the width of the tree network element and the included angle.
- Step 2044d2 Obtain the layout start position of each tree network element.
- the isolated network element may be arranged outside the layout area of the non-isolated network element.
- the black dots in FIG. 36 indicate isolated network elements.
- the solid line between each two isolated network elements is used to indicate that there is a connection relationship between the two isolated network elements.
- isolated network elements can be arranged outside the circular area where non-isolated network elements are located. And isolated network elements with connection relationships can be laid out in a tree-shaped subnet.
- the layout start position of each tree network element can be characterized by the layout start angle, and the layout start angle can be represented by the center angle of the circular area.
- the second when determining the layout start angle of any second root network element, the second may be determined based on the width of other second root network elements that are located before the second root network element in sequence in the fourth network element queue The starting position of the root network element. For example, it can be assumed that the layout start angle of the first second network element in the fourth network element queue is 0, then the layout start angle ⁇ t of the tth second network element in the fourth network element queue, the fourth The width of the i-th root network element in the network element queue is w i , which can satisfy:
- ⁇ is a constant angle difference between every two adjacent second network elements.
- Step 2045d2 based on the specified radius, the sum of the widths of all second network elements, and the sum of the widths of other second network elements in the fourth network element queue before any second network element in sequence The location information of a second network element.
- the specified radius may be the maximum value of the distance from the non-isolated network element to the origin as the radius Rr. In this way, all isolated network elements can be arranged outside the non-isolated network element, so that there is no interference between the isolated network element and the non-isolated network element.
- the position information (x t , y t ) of the t-th second network element in the fourth network element queue specifies the radius Rr, the sum of the widths of all the second network elements in the fourth network element queue, ⁇ w, And the sum of the widths of other second network elements that are located before the t-th second network element in the fourth network element queue Can meet:
- Step 2046d2. Determine the location information of any other tree network element based on the layout start position and layout width of any other tree network element, and the location information of the first root network element.
- step 2046d2 For the implementation process of this step 2046d2, please refer to the implementation process of step 2045d1 accordingly.
- step 204 may include:
- Step 2041d3 Acquire position information of the second center of gravity of the entire network composed of multiple tree-shaped subnets.
- the implementation process of step 2041d3 may include: determining The position information of the second center of gravity of the overall network in the x coordinate direction.
- the second center of gravity of the overall network can be understood as the center of gravity of the overall network in the x coordinate direction.
- the position information of the second center of gravity of the overall network in the x coordinate direction is equal to the quotient of the sum of the coordinates of the original root network elements of all tree subnets in the overall network in the x coordinate direction and the number of long trees.
- Step 2042d3 Obtain the width of each tree-shaped subnet.
- the width of the tree-shaped subnet may be equal to the width of the root network element in the tree-shaped subnet.
- Step 2043d3 Sort the multiple tree-shaped subnets according to the position information of the third root network element of each tree-shaped subnet to obtain a second network queue.
- the third root network element may be the root network element in the tree-shaped subnet of the tree-shaped subnet.
- the multiple tree-type subnets may be sorted in order of the smallest value of the x value of the third network element in the tree-type subnet to which the multiple tree-type subnets belong, to obtain The second network queue.
- Step 2044d3. Determine any tree type based on the width of each tree type subnet, the position information of the second center of gravity, and the width of other tree type subnets that are located before any tree type subnet in the second network queue Location information of the third network element of the subnet.
- the layout manner of the tree network elements in the tree-shaped subnet may satisfy that: the tree network elements at the same depth may be laid out on a horizontal line, and the projections of all tree network elements on the same horizontal plane form equidistant points Arrange. That is, the tree network elements in the tree-shaped subnet can be laid out on the straight-line tree model.
- FIG. 38 is a schematic structural diagram of a straight-line tree model provided by an embodiment of the present application. Black dots in FIG. 38 represent network elements, and solid lines between network elements indicate that there is a connection relationship between network elements. As shown in FIG.
- tree network elements at the same depth can be laid out on a horizontal line, and the points formed by the projection of all tree network elements on the same horizontal plane are arranged at equal intervals (that is, every two adjacent arrows in FIG. 38 The spacing between them is equal), the vertical spacing of each adjacent tree network element at two adjacent depths is equal, and the width occupied by each tree network element is proportional to the width of the tree network element.
- each layer of network elements of the tree-shaped subnet is distributed on a horizontal line, which can be allocated according to the width of the tree network element
- the size of the horizontal width ensures that there is no cross between all tree network elements under the same root network element.
- the position information (x j , y j ) of the j th third network element in the second network queue, the width w i of each tree-shaped subnet, and the th can satisfy:
- k5 is the constant of multiples of the length of the long tree
- d tw is the constant of the distance between the tree subnets in the x coordinate direction
- d th is the constant of the distance between the long tree network element and other network elements in the y coordinate direction
- ymin2 is The minimum value of the non-long tree network element in the y coordinate direction
- I5 is the total number of tree subnets in the second network queue.
- Step 2045d3 Sort multiple child network elements connected to the same parent network element according to the connection relationship between the tree network elements to obtain a fifth network element queue.
- the multiple sub-network elements may be randomly ordered initially, and the initial sorting result may be adjusted according to the widths of the multiple sub-network elements to obtain the first Five network element queues.
- the process of adjusting the initial sorting result may be performed according to the principle of diverging multiple sub-network elements with a larger width.
- Step 2046d3 based on the location information of the parent network element to which any other tree network element is connected, the width of any other tree network element, and other tree networks that are positioned before any other tree network element in sequence in the fifth network element queue The location information and width of the element determine the location information of any other tree network element.
- the width w t of any other tree network element, and the order in the fifth network element queue The width w i of the other tree network element before the other tree network element, the position information of the other network element in the x-coordinate direction x c t-1 before the other tree network element in the fifth network element queue, and the first
- the position information (x c t , y c t ) of the t-th other tree network element in the five network element queue can satisfy:
- k5 is a constant constant of multiples of the length of the long tree
- h is a constant of the height of each layer of the tree
- I6 is the total number of other tree network elements in the fifth network element queue.
- Step 205 Establish a network topology based on the connection relationship between multiple network elements and the location information of each network element.
- the network topology can be visualized according to the connection relationship between the location information and the network element in the network, which plays a pivotal role in the representation and analysis of network networking information . For example, it can be of great reference significance for network resource management, evaluation and analysis, planning and design, implementation of rectification and routine maintenance.
- FIG. 39 for a schematic diagram of a network topology obtained according to the method for determining a network topology provided by an embodiment of the present application.
- the network elements in the network topology are distributed from inside to outside starting from the geometric center of the figure, and the core network elements in the network topology are arranged on a circle centered at the geometric center.
- the secondary network elements are arranged on a concentric circle centered on the geometric center and including two circles.
- a part of the ring network elements is arranged on a double parabola, and the other part of the ring network elements is arranged on an ellipse.
- the elements are arranged on the arc tree model, and the isolated network elements are arranged in the area outside the circular area where the non-isolated network elements are located.
- FIG. 40 a schematic diagram of the network topology obtained according to the method for determining the network topology provided by the embodiments of the present application.
- the network elements in the network topology (shown as black dots) are distributed from top to bottom, and the core network elements in the network topology are arranged on a circular arc, and the ring network elements are arranged in a single
- the tree elements in the short tree subnet are laid out on the arc tree model, and the tree elements in the long tree subnet are laid out on the straight tree model.
- FIG. 39 and FIG. 40 there are fewer link crossings in the network topology, the network topology has better symmetry, and the network topology can more clearly present the structure of the network and the network of network elements Hierarchy and the relationship between different subnets.
- the present application provides a method for determining the network topology. Based on the connection relationship between multiple network elements and the network level of each network element, multiple sub-networks are separately determined according to the network of network elements in the network. Hierarchical order, based on the connection relationship between each network element in each subnetwork, determine the location information of each network element, and based on the connection relationship between multiple network elements and the location information of each network element To establish a network topology, compared to related technologies, it can automatically obtain the location information of the network element, without manually adjusting the network topology, which effectively improves the efficiency of obtaining the network topology.
- the obtained network topology can clearly present the structure of the network and the network of network elements Hierarchy and the relationship between different subnets.
- the graphics used in determining the location information of the network element are all graphics with good symmetry, the obtained network topology has good symmetry.
- the process of calculating the location information of the network element by using definite integration, dichotomy iteration, graphics parameter solution and coordinate transformation to simplify the calculation, it can reduce the time-consuming determination of the location information of the network element and solve the related algorithm The problem of non-convergence and low efficiency.
- FIG. 41 shows a block diagram of an apparatus 900 for determining a network topology provided by an exemplary embodiment of the present application.
- the apparatus 900 may include:
- the obtaining module 901 is used to obtain a connection relationship between a plurality of network elements constituting the network and a network level of each network element, and the network level is used to reflect the importance of the network element in the network.
- the first determining module 902 is configured to determine multiple sub-networks based on the connection relationship between multiple network elements and the network level of each network element.
- the second determining module 903 is configured to determine the location information of each network element based on the connection relationship between each network element in each sub-network according to the order of the network level of the network element in the network from high to low.
- the establishment module 904 is used to establish a network topology based on the connection relationship between multiple network elements and the location information of each network element.
- the second determination module 903 is configured to:
- the location information of each core network element is determined.
- the second determination module 903 is used to determine the location information of each core network element based on the first distance and the total number of core network elements.
- the first fixed-length parameter of the first figure is determined, and the first fixed-length parameter is used to reflect the geometric characteristics satisfied by the points on the first figure.
- the position information of the core network element is determined in sequence based on the first fixed-length parameter and the first spacing.
- the first graphic includes: a circle, an ellipse, or a regular polygon.
- the second determining module 903 is used to obtain the first distance between every two adjacent core network elements in the first network element queue, which is specifically used to: The first total number of hanging network elements determines the first distance.
- the first distance is characterized by a first angle between the connection between each core network element and the designated point in the two core network elements, and the second determination module 903 is used to determine the distance between the two core network elements
- the first total number of network elements to be hung down is specifically used when determining the first distance:
- the first total number accounts for the first total number of the second total number
- the second total number is the total number of the down-linking network elements of all core network elements.
- the product of the first total proportion and 360 degrees is determined as the first included angle.
- the second determination module 903 is configured to:
- multiple secondary network elements of the secondary sub-network are divided into multiple first network element groups, and the secondary network elements are the network elements directly connected to the core network element among the multiple network elements,
- the core network element is the network element with the highest network level among multiple network elements.
- the layout width of each first network element group is determined based on the third total number of drop-down network elements of all secondary network elements in each first network element group.
- the layout start position of any first network element group is determined.
- layout start position Based on the layout width, layout start position, the total number of multiple first network element groups, the second network element queue, the network element group queue, and the total number of secondary network elements in each first network element group, determine each Location information of two secondary network elements.
- a plurality of secondary network elements are arranged on the boundary of at least one second graphic, and the second determination module 903 is used to determine the width of the layout, the start position of the layout, the total number of the plurality of first network element groups, the second The total number of network element queues, network element group queues, and secondary network elements in each first network element group is used to determine the location information of each secondary network element:
- the second figure where each secondary network element is located is determined.
- the second fixed-length parameter of each second figure is determined, and the second fixed-length parameter is used to reflect the geometry satisfied by the point on the corresponding second figure feature.
- each secondary network element in the second network element queue and the network element group queue based on the second fixed-length parameter corresponding to the secondary network element, the layout width, the layout start position, and each secondary network element The total number of secondary network elements in the first network element group to determine the location information of the secondary network elements.
- each second graphic is located outside the first graphic corresponding to the core network element.
- the second graphic When at least one second graphic is a second graphic, the second graphic includes: a circle, an ellipse, or a regular polygon.
- the overall figure formed by the plurality of second figures includes: concentric circles, concentric ellipses or concentric regular polygons.
- the second determining module 903 is used to sort multiple first network element groups to obtain a network element group queue, which is specifically used to:
- the first network element groups are initially sorted to obtain an initial network element group queue.
- the target distance is the first network element group in the initial network element group The distance from the position in the column to the center position of the initial network element group queue.
- the layout width of each first network element group is characterized by a second included angle between the connection between the two outermost network elements in the first network element group and the designated point, and the second determination module 903 is used to determine the layout width of each first network element group based on the third total number of the drop-down network elements of all secondary network elements in each first network element group, specifically used for:
- the third total number corresponding to any first network element group accounts for the second total number of the fourth total number
- the fourth total number is the total number of the down-link network elements of all secondary network elements in the plurality of first network element groups.
- the second included angle of any first network element group is determined.
- the layout start position of each first network element group is characterized by the layout start angle.
- the layout start angle is the offset angle of the line connecting the layout start position and the specified point with respect to the specified 0 degree.
- the second determination module 903 uses When determining the starting position of the layout of any first network element group based on the layout width of each first network element group and the order of any first network element group in the network element group queue, it is specifically used to:
- the second determination module 903 is configured to:
- At least one ring-shaped subnet is divided into at least one second network element group, the network elements in the ring-shaped subnet are connected in a ring, and the network elements belonging to the ring-shaped subnet are ring network elements.
- the layout width of any ring-shaped subnet is determined.
- the corresponding graphic parameters, the corresponding layout width, and the position information of the start ring network element and the end ring network element of any ring-shaped subnet determine any task Location information of each ring network element in a ring-shaped subnet.
- the second determining module 903 is configured to be based on the sixth total number of down-linking network elements in any ring-shaped subnet, corresponding graphic parameters, corresponding layout width, and the start ring network element of any ring-shaped subnet And the location information of the end ring network element, when determining the location information of each ring network element in any ring subnet, it is specifically used for:
- the iterative algorithm obtains the position information of each ring network element in the first direction in any ring-shaped subnet.
- the position information of any ring network element in the second direction is determined.
- the second determination module 903 is also used to:
- the second determining module 903 when used to determine the graphic parameter of the third graphic corresponding to the ring network element of any ring-shaped subnet, it is specifically used to:
- the position information of the first center of gravity of any second network element group is determined.
- the level determines the position information of at least one target ring network element in the ring network element directly connected to the start ring network element and the ring network element directly connected to the end ring network element.
- the figure parameter is determined.
- the second determining module 903 is configured to be based on the sixth total number of down-linking network elements in any ring-shaped subnet, corresponding graphic parameters, corresponding layout width, and the start ring network element of any ring-shaped subnet And the location information of the end ring network element, when determining the location information of each ring network element in any ring subnet, it is specifically used for:
- the third graphic coordinate system corresponding to any ring-shaped subnet is determined.
- the position information of each ring network element in any ring-shaped subnet is determined.
- the second determining module 903 is used to determine each ring network in any ring-shaped subnet based on the sixth total number corresponding to any ring-shaped subnet, and the corresponding third graphics coordinate system and corresponding graphics parameters
- the location information of yuan is used to:
- the target ring network element that is the vertex of any ring-shaped subnet is determined.
- the order of the target ring network element among multiple ring-shaped network elements in any ring-shaped subnet, between the start ring network element and the end ring network element in any ring-shaped subnet The distance, the third graphic coordinate system corresponding to any ring-shaped subnet and the corresponding graphic parameter, determine the position information of each ring network element.
- the second determination module 903 is configured to be based on the layout width corresponding to any ring-shaped subnet, the corresponding sixth total number, the corresponding graphic parameter, and the start ring network element and the end ring network in any ring-shaped subnet
- the distance between the elements is specifically used to determine the target ring network element that is the vertex of any ring-shaped subnet among the multiple ring network elements included in any ring-shaped subnet:
- the first arc length and the second arc length of the figure, the first arc length and the second arc length are respectively the lengths of the arcs located on both sides of the vertex of the third figure.
- the target ring network element that is the vertex of any ring-shaped subnet is determined.
- the second determining module 903 is used to determine the third graphics coordinate system corresponding to any ring-shaped subnet based on the position information of the start ring network element and the end ring network element of any ring-shaped subnet. in:
- the midpoint of the start ring network element and the end ring network element of any ring-shaped subnet is determined as the coordinate origin of the third graphics coordinate system corresponding to any ring-shaped subnet.
- the reference graphic is a circle with the specified fixed length as the radius and the coordinate origin of the corresponding third graphic coordinate system as the center of the circle.
- the target intersection point is the intersection point of the reference pattern corresponding to the second network element group where any ring-shaped subnet is located and the third connection line of any ring-shaped subnet.
- the vertex of the type subnet and the designated point are located on the third connection.
- the direction of the line connecting the coordinate origin of the corresponding third graphics coordinate system and the target intersection is determined as the second direction of the corresponding third graphics coordinate system, and the direction perpendicular to the second direction is determined as the corresponding third graphics coordinate The first direction of the department.
- the second determining module 903 is used to determine the third graphics coordinate system corresponding to any ring-shaped subnet based on the position information of the start ring network element and the end ring network element of any ring-shaped subnet. in:
- the first relative position of the geometric center of the third graphic corresponding to any ring-shaped subnet in the third graphic is determined.
- the position information of the geometric center corresponding to any ring-shaped subnet is determined as the position information of the origin of the corresponding third graphics coordinate system, and the connection line between the geometric center corresponding to any ring-shaped subnet and the corresponding home point is located
- the direction is determined as the first direction of the third graphics coordinate system corresponding to any ring-shaped subnet, and the direction perpendicular to the first direction is determined as the second direction of the third graphics coordinate system corresponding to any ring-shaped subnet.
- the second determining module 903 when used to determine the graphic parameter of the third graphic corresponding to the ring network element of any ring-shaped subnet, it is specifically used to:
- the first perimeter of the third figure corresponding to any ring-shaped subnet is estimated.
- the second perimeter of the third figure is determined.
- the graphic parameters corresponding to any ring-shaped subnet are obtained.
- the second determining module 903 is used to obtain the graphic parameters corresponding to any ring-shaped subnet based on the first perimeter and the second perimeter, specifically:
- the first sub-parameter in the graphics parameter corresponding to any ring-shaped subnet is obtained.
- the layout width corresponding to any ring-shaped subnet, and the distance between the start ring network element and the end ring network element in any ring-shaped subnet determine any
- the other sub-parameters in the graphic parameters corresponding to the ring-shaped subnet can obtain the graphic parameters corresponding to any ring-shaped subnet.
- the second determining module 903 when used to divide at least one ring-shaped subnet into at least one second network element group, it is specifically used to:
- the second determining module 903 when used to divide at least one ring-shaped subnet into at least one second network element group, it is specifically used to: divide ring-shaped subnets with the same ring level into the same second network element group To get at least one second network element group.
- the layout width of any ring-shaped subnet is characterized by the third included angle of any ring-shaped subnet, and the second determination module 903 is used for based on the fifth total number of ring-shaped subnets in each second network element group ,
- the layout width of any ring-shaped subnet it is specifically used to determine the quotient of the fifth total number corresponding to any second network element group at 180 degrees as each ring type in any second network element group The third angle occupied by the subnet.
- the layout width of any ring-shaped subnet is characterized by the third included angle of any ring-shaped subnet, and the second determination module 903 is used for based on the fifth total number of ring-shaped subnets in each second network element group ,
- the layout width of any ring-shaped subnet specifically used for:
- the first connection is the connection between the ring network element and the specified point in any second network element group
- the second connection is any first connection End the connection between the ring network element and the designated point in the second network element group.
- the layout width of any ring-shaped subnet is characterized by the third included angle of any ring-shaped subnet, and the second determination module 903 is used for based on the fifth total number of ring-shaped subnets in each second network element group
- the layout width of any ring-shaped subnet it is specifically used to determine the layout width of any ring-shaped subnet based on the sixth total number corresponding to any ring-shaped subnet.
- the second determination module 903 is configured to:
- the first root network element is determined.
- the network elements in the tree-shaped subnet are connected in a tree shape, and the network elements that belong to the tree-shaped subnet are tree network elements.
- the other tree network element Based on the layout start position and layout width of any other tree network element, and the position information of the first root network element, determine the position information of any other tree network element, the other tree network element is the first among multiple tree network elements Tree NEs outside the root NE.
- the second determination module 903 is also used to:
- the second determination module 903 is used to determine the location information of any other tree network element based on the layout start position and layout width of any other tree network element and the location information of the first root network element, specifically:
- the location information of any other tree network element is determined.
- the layout start position of each tree network element is characterized by the layout start angle.
- the second determination module 903 is used to obtain the layout start position of each tree network element, it is specifically used to:
- the straight line where the first network element and the specified point are located is determined as the target straight line.
- the angle between the target ray and the specified line is determined as the layout start angle of the first network element.
- the target ray is a ray perpendicular to the target line and the emission direction is away from the specified point.
- the layout start angle of the first network element is -180 degrees.
- the layout start position of each tree network element is characterized by the layout start angle.
- the second determination module 903 is used to obtain the layout start position of each tree network element, it is specifically used to:
- multiple child network elements connected to the same parent network element are sorted to obtain a third network element queue.
- the layout width of each tree network element is characterized by a fifth angle.
- the second determination module 903 is used to obtain the layout width of each tree network element, it is specifically used to:
- the fifth angle of the first network element is 180 degrees.
- the fifth angle and width of the parent network element connected to any other tree network element determine the fifth of any other tree network element Angle.
- the second determining module 903 is also used to:
- the network elements in the isolated tree-type subnet are connected in a tree shape, and the network elements in the isolated tree-type subnet are isolated trees There is no connection path between the network element, the isolated tree network element and the core network element, and the core network element is the network element with the highest network level among multiple network elements.
- the sum of the widths of all second network elements, and the sum of the widths of other second root elements in the fourth network element queue in sequence before any second root element
- the location information of the root network element Based on the specified radius, the sum of the widths of all second network elements, and the sum of the widths of other second root elements in the fourth network element queue in sequence before any second root element The location information of the root network element.
- the layout start position of each tree network element is characterized by the layout start angle.
- the second determination module 903 is used to obtain the layout start position of each tree network element, it is specifically used: based on the fourth network element queue The width of the other second network elements that are located before any second network element in sequence determines the layout start position of the second network element.
- the layout width of each tree network element is characterized by a fifth angle.
- the second determination module 903 obtains the layout width of each tree network element, it is specifically used to:
- the width of each tree network element is obtained.
- the layout width of each tree network element is determined.
- multiple other tree network elements connected to the same first root network element are arranged on a circle with the first root network element as the center and a specified length as the radius.
- the second determination module 903 is configured to:
- each tree-shaped subnet sort the multiple tree-shaped subnets to obtain a second network queue.
- the position information of the second center of gravity, and the width of other tree-shaped subnets that are located before any tree-shaped subnet in the second network queue determine the The location information of the third network element.
- multiple child network elements connected to the same parent network element are sorted to obtain a fifth network element queue.
- the width of any other tree network element, and the positions of other tree network elements that are located before any other tree network element in sequence in the fifth network element queue Information and width to determine the location information of any other tree network element.
- the first determining module 902 is configured to: determine a network composed of core network element connections as a core sub-network, and the core network element is the network element with the highest network level.
- the first determining module 902 is used to:
- the network composed of other network elements connected in a ring is determined as a ring-shaped subnetwork, and the other network elements are network elements other than the core network element in the network.
- the network composed of other network elements connected in a tree shape is determined as a tree subnet.
- the network elements in the network topology start with the network element with the highest network level and are distributed from inside to outside in the order of the network level from high to low.
- the network elements in the network topology start from the network element with the highest network level and are distributed from top to bottom in the order of network level from high to low.
- the present application provides a device for determining a network topology.
- the first determination module determines multiple sub-networks based on the connection relationship between multiple network elements and the network level of each network element, and the second determines The module determines the location information of each network element based on the connection relationship between each network element in each sub-network according to the order of the network hierarchy of network elements from high to low, and based on the connection relationship between multiple network elements Comparing with the location information of each network element, the network topology is established. Compared with related technologies, it can automatically obtain the location information of the network element without manually adjusting the network topology, which effectively improves the efficiency of obtaining the network topology.
- the obtained network topology can clearly present the structure of the network and the network of network elements Hierarchy and the relationship between different subnets.
- the graphics used in determining the location information of the network element are all graphics with good symmetry, the obtained network topology has good symmetry.
- it can reduce the time-consuming determination of the location information of the network element and solve the related algorithm The problem of non-convergence and low efficiency.
- Each module in the above device can be implemented by software or hardware or a combination of software and hardware.
- the hardware may be a logic integrated circuit module, which may specifically include a transistor, a logic gate array, or an arithmetic logic circuit.
- the software exists in the form of a computer program product and is stored in a computer-readable storage medium.
- the software may be executed by a processor, that is, when the computer program product corresponding to the software is executed, the software is executed to realize the functions of the foregoing modules. Therefore, alternatively, the device for determining the network topology may be implemented by a processor executing a software program, which is not limited in this embodiment.
- Exemplary embodiments of the present application also provide an apparatus for determining a network topology.
- the device for determining the network topology may be a terminal.
- the device for determining the network topology includes: a processor and a memory.
- the processor executes the computer program stored in the memory
- the network topology determination device executes the network topology determination method provided by the embodiments of the present application.
- the processor is configured to: obtain the connection relationship between multiple network elements used to form the network and the network level of each network element, the network level is used to reflect the importance of the network element in the network; based on multiple networks
- the connection relationship between the elements and the network level of each network element separately determine multiple sub-networks; based on the order of the network level of the network elements in the network from high to low, based on the connection relationship between each network element in each sub-network, Determine the location information of each network element; establish the network topology based on the connection relationship between multiple network elements and the location information of each network element.
- FIG. 42 shows a schematic structural diagram of a network topology determination device 20 according to an exemplary embodiment of the present application.
- the network topology determination device 20 may include a processor 22 and a signal interface 24.
- the processor 22 includes one or more processing cores.
- the processor 22 executes various functional applications and data processing by running software programs and modules.
- the processor 22 may be a general-purpose processor, for example, a central processing unit (CPU), a forwarding chip, or a combination of a CPU and a forwarding chip.
- the processor may also be a hardware chip, and the hardware chip may be an application-specific integrated circuit (ASIC), a programmable logic device (programmable logic device, PLD), or a combination thereof.
- ASIC application-specific integrated circuit
- PLD programmable logic device
- the PLD may be a complex programmable logic device (complex programmable logic device, CPLD), a field programmable gate array (field-programmable gate array, FPGA), a general array logic (generic array logic, GAL), or any combination thereof.
- the forwarding chip may include a network processor (NP), FPGA or ASIC.
- the signal interface 24 is used to establish a connection with other devices or modules.
- the signal interface 24 may be used to connect with a transceiver. Therefore, optionally, the device 20 may further include the transceiver (not shown in the figure).
- the transceiver specifically performs signal transmission and reception.
- the processor 22 needs to perform the signal transceiving operation, it can call or drive the transceiver to perform the corresponding transceiving operation. Therefore, when the device 20 performs signal transmission and reception, the processor 22 is used to determine or initiate a transmission and reception operation, which is equivalent to an initiator, and the transceiver is used to perform specific transmission and reception, which is equivalent to an executor.
- the transceiver may also be a transceiver circuit, a radio frequency circuit or a radio frequency unit, which is not limited in this embodiment.
- the device 20 for determining the network topology further includes a memory 26, a bus 28, and other components.
- the memory 26 and the signal interface 24 are respectively connected to the processor 22 through a bus 28.
- the memory 26 can be used to store software programs and modules. Specifically, the memory 26 may store a program module 262 required for at least one function, and the program may be an application program or a driver program.
- program module 262 may include:
- the obtaining unit 2621 has the same or similar function as the obtaining module 901.
- the first determining unit 2622 has the same or similar function as the first determining module 902.
- the second determining unit 2623 has the same or similar function as the second determining module 903.
- the establishment unit 2624 has the same or similar function as the establishment module 904.
- An embodiment of the present application also provides a storage medium.
- the storage medium may be a non-volatile computer-readable storage medium, and a computer program is stored in the storage medium, and the computer program instructs a network topology determination apparatus to execute the embodiment of the present application. Any method of determining the network topology.
- the storage medium may include: read-only memory (read-only memory, ROM) or random access memory (random access memory, RAM), magnetic disk or optical disk, and other media that can store program codes.
- An embodiment of the present application also provides a computer program product containing instructions.
- the computer program product runs on a computer, the computer is caused to execute the method for determining the network topology provided by the embodiment of the present application.
- the computer program product may include one or more computer instructions. When the computer program instructions are loaded and executed on the computer, all or part of the processes or functions described in the embodiments of the present application are generated.
- the computer may be a general-purpose computer, a dedicated computer, a computer network, or other programmable devices.
- the computer instructions may be stored in a computer-readable storage medium or transmitted through the computer-readable storage medium.
- the computer-readable storage medium may be any available medium that can be accessed by a computer or a data storage device including a server, a data center, and the like integrated with one or more available media.
- the available media may be magnetic media (eg, floppy disk, hard disk, magnetic tape), optical media (eg, DVD), or semiconductor media (eg, solid state disk (SSD)), or the like.
- the program may be stored in a computer-readable storage medium.
- the mentioned storage medium may be a read-only memory, a magnetic disk or an optical disk.
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Data Mining & Analysis (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
本申请公开了一种网络拓扑的确定方法及装置,属于通信技术领域。装置包括:获取模块,用于获取用于组成网络的多个网元之间的连接关系和每个网元的网络层级,该网络层级用于反映网元在网络中的重要程度;第一确定模块,用于基于多个网元之间的连接关系和每个网元的网络层级,分别确定多个子网络;第二确定模块,用于按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息;建立模块,用于基于多个网元之间的连接关系和每个网元的位置信息,建立网络拓扑。本申请有效地提高了获取网络拓扑的效率。
Description
本申请要求于2018年12月27日提交的申请号为201811613944.0、发明名称为“网络拓扑的确定方法、装置及系统”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
本发明涉及网络技术领域,尤其涉及一种网络拓扑的确定方法、装置及系统。
网络拓扑(network topology)是通过传输介质互相连接的各个网元的物理布局。网络拓扑通常是根据网络中各个网元的连接方式获得的。获取网络拓扑是对网络进行评估、规划和维护的重要基础,因此,快速、清晰地获取网络拓扑是所有业务的迫切需求。
相关技术中,在获取网络中各个网元的连接方式后,可以先根据该连接方式,通过胡克定律建立整个网络的能量模型,然后通过迭代方式对网元进行移动,并在网元使能量模型的能量取得最小值时,将该最小值对应的位置确定为该网元的位置,以得到该网络的网络拓扑。
但是,通过该方式获取网络拓扑的效率较低。
发明内容
本申请提供了一种网络拓扑的确定方法及装置,可以提高获取网络拓扑的效率,本申请提供的技术方案如下:
第一方面,本申请示例性实施例提供了一种网络拓扑的确定方法,方法包括:获取用于组成网络的多个网元之间的连接关系和每个网元的网络层级,网络层级用于反映网元在网络中的重要程度;基于多个网元之间的连接关系和每个网元的网络层级,分别确定多个子网络;按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息;基于多个网元之间的连接关系和每个网元的位置信息,建立网络拓扑。
本申请提供了一种网络拓扑的确定方法,通过基于多个网元之间的连接关系和每个网元的网络层级,分别确定多个子网络,并按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息,并基于多个网元之间的连接关系和每个网元的位置信息,建立网络拓扑,相较于相关技术,能够自动地获取网元的位置信息,无需手动对网络拓扑进行调整,有效地提高了获取网络拓扑的效率。
当待确定位置信息的网元为核心网元时,按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息的实现过程,可以包括:对组成核心子网的多个核心网元进行排序,得到第一网元队列,核心网元为多个网元中具有最高网络层级的网元;获取第一网元队列中相邻的每两个核心网元之间的第一间距;基于第一间距和核心网元的总数,确定每个核心网元的位置信息。
可选地,多个核心网元布局在第一图形的边界上,基于第一间距和核心网元的总数,确 定每个核心网元的位置信息,包括:基于核心网元的总数,确定第一图形的第一定长参数,第一定长参数用于反映第一图形上的点满足的几何特征;按照每个核心网元在第一网元队列中的顺序,基于第一定长参数和第一间距,依次确定核心网元的位置信息。
示例地,该第一图形包括:圆形、椭圆形或正多边形。
其中,获取第一网元队列中相邻的每两个核心网元之间的第一间距,包括:基于两个核心网元之间的下挂网元的第一总数,确定第一间距。
在一种可实现方式中,第一间距由两个核心网元中每个核心网元与指定点的连线之间的第一夹角表征,基于两个核心网元之间的下挂网元的第一总数,确定第一间距,包括:确定第一总数在第二总数中的第一总数占比,第二总数为所有核心网元的下挂网元的总数;将第一总数占比与360度的乘积确定为第一夹角。
通过将核心网元布局在第一图形上,且根据两个核心网元之间的下挂网元的第一总数,确定该两个核心网元之间的第一间距,能够保证同一核心网元下的所有下挂网元之间不出现交叉。
当待确定位置信息的网元为次级网元时,按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息,包括:基于网元之间的连接关系,将次级子网络的多个次级网元划分至多个第一网元组,次级网元为多个网元中与核心网元直接连接的网元,核心网元为多个网元中具有最高网络层级的网元;对每个第一网元组中至少一个次级网元进行排序,得到第二网元队列;对多个第一网元组进行排序,得到网元组队列;基于每个第一网元组中所有次级网元的下挂网元的第三总数,确定每个第一网元组的布局宽度;基于每个第一网元组的布局宽度和任一第一网元组在网元组队列中的顺序,确定任一第一网元组的布局开始位置;基于布局宽度、布局开始位置、多个第一网元组的总组数、第二网元队列、网元组队列和每个第一网元组中的次级网元的总数,确定每个次级网元的位置信息。
可选地,多个次级网元布局在至少一个第二图形的边界上,基于布局宽度、布局开始位置、多个第一网元组的总组数、第二网元队列、网元组队列和每个第一网元组中的次级网元的总数,确定每个次级网元的位置信息,包括:基于每个次级网元所在的第一网元组在网元组队列中的顺序,确定每个次级网元所在的第二图形;基于次级网元的总数和第一网元组的总组数,确定每个第二图形的第二定长参数,第二定长参数用于反映对应的第二图形上的点满足的几何特征;按照每个次级网元在第二网元队列和网元组队列中的顺序,基于次级网元对应的第二定长参数、布局宽度,布局开始位置,及每个次级网元所在第一网元组中次级网元的总数,确定次级网元的位置信息。
可选地,为了保证网络之间的层次性,每个第二图形均位于核心网元对应的第一图形的外部;且当至少一个第二图形为一个第二图形时,第二图形包括:圆形、椭圆形或正多边形;当至少一个第二图形为多个第二图形时,多个第二图形构成的整体图形包括:同心圆形、同心椭圆形或同心正多边形。
在一种可实现方式中,对多个第一网元组进行排序,得到网元组队列,包括:按照每个第一网元组对应的第三总数由大到小的顺序,对多个第一网元组进行初始排序,得到初始网元组队列;按照每个第一网元组对应的目标距离由大到小的顺序,对初始网元组队列重新排序,得到网元组队列,目标距离为第一网元组在初始网元组队列中的位置到初始网元组队列 的中心位置的距离。
可选地,每个第一网元组的布局宽度由第一网元组中位于最外侧的两个次级网元与指定点的连线之间的第二夹角表征,基于每个第一网元组中所有次级网元的下挂网元的第三总数,确定每个第一网元组的布局宽度,包括:确定任一第一网元组对应的第三总数在第四总数中的第二总数占比,第四总数为多个第一网元组中所有次级网元的下挂网元的总数;基于任一第一网元组对应的第二总数占比,确定任一第一网元组的第二夹角。
可选地,每个第一网元组的布局开始位置由布局开始角度表征,布局开始角度为布局开始位置与指定点的连线相对于指定0度的偏移角度,基于每个第一网元组的布局宽度和任一第一网元组在网元组队列中的顺序,确定任一第一网元组的布局开始位置,包括:基于任一第一网元组在网元组队列中的顺序,及在网元组队列中位于任一第一网元组之前的其他第一网元组的布局宽度,获取任一第一网元组的布局开始角度。
通过将次级网元布局在第二图形上,且根据每个第一网元组中所有次级网元的下挂网元的第三总数,确定每个第一网元组的布局宽度,能够保证每个第一网元组的所有下挂网元之间不出现交叉。
当待确定位置信息的网元为环网元时,按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息,包括:将至少一个环型子网划分至至少一个第二网元组,环型子网中的网元呈环状连接,属于环型子网的网元为环网元;基于每个第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度;确定任一环型子网的环网元对应的第三图形的图形参数,组成任一环型子网的环网元布局在对应的第三图形的边界上,图形参数用于反映对应的第三图形上的点满足的几何特征;基于任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网中每个环网元的位置信息。
当网络中的网元按照网络层级由高到低的顺序自上向下分布时,基于任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网中每个环网元的位置信息,包括:基于任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,通过二分迭代算法获取任一环型子网中每个环网元在第一方向上的位置信息;基于对应的图形参数和任一环网元在第一方向上的位置信息,确定任一环网元在第二方向上的位置信息,第二方向与第一方向垂直。
可选地,在确定任一环型子网的环网元对应的第三图形的图形参数之前,方法还包括:基于任一第二网元组中每个环型子网的开始环网元和结束环网元的位置信息,对任一第二网元组中至少一个环型子网进行排序,得到第一网络队列。
相应的,确定任一环型子网的环网元对应的第三图形的图形参数,包括:基于任一第二网元组中环型子网的开始环网元和结束环网元的位置信息,确定任一第二网元组的第一重心的位置信息;基于任一第二网元组的第一重心的位置信息、任一环型子网的布局宽度、任一环型子网在第一网络队列中的顺序,及任一环型子网的环等级,确定与开始环网元直接连接的环网元和与结束环网元直接连接的环网元中的至少一个目标环网元的位置信息;基于任一环型子网对应的目标环网元的位置信息和对应的第三图形所满足的函数关系,确定图形参数。
当网络中的网元按照离心分层布局的方式进行布局时,基于任一环型子网中下挂网元的 第六总数,对应的图形参数,对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网中每个环网元的位置信息,包括:基于任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网对应的第三图形坐标系;基于任一环型子网对应的第六总数,及对应的第三图形坐标系和对应的图形参数,确定任一环型子网中每个环网元的位置信息。
其中,基于任一环型子网对应的第六总数,及对应的第三图形坐标系和对应的图形参数,确定任一环型子网中每个环网元的位置信息,包括:基于任一环型子网对应的布局宽度、对应的第六总数、对应的图形参数,及任一环型子网中开始环网元和结束环网元之间的距离,在任一环型子网所包括的多个环网元中,确定作为任一环型子网的顶点的目标环网元;基于任一环型子网对应的布局宽度,目标环网元在任一环型子网中多个环网元中的次序,任一环型子网中开始环网元和结束环网元之间的距离,任一环型子网对应的第三图形坐标系和对应的图形参数,确定每个环网元的位置信息。
可选地,基于任一环型子网对应的布局宽度、对应的第六总数、对应的图形参数,及任一环型子网中开始环网元和结束环网元之间的距离,在任一环型子网所包括的多个环网元中,确定作为任一环型子网的顶点的目标环网元,包括:基于任一环型子网对应的图形参数和对应的布局宽度,及任一环型子网中开始环网元和结束环网元之间的距离,确定任一环型子网对应的第三图形的第一弧长和第二弧长,第一弧长和第二弧长分别为位于第三图形的顶点两侧的弧的长度;基于任一环型子网对应的第一弧长和第二弧长,及任一环型子网对应的第六总数,确定作为任一环型子网的顶点的目标环网元。
在一种可实现方式中,基于任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网对应的第三图形坐标系,包括:将任一环型子网的开始环网元和结束环网元的中点确定为任一环型子网对应的第三图形坐标系的坐标原点;确定任一环型子网所在的第二网元组对应的参考图形,参考图形为以指定定长为半径,以对应的第三图形坐标系的坐标原点为圆心的圆;确定任一环型子网对应的目标交点,目标交点为任一环型子网所在的第二网元组对应的参考图形与任一环型子网的第三连线的交点,任一环型子网的顶点与指定点位于第三连线上;将对应的第三图形坐标系的坐标原点与目标交点的连线所在的方向确定为对应的第三图形坐标系的第二方向,将与第二方向垂直的方向确定为对应的第三图形坐标系的第一方向。
在另一种可实现方式中,基于任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网对应的第三图形坐标系,包括:基于任一环型子网对应的图形参数,确定任一环型子网对应的第三图形的几何中心在第三图形中的第一相对位置;基于任一环型子网对应的第一相对位置和对应的布局宽度,确定任一环型子网对应几何中心在任一环型子网所在的目标第二网元组中的第二相对位置;基于任一环型子网对应的第二相对位置和归属点的位置信息,确定任一环型子网对应的几何中心的位置信息,归属点为目标第二网元组中至少一个环型子网中共同存在的环网元;将任一环型子网对应的几何中心的位置信息确定为对应的第三图形坐标系的原点的位置信息,将任一环型子网对应的几何中心与对应的归属点的连线所在的方向确定为任一环型子网对应的第三图形坐标系的第一方向,将与第一方向垂直的方向确定为任一环型子网对应的第三图形坐标系的第二方向。
可选地,确定任一环型子网的环网元对应的第三图形的图形参数,包括:基于任一环型 子网对应的第六总数,估算任一环型子网对应的第三图形的第一周长;基于任一环型子网对应的第三图形的周长公式,确定第三图形的第二周长;基于第一周长和第二周长,获取任一环型子网对应的图形参数。
其中,基于第一周长和第二周长,获取任一环型子网对应的图形参数,包括:基于任一环型子网对应的第一周长和第二周长,获取任一环型子网对应的图形参数中的第一子参数;基于任一环型子网对应的第一子参数,任一环型子网对应的布局宽度,及任一环型子网中开始环网元和结束环网元之间的距离,确定任一环型子网对应的图形参数中的其他子参数,得到任一环型子网对应的图形参数。
当网络中的网元按照离心分层布局的方式进行布局时,将至少一个环型子网划分至至少一个第二网元组,包括:将具有相同开始环网元和相同结束环网元的环型子网划分至同一第二网元组,得到至少一个第二网元组。
当网络中的网元按照网络层级由高到低的顺序自上向下分布时,将至少一个环型子网划分至至少一个第二网元组,包括:将环等级相同的环型子网划分至同一第二网元组,得到至少一个第二网元组。
可选地,任一环型子网的布局宽度由任一环型子网的第三夹角表征,基于每个第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度,包括:将180度与任一第二网元组对应的第五总数的商,确定为任一第二网元组中每个环型子网所占的第三夹角。
其中,任一环型子网的布局宽度由任一环型子网的第三夹角表征,基于每个第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度,包括:确定第一连线和第二连线所成的第四夹角,第一连线为任一第二网元组中开始环网元与指定点的连线,第二连线为任一第二网元组中结束环网元与指定点的连线;
当网络中的网元按照离心分层布局的方式进行布局时,将第四夹角与目标总数的商确定为任一第二网元组中每相邻两个环型子网的第三连线之间的第三夹角,环型子网的顶点与指定点位于第三连线上,目标总数等于任一第二网元组对应的第五总数减一。
当网络中的网元按照网络层级由高到低的顺序自上向下分布时,任一环型子网的布局宽度由任一环型子网的第三夹角表征,基于每个第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度,包括:基于任一环型子网对应的第六总数,确定任一环型子网的布局宽度。
当待确定位置信息的网元为树网元时,按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息,包括:在组成树型子网的多个树网元中,确定第一根网元,树型子网中的网元呈树状连接,属于树型子网的网元为树网元;获取每个树网元的布局开始位置和布局宽度;基于任一其他树网元的布局开始位置和布局宽度,及第一根网元的位置信息,确定任一其他树网元的位置信息,其他树网元为多个树网元中除第一根网元外的树网元。
其中,在基于任一其他树网元的布局开始位置和布局宽度,及第一根网元的位置信息,确定任一其他树网元的位置信息之前,方法还包括:获取每个其他网元的深度。
相应的,基于任一其他树网元的布局开始位置和布局宽度,及第一根网元的位置信息,确定任一其他树网元的位置信息,包括:基于任一其他树网元深度、布局开始位置和布局宽度,及第一根网元的位置信息,确定任一其他树网元的位置信息。
可选地,每个树网元的布局开始位置由布局开始角度表征,获取每个树网元的布局开始位置,包括:基于第一根网元的位置信息,将第一根网元和指定点所在的直线确定为目标直线;将目标射线与指定直线的夹角确定为第一根网元的布局开始角度,目标射线为垂直于目标直线,且发射方向背离指定点的射线;或者,第一根网元的布局开始角度为-180度。
其中,每个树网元的布局开始位置由布局开始角度表征,获取每个树网元的布局开始位置,包括:根据树网元之间的连接关系,对与同一父网元连接的多个子网元进行排序,得到第三网元队列;基于任一其他树网元所连接的父网元的布局开始角度、布局宽度和宽度,及在第三网元队列中顺序位于任一其他树网元之前的其他树网元的宽度,确定任一其他树网元的布局开始角度。
在一种可实现方式中,每个树网元的布局宽度由第五夹角表征,获取每个树网元的布局宽度,包括:第一根网元的第五夹角为180度;和/或,根据树网元之间的连接关系,基于任一其他树网元的宽度,任一其他树网元所连接的父网元的第五夹角和宽度,确定任一其他树网元的第五夹角。
可选地,按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息,还包括:对所有孤立树型子网中的第二根网元进行排序,得到第四网元队列,孤立树型子网中的网元呈树状连接,属于孤立树型子网的网元为孤立树网元,孤立树网元与核心网元之间不存在连接路径,核心网元为多个网元中具有最高网络层级的网元;基于指定半径、所有第二根网元的宽度之和,及在第四网元队列中顺序位于任一第二根网元之前的其他第二根网元的宽度之和,确定任一第二根网元的位置信息。
在一种可实现方式中,每个树网元的布局开始位置由布局开始角度表征,获取每个树网元的布局开始位置,包括:基于在第四网元队列中顺序位于任一第二根网元之前的其他第二根网元的宽度,确定第二根网元的布局开始位置。
在另一种可实现方式中,每个树网元的布局宽度由第五夹角表征,获取每个树网元的布局宽度,包括:根据树网元之间的连接关系,获取每个树网元的宽度;基于每个树网元的宽度,确定每个树网元的布局宽度。
可选地,与同一第一根网元连接的多个其他树网元布局在以第一根网元为圆心,以指定长度为半径的圆上。
通过将树网元布局在弧线树上,能够根据树网元的宽度分配树网元的布局宽度的大小,进而保证同一根网元下的所有树网元之间不出现交叉。
当待确定位置信息的网元为树网元,且树网元的深度大于指定深度阈值时,按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息,包括:获取多个树型子网组成的整体网络的第二重心的位置信息;获取每个树型子网的宽度;按照每个树型子网的第三根网元的位置信息,对多个树型子网进行排序,得到第二网络队列;基于每个树型子网的宽度,第二重心的位置信息,及在第二网络队列中顺序位于任一树型子网之前的其他树型子网的宽度,确定任一树型子网的第三根网元的位置信息;根据树网元之间的连接关系,对与同一父网元连接的多个子网元进行排序,得到第五网元队列;基于任一其他树网元所连接的父网元的位置信息,任一其他树网元的宽度,及在第五网元队列中顺序位于任一其他树网元之前的其他树网元的位置信息和宽度,确定任一其他树网元的位置信息。
其中,基于多个网元之间的连接关系和每个网元的网络层级,分别确定多个子网络,包括:将由核心网元连接组成的网络确定为核心子网络,核心网元为具有最高网络层级的网元。
可选地,基于多个网元之间的连接关系和每个网元的网络层级,分别确定多个子网络,还包括:将呈环状连接的其他网元组成的网络确定为环型子网络,其他网元为网络中除核心网元外的网元;和/或,将呈树型连接的其他网元组成的网络确定为树型子网。
在一种可实现方式中,网络拓扑中的网元以具有最高网络层级的网元为起点,按照网络层级由高到低的顺序由内向外分布。此时,获得的网络拓扑中多个网元的分布位置更均匀,能够使网络拓扑的布局更美观,且根据该网元拓扑进行网络建设时,能够减小网元之间的干扰。
在另一种可实现方式中,网络拓扑中的网元以具有最高网络层级的网元为起点,按照网络层级由高到低的顺序自上向下分布。此时,获得的网络拓扑中网元的拓扑层次更清晰,能够较清楚地呈现网络的结构、网元的网络层级及不同子网之间的关系。
第二方面,本申请示例性实施例提供了一种网络拓扑的确定装置,装置包括:获取模块,用于获取用于组成网络的多个网元之间的连接关系和每个网元的网络层级,网络层级用于反映网元在网络中的重要程度;第一确定模块,用于基于多个网元之间的连接关系和每个网元的网络层级,分别确定多个子网络;第二确定模块,用于按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息;建立模块,用于基于多个网元之间的连接关系和每个网元的位置信息,建立网络拓扑。
可选地,第二确定模块,用于:对组成核心子网的多个核心网元进行排序,得到第一网元队列,核心网元为多个网元中具有最高网络层级的网元;获取第一网元队列中相邻的每两个核心网元之间的第一间距;基于第一间距和核心网元的总数,确定每个核心网元的位置信息。
可选地,多个核心网元布局在第一图形的边界上,第二确定模块用于基于第一间距和核心网元的总数,确定每个核心网元的位置信息时,具体用于:基于核心网元的总数,确定第一图形的第一定长参数,第一定长参数用于反映第一图形上的点满足的几何特征;按照每个核心网元在第一网元队列中的顺序,基于第一定长参数和第一间距,依次确定核心网元的位置信息。
可选地,第一图形包括:圆形、椭圆形或正多边形。
可选地,第二确定模块用于获取第一网元队列中相邻的每两个核心网元之间的第一间距时,具体用于:基于两个核心网元之间的下挂网元的第一总数,确定第一间距。
可选地,第一间距由两个核心网元中每个核心网元与指定点的连线之间的第一夹角表征,第二确定模块用于基于两个核心网元之间的下挂网元的第一总数,确定第一间距时,具体用于:确定第一总数在第二总数中的第一总数占比,第二总数为所有核心网元的下挂网元的总数;将第一总数占比与360度的乘积确定为第一夹角。
可选地,第二确定模块,用于:基于网元之间的连接关系,将次级子网络的多个次级网元划分至多个第一网元组,次级网元为多个网元中与核心网元直接连接的网元,核心网元为多个网元中具有最高网络层级的网元;对每个第一网元组中至少一个次级网元进行排序,得到第二网元队列;对多个第一网元组进行排序,得到网元组队列;基于每个第一网元组中所 有次级网元的下挂网元的第三总数,确定每个第一网元组的布局宽度;基于每个第一网元组的布局宽度和任一第一网元组在网元组队列中的顺序,确定任一第一网元组的布局开始位置;基于布局宽度、布局开始位置、多个第一网元组的总组数、第二网元队列、网元组队列和每个第一网元组中的次级网元的总数,确定每个次级网元的位置信息。
可选地,多个次级网元布局在至少一个第二图形的边界上,第二确定模块用于基于布局宽度、布局开始位置、多个第一网元组的总组数、第二网元队列、网元组队列和每个第一网元组中的次级网元的总数,确定每个次级网元的位置信息时,具体用于:基于每个次级网元所在的第一网元组在网元组队列中的顺序,确定每个次级网元所在的第二图形;基于次级网元的总数和第一网元组的总组数,确定每个第二图形的第二定长参数,第二定长参数用于反映对应的第二图形上的点满足的几何特征;按照每个次级网元在第二网元队列和网元组队列中的顺序,基于次级网元对应的第二定长参数、布局宽度,布局开始位置,及每个次级网元所在第一网元组中次级网元的总数,确定次级网元的位置信息。
可选地,每个第二图形均位于核心网元对应的第一图形的外部;当至少一个第二图形为一个第二图形时,第二图形包括:圆形、椭圆形或正多边形;当至少一个第二图形为多个第二图形时,多个第二图形构成的整体图形包括:同心圆形、同心椭圆形或同心正多边形。
可选地,第二确定模块用于对多个第一网元组进行排序,得到网元组队列时,具体用于:按照每个第一网元组对应的第三总数由大到小的顺序,对多个第一网元组进行初始排序,得到初始网元组队列;按照每个第一网元组对应的目标距离由大到小的顺序,对初始网元组队列重新排序,得到网元组队列,目标距离为第一网元组在初始网元组队列中的位置到初始网元组队列的中心位置的距离。
可选地,每个第一网元组的布局宽度由第一网元组中位于最外侧的两个次级网元与指定点的连线之间的第二夹角表征,第二确定模块用于基于每个第一网元组中所有次级网元的下挂网元的第三总数,确定每个第一网元组的布局宽度时,具体用于:确定任一第一网元组对应的第三总数在第四总数中的第二总数占比,第四总数为多个第一网元组中所有次级网元的下挂网元的总数;基于任一第一网元组对应的第二总数占比,确定任一第一网元组的第二夹角。
可选地,每个第一网元组的布局开始位置由布局开始角度表征,布局开始角度为布局开始位置与指定点的连线相对于指定0度的偏移角度,第二确定模块用于基于每个第一网元组的布局宽度和任一第一网元组在网元组队列中的顺序,确定任一第一网元组的布局开始位置时,具体用于:基于任一第一网元组在网元组队列中的顺序,及在网元组队列中位于任一第一网元组之前的其他第一网元组的布局宽度,获取任一第一网元组的布局开始角度。
可选地,第二确定模块,用于:将至少一个环型子网划分至至少一个第二网元组,环型子网中的网元呈环状连接,属于环型子网的网元为环网元;基于每个第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度;确定任一环型子网的环网元对应的第三图形的图形参数,组成任一环型子网的环网元布局在对应的第三图形的边界上,图形参数用于反映对应的第三图形上的点满足的几何特征;基于任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网中每个环网元的位置信息。
可选地,第二确定模块用于基于任一环型子网中下挂网元的第六总数,对应的图形参数, 对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网中每个环网元的位置信息时,具体用于:基于任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,通过二分迭代算法获取任一环型子网中每个环网元在第一方向上的位置信息;基于对应的图形参数和任一环网元在第一方向上的位置信息,确定任一环网元在第二方向上的位置信息,第二方向与第一方向垂直。
可选地,第二确定模块还用于:基于任一第二网元组中每个环型子网的开始环网元和结束环网元的位置信息,对任一第二网元组中至少一个环型子网进行排序,得到第一网络队列。
相应的,第二确定模块用于确定任一环型子网的环网元对应的第三图形的图形参数时,具体用于:基于任一第二网元组中环型子网的开始环网元和结束环网元的位置信息,确定任一第二网元组的第一重心的位置信息;基于任一第二网元组的第一重心的位置信息、任一环型子网的布局宽度、任一环型子网在第一网络队列中的顺序,及任一环型子网的环等级,确定与开始环网元直接连接的环网元和与结束环网元直接连接的环网元中的至少一个目标环网元的位置信息;基于任一环型子网对应的目标环网元的位置信息和对应的第三图形所满足的函数关系,确定图形参数。
可选地,第二确定模块用于基于任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网中每个环网元的位置信息时,具体用于:基于任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网对应的第三图形坐标系;基于任一环型子网对应的第六总数,及对应的第三图形坐标系和对应的图形参数,确定任一环型子网中每个环网元的位置信息。
可选地,第二确定模块用于基于任一环型子网对应的第六总数,及对应的第三图形坐标系和对应的图形参数,确定任一环型子网中每个环网元的位置信息时,具体用于:基于任一环型子网对应的布局宽度、对应的第六总数、对应的图形参数,及任一环型子网中开始环网元和结束环网元之间的距离,在任一环型子网所包括的多个环网元中,确定作为任一环型子网的顶点的目标环网元;基于任一环型子网对应的布局宽度,目标环网元在任一环型子网中多个环网元中的次序,任一环型子网中开始环网元和结束环网元之间的距离,任一环型子网对应的第三图形坐标系和对应的图形参数,确定每个环网元的位置信息。
可选地,第二确定模块用于基于任一环型子网对应的布局宽度、对应的第六总数、对应的图形参数,及任一环型子网中开始环网元和结束环网元之间的距离,在任一环型子网所包括的多个环网元中,确定作为任一环型子网的顶点的目标环网元时,具体用于:基于任一环型子网对应的图形参数和对应的布局宽度,及任一环型子网中开始环网元和结束环网元之间的距离,确定任一环型子网对应的第三图形的第一弧长和第二弧长,第一弧长和第二弧长分别为位于第三图形的顶点两侧的弧的长度;基于任一环型子网对应的第一弧长和第二弧长,及任一环型子网对应的第六总数,确定作为任一环型子网的顶点的目标环网元。
可选地,第二确定模块用于基于任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网对应的第三图形坐标系时,具体用于:将任一环型子网的开始环网元和结束环网元的中点确定为任一环型子网对应的第三图形坐标系的坐标原点;确定任一环型子网所在的第二网元组对应的参考图形,参考图形为以指定定长为半径,以对应的第三图形坐标系的坐标原点为圆心的圆;确定任一环型子网对应的目标交点,目标交点为任一环型子网所 在的第二网元组对应的参考图形与任一环型子网的第三连线的交点,任一环型子网的顶点与指定点位于第三连线上;将对应的第三图形坐标系的坐标原点与目标交点的连线所在的方向确定为对应的第三图形坐标系的第二方向,将与第二方向垂直的方向确定为对应的第三图形坐标系的第一方向。
可选地,第二确定模块用于基于任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网对应的第三图形坐标系时,具体用于:基于任一环型子网对应的图形参数,确定任一环型子网对应的第三图形的几何中心在第三图形中的第一相对位置;基于任一环型子网对应的第一相对位置和对应的布局宽度,确定任一环型子网对应几何中心在任一环型子网所在的目标第二网元组中的第二相对位置;基于任一环型子网对应的第二相对位置和归属点的位置信息,确定任一环型子网对应的几何中心的位置信息,归属点为目标第二网元组中至少一个环型子网中共同存在的环网元;将任一环型子网对应的几何中心的位置信息确定为对应的第三图形坐标系的原点的位置信息,将任一环型子网对应的几何中心与对应的归属点的连线所在的方向确定为任一环型子网对应的第三图形坐标系的第一方向,将与第一方向垂直的方向确定为任一环型子网对应的第三图形坐标系的第二方向。
可选地,第二确定模块用于确定任一环型子网的环网元对应的第三图形的图形参数时,具体用于:基于任一环型子网对应的第六总数,估算任一环型子网对应的第三图形的第一周长;基于任一环型子网对应的第三图形的周长公式,确定第三图形的第二周长;基于第一周长和第二周长,获取任一环型子网对应的图形参数。
可选地,第二确定模块用于基于第一周长和第二周长,获取任一环型子网对应的图形参数时,具体用于:基于任一环型子网对应的第一周长和第二周长,获取任一环型子网对应的图形参数中的第一子参数;基于任一环型子网对应的第一子参数,任一环型子网对应的布局宽度,及任一环型子网中开始环网元和结束环网元之间的距离,确定任一环型子网对应的图形参数中的其他子参数,得到任一环型子网对应的图形参数。
可选地,第二确定模块用于将至少一个环型子网划分至至少一个第二网元组时,具体用于:将具有相同开始环网元和相同结束环网元的环型子网划分至同一第二网元组,得到至少一个第二网元组。
可选地,第二确定模块用于将至少一个环型子网划分至至少一个第二网元组时,具体用于:将环等级相同的环型子网划分至同一第二网元组,得到至少一个第二网元组。
可选地,任一环型子网的布局宽度由任一环型子网的第三夹角表征,第二确定模块用于基于每个第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度时,具体用于:将180度与任一第二网元组对应的第五总数的商,确定为任一第二网元组中每个环型子网所占的第三夹角。
可选地,任一环型子网的布局宽度由任一环型子网的第三夹角表征,第二确定模块用于基于每个第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度时,具体用于:确定第一连线和第二连线所成的第四夹角,第一连线为任一第二网元组中开始环网元与指定点的连线,第二连线为任一第二网元组中结束环网元与指定点的连线;将第四夹角与目标总数的商确定为任一第二网元组中每相邻两个环型子网的第三连线之间的第三夹角,环型子网的顶点与指定点位于第三连线上,目标总数等于任一第二网元组对应的第五总数减一。
可选地,任一环型子网的布局宽度由任一环型子网的第三夹角表征,第二确定模块用于 基于每个第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度时,具体用于:基于任一环型子网对应的第六总数,确定任一环型子网的布局宽度。
可选地,第二确定模块,用于:在组成树型子网的多个树网元中,确定第一根网元,树型子网中的网元呈树状连接,属于树型子网的网元为树网元;获取每个树网元的布局开始位置和布局宽度;基于任一其他树网元的布局开始位置和布局宽度,及第一根网元的位置信息,确定任一其他树网元的位置信息,其他树网元为多个树网元中除第一根网元外的树网元。
可选地,第二确定模块还用于:获取每个其他网元的深度。
相应的,第二确定模块用于基于任一其他树网元的布局开始位置和布局宽度,及第一根网元的位置信息,确定任一其他树网元的位置信息时,具体用于:基于任一其他树网元深度、布局开始位置和布局宽度,及第一根网元的位置信息,确定任一其他树网元的位置信息。
可选地,每个树网元的布局开始位置由布局开始角度表征,第二确定模块用于获取每个树网元的布局开始位置时,具体用于:基于第一根网元的位置信息,将第一根网元和指定点所在的直线确定为目标直线;将目标射线与指定直线的夹角确定为第一根网元的布局开始角度,目标射线为垂直于目标直线,且发射方向背离指定点的射线;或者,第一根网元的布局开始角度为-180度。
可选地,每个树网元的布局开始位置由布局开始角度表征,第二确定模块用于获取每个树网元的布局开始位置时,具体用于:根据树网元之间的连接关系,对与同一父网元连接的多个子网元进行排序,得到第三网元队列;基于任一其他树网元所连接的父网元的布局开始角度、布局宽度和宽度,及在第三网元队列中顺序位于任一其他树网元之前的其他树网元的宽度,确定任一其他树网元的布局开始角度。
可选地,每个树网元的布局宽度由第五夹角表征,第二确定模块用于获取每个树网元的布局宽度时,具体用于:第一根网元的第五夹角为180度;和/或,根据树网元之间的连接关系,基于任一其他树网元的宽度,任一其他树网元所连接的父网元的第五夹角和宽度,确定任一其他树网元的第五夹角。
可选地,第二确定模块,还用于:对所有孤立树型子网中的第二根网元进行排序,得到第四网元队列,孤立树型子网中的网元呈树状连接,属于孤立树型子网的网元为孤立树网元,孤立树网元与核心网元之间不存在连接路径,核心网元为多个网元中具有最高网络层级的网元;基于指定半径、所有第二根网元的宽度之和,及在第四网元队列中顺序位于任一第二根网元之前的其他第二根网元的宽度之和,确定任一第二根网元的位置信息。
可选地,每个树网元的布局开始位置由布局开始角度表征,第二确定模块用于获取每个树网元的布局开始位置时,具体用于:基于在第四网元队列中顺序位于任一第二根网元之前的其他第二根网元的宽度,确定第二根网元的布局开始位置。
可选地,每个树网元的布局宽度由第五夹角表征,第二确定模块获取每个树网元的布局宽度时,具体用于:根据树网元之间的连接关系,获取每个树网元的宽度;基于每个树网元的宽度,确定每个树网元的布局宽度。
可选地,与同一第一根网元连接的多个其他树网元布局在以第一根网元为圆心,以指定长度为半径的圆上。
可选地,第二确定模块,用于:获取多个树型子网组成的整体网络的第二重心的位置信息;获取每个树型子网的宽度;按照每个树型子网的第三根网元的位置信息,对多个树型子 网进行排序,得到第二网络队列;基于每个树型子网的宽度,第二重心的位置信息,及在第二网络队列中顺序位于任一树型子网之前的其他树型子网的宽度,确定任一树型子网的第三根网元的位置信息;根据树网元之间的连接关系,对与同一父网元连接的多个子网元进行排序,得到第五网元队列;基于任一其他树网元所连接的父网元的位置信息,任一其他树网元的宽度,及在第五网元队列中顺序位于任一其他树网元之前的其他树网元的位置信息和宽度,确定任一其他树网元的位置信息。
可选地,第一确定模块,用于:将由核心网元连接组成的网络确定为核心子网络,核心网元为具有最高网络层级的网元。
可选地,第一确定模块,用于:将呈环状连接的其他网元组成的网络确定为环型子网络,其他网元为网络中除核心网元外的网元;和/或,将呈树型连接的其他网元组成的网络确定为树型子网。
可选地,网络拓扑中的网元以具有最高网络层级的网元为起点,按照网络层级由高到低的顺序由内向外分布。
可选地,网络拓扑中的网元以具有最高网络层级的网元为起点,按照网络层级由高到低的顺序自上向下分布。
第三方面,本申请示例性实施例提供了一种网络拓扑的确定装置,包括处理器和存储器。在处理器执行存储器存储的计算机程序时,网络拓扑的确定装置执行第一方面任一的网络拓扑的确定方法。
第四方面,本申请示例性实施例提供了一种存储介质,存储介质内存储有计算机程序,计算机程序指示文件传输检测装置执行第一方面任一的网络拓扑的确定方法。
本申请示例性实施例提供的技术方案带来的有益效果是:
本申请实施例提供的网络拓扑的确定方法及装置,通过基于多个网元之间的连接关系和每个网元的网络层级,分别确定多个子网络,按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息,并基于多个网元之间的连接关系和每个网元的位置信息,建立网络拓扑,相较于相关技术,能够自动地获取网元的位置信息,无需手动对网络拓扑进行调整,有效地提高了获取网络拓扑的效率。还能够有效地减少网络拓扑中的链路交叉,且无需预置网元的初始位置,使得获取的网络拓扑的结果唯一,且获取的网络拓扑能够较清楚地呈现网络的结构、网元的网络层级及不同子网之间的关系。并且,由于在确定网元的位置信息时,采用的图形均为具有较好对称性的图形,使得获取的网络拓扑具有较好的对称性。同时,在该计算网元的位置信息的过程中,通过采用定积分、二分迭代、图形参数求解以及坐标变换等方式简化计算量,能够减少确定网元位置信息的耗时,解决了相关中算法不收敛和效率低的问题。
图1是本申请示例性实施例提供的一种环型子网的结构示意图;
图2是本申请实施例提供的一种网络拓扑的确定方法的流程图;
图3是本申请实施例提供的一种树型子网的结构示意图;
图4是本申请实施例提供的一种离心分层布局的示意图;
图5是本申请实施例提供的一种执行步骤204的流程顺序的示意图;
图6是本申请实施例提供的一种按照网络层级由高到低的顺序自上向下分布的示意图;
图7是本申请实施例提供的另一种执行步骤204的流程顺序的示意图;
图8是本申请实施例提供的一种确定核心网元的位置信息的方法流程图;
图9是本申请实施例提供的一种弧线模型的示意图;
图10是本申请实施例提供的一种核心网元布局在圆形上的示意图;
图11是本申请实施例提供的一种确定次级网元的位置信息的方法流程图;
图12是本申请实施例提供的一种当多个次级网元布局在至少一个第二图形的边界上时,确定次级网元的位置信息的方法流程图;
图13是本申请实施例提供的一种双层圆形的示意图;
图14是本申请实施例提供的一种确定环网元的位置信息的方法流程图;
图15是本申请实施例提供的一种第三夹角的示意图;
图16是本申请实施例提供的一种五个环型子网分布在双抛物线的边界上的示意图;
图17是本申请实施例提供的一种多个环型子网的环网元分别布局在多个椭圆形的边界上的示意图;
图18是本申请实施例提供的一种确定任一环型子网的环网元对应的第三图形的图形参数的方法流程图;
图19是本申请实施例提供的一种多个环型子网的环网元分别布局在多个双抛物线的边界上的示意图;
图20是本申请实施例提供的另一种确定任一环型子网的环网元对应的第三图形的图形参数的方法流程图;
图21是本申请实施例提供的一种图16的局部示意图;
图22是本申请实施例提供的一种多个环型子网的环网元分别布局在多个单抛物线的边界上的示意图;
图23是本申请实施例提供的又一种确定任一环型子网的环网元对应的第三图形的图形参数的方法流程图;
图24是本申请实施例提供的一种确定任一环型子网中每个环网元的位置信息的方法流程图;
图25是本申请实施例提供的一种确定任一环型子网对应的第三图形坐标系的方法流程图;
图26是本申请实施例提供的另一种确定任一环型子网对应的第三图形坐标系的方法流程图;
图27是本申请实施例提供的另一种确定任一环型子网中每个环网元的位置信息的方法流程图;
图28是本申请实施例提供的一种确定作为任一环型子网的顶点的目标环网元的方法流程图;
图29是本申请实施例提供的又一种确定任一环型子网中每个环网元的位置信息的方法流程图;
图30是本申请示例性实施例提供的一种对网元进行分簇的示意图;
图31是本申请示例性实施例提供的一种确定树网元的位置信息的流程图;
图32是本申请示例性实施例提供的一种树型子网中的树网元布局在弧线树模型上的示意图;
图33是本申请示例性实施例提供的一种获取第一根网元的布局开始角度的原理示意图;
图34是本申请示例性实施例提供的一种树型子网中树网元宽度的示意图;
图35是本申请示例性实施例提供的另一种确定树网元的位置信息的流程图;
图36是本申请示例性实施例提供的一种孤立网元布局在非孤立网元所在的圆形区域的外部的示意图;
图37是本申请示例性实施例提供的又一种确定树网元的位置信息的流程图;
图38是本申请示例性实施例提供的一种直线树模型的结构示意图;
图39是本申请示例性实施例提供的一种网络拓扑的示意图;
图40是本申请示例性实施例提供的另一种网络拓扑的示意图;
图41是本申请示例性实施例提供的一种网络拓扑的确定装置的结构示意图;
图42是本申请示例性实施例提供的一种网络拓扑的确定装置的结构框图。
为使本申请的目的、技术方案和优点更加清楚,下面将结合附图对本申请实施方式作进一步地详细描述。
为便于了解本申请实施例提供的网络拓扑的确定方法,下面先对本文中涉及的名词进行解释:
网络层级:在网络中通常根据网元在整个拓扑中的重要性进行分级,网络层级用于反映网元在网络中的重要程度,即网元的网络层级越高,该网元在网络中越重要。
环型子网(也称为环):网络中从一个开始环网元通过链路经过一个或多个网元到达结束环网元所形成的环状网络。其中,该环型子网中的网元为环网元,位于该环状网络两个端点的环网元一个为该环状网络的开始环网元,另一个为该环状网络的结束环网元。该环型子网中除开始环网元和结束环网元外的网元为环下挂网元。且开始环网元和结束环网元均可以称为对应环型子网的归属点。且当环型子网为单归属环时,由于该环型子网的开始环网元和结束环网元为同一个,该单归属环的归属点为同一个。
单归属环型子网(也称为单归属环)为开始环网元和结束环网元是同一个网元的环型子网。双归属环型子网(也称为双归属环型子网)为开始环网元和结束环网元不是同一个网元的环型子网。同层环型子网(也称为同层环)为开始环网元和结束环网元的网络层级相同的环型子网。跨层环型子网(也称为跨层环)为开始环网元和结束环网元的网络层级不相同的环型子网。
树型子网:呈树状连接的网元组成的网络。属于该树型子网的网元为树网元。
核心网元:网络包括的多个网元中具有最高网络层级的网元。
次级网元:网络包括的多个网元中与核心网元直接连接的下级网元。
孤立网元(在本文中也称孤立树网元):与核心网元之间不存在连通路径的网元。
跨环链路:位于链路两端的网元中,一个网元属于环网元,一个不属于环网元的链路。
簇:在按照次级网元之间的连通性对次级网元进行分组后,再按照每个其余网元到次级网元的路径远近,将每个其余网元划分到最近路径对应的次级网元所在的组,该每个组中包括的网元和链路组成的集合称为簇。该其余网元为网络层级低于次级网元的网元。
跨簇链路:位于链路两端的网元分别属于不同的簇的链路。
任一网元的下挂网元:连接在该任一网元下的网元。
环等级:环型子网的等级等于环型子网的开始环网元的网络层级和结束环网元的网络层级中的最大值加1。示例地,图1示出了四个环型子网,分别是:包括环网元a1、环网元a4和环网元a2的环型子网1,包括环网元a2、环网元a5、环网元a6和环网元a3的环型子网2,包括环网元a4、环网元a7和环网元a5的环型子网3,包括环网元a7、环网元a8和环网元a6的环型子网4。其中,环网元a1、环网元a2和环网元a3的网络层级均为1,环网元a4、环网元a5和环网元a6的网络层级均为2,环网元a7的网络层级为3,则可以确定环型子网1和2的环等级为1,环型子网3的环等级为2,环型子网4的环等级为3。
相关技术中,通常根据力导向布局算法获取网络的网络拓扑。其实现过程包括:在获取网络中各个网元的连接方式后,可以先根据该连接方式,通过胡克定律建立整个网络的能量模型,然后通过迭代方式对网元进行移动,并在网元使能量模型的能量取得最小值时,将该最小值对应的位置确定为该网元的位置,以得到该网络的网络拓扑。
但是,在根据能量对网元进行移动的过程中,容易造成网元出现震动,导致算法不收敛且获取网络拓扑的过程耗时较长。且由于是通过迭代方式确定网元的位置,在获取该网络拓扑时,需要通过指定迭代次数来终止迭代过程。同时,由于在建立能量模型时,需要指定网元的初始位置,导致获取的拓扑结构具有不确定性,且该拓扑结构的获取过程会受到该初始位置的影响,例如,当指定的初始位置比较差时,获取的网络拓扑的布局结果较差,较难获得令人满意的结果。并且,由于该网络拓扑为纯粹的能量布局,导致网络拓扑中的交叉多且结构混乱,无法清晰且完整地呈现出网络的结构、层次和不同子网之间的关系,需要大量手动调整,导致该获取网络拓扑的效率较低。
为此,本申请提供了一种网络拓扑的确定方法,该方法通过基于多个网元之间的连接关系和每个网元的网络层级,分别确定多个子网络,按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息,并基于多个网元之间的连接关系和每个网元的位置信息,建立网络拓扑,相较于相关技术,能够自动地获取网元的位置信息,无需手动对网络拓扑进行调整,有效地提高了获取网络拓扑的效率。并且,能够有效地减少网络拓扑中的链路交叉,且无需预置网元的初始位置,使得获取的网络拓扑的结果唯一,且获取的网络拓扑能够较清楚地呈现网络的结构、网元的网络层级及不同子网之间的关系。
图2为本申请实施例提供的一种网络拓扑的确定方法的流程图,如图2所示,该方法可以包括:
步骤201、获取用于组成网络的多个网元之间的连接关系和每个网元的网络层级。
其中,网络层级用于反映网元在网络中的重要程度。
网元之间的连接关系和每个网元的网络层级通常是根据网络的部署需求确定的,且网络 拓扑是根据该连接关系和每个网元的网络层级获得的,因此,在确定网络拓扑时,需要先获取该连接关系和每个网元的网络层级。
步骤202、确定网络拓扑中的核心网元,并根据各个网元与核心网元的连通性,对网络进行网络分割。
在对网络进行分割时,可以将与核心网元之间存在连接链路的网元确定为非孤立网元,该非孤立网元通常包括次级网元、环网元和树网元中的至少一个。由非孤立网元组成的子网络为非孤立子网。可以将网络中与核心网元之间不存在连接链路的网元确定为孤立网元,由孤立网元组成的子网络为孤立子网。
步骤203、基于多个网元之间的连接关系和每个网元的网络层级,分别确定多个子网络。
网络拓扑通常包括:核心网元及其他网元。该其他网元可以包括次级网元、环网元、树网元和孤立网元中的至少一种。相应的,该步骤203的实现过程可以包括:将由核心网元连接组成的网络确定为核心子网络。以及,该步骤203的实现过程还可以包括:将呈环状连接的其他网元组成的网络确定为环型子网络,其他网元为网络中除核心网元外的网元。和/或,将呈树型连接的其他网元组成的网络确定为树型子网。且在本申请实施例中,由于孤立子网中的网元按照树型连接进行布局,因此,该孤立子网也可称为孤立树型子网,该孤立树型子网中的网元可称为孤立树网元。
并且,在确定树型子网后,该步骤203的实现过程还可以包括:获取树型子网中每个网元的深度,并根据该树型子网中每个网元的深度,将该树型子网划分为短树子网和长树子网,以便分别根据不同的布局模型对长树子网和短树子网进行布局,达到减小树型子网中的交叉的目的。树型子网中每个网元的深度等于网元到达该树型子网的根网元的最短路径中包括的网元的总数。
可选地,该划分长树和短树的实现方式可以包括:在树型子网中,将网元深度大于指定深度阈值的网元确定为长树子网中的长树网元,将网元深度小于或等于指定深度阈值的网元确定为短树子网中的短树网元,并将该长树网元组成的子网络确定为长树子网,将短树网元组成的子网络确定为短树子网。
示例地,假设指定深度阈值为2,某树型子网的结构示意图如图3所示,在该树型子网中,第一根网元为树网元b1,其深度为1,该树网元b1的子网元b2、子网元b3、子网元b4和子网元b5的深度均为2,树网元b2的子网元b6、树网元b3的子网元b7和b8、及树网元b5的子网元b9和b10的深度均为3,树网元b7的子网元b11和b12、树网元b9的子网元b13和b14、及树网元b10的子网元b15和b16的深度均为4,树网元b14的子网元b17的深度均为5,对该树型子网按照指定深度阈值进行长短树分割后,分割得到的长树1包括:树网元b5、树网元b9、树网元b10、树网元b13、树网元b14、树网元b15、树网元b16和树网元b17,分割得到的长树2包括:树网元b3、树网元b7、树网元b8、树网元b11和树网元b12,短树包括:树网元b1、树网元b2、树网元b4和树网元b6。
步骤204、按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息。
可选地,网络拓扑中的网元的布局方式至少可以包括以下两种:
第一种布局方式:网络拓扑中的网元可以以具有最高网络层级的网元为起点,按照网络层级由高到低的顺序由内向外分布,此时,获取的网络拓扑可称为网状拓扑。也即是,该网 络拓扑中的网元可以按照离心分层布局的方式进行布局。当网络拓扑中的网元按照离心分层布局时,获得的网络拓扑中多个网元的分布位置更均匀,能够使网络拓扑的布局更美观,且根据该网元拓扑进行网络建设时,能够减小网元之间的干扰。
并且,在该第一种布局方式中,核心网元可以布局在第一图形的边界上。该第一图形可以为:几何中心位于指定点的圆形、椭圆形或正多边形等闭合图形。次级网元可以布局在至少一个第二图形的边界上。当至少一个第二图形为一个第二图形时,该第二图形可以包括:几何中心位于指定点的圆形、椭圆形或正多边形。当该至少一个第二图形为多个第二图形时,该多个第二图形构成的整体图形可以包括:几何中心位于指定点的同心圆形、同心椭圆形或同心正多边形。且该第二图形位于第一图形的外部。环型子网的环网元可以布局在第三图形的边界上。该第三图形可以包括:椭圆形或双抛物线等图形。
示例地,图4为该离心分层布局的一种示意图,图4中的黑点为网元,图4中两个网元之间的实线表示该两个网元之间存在连接关系,且距离图4所示的网络拓扑的几何中心越近的网元的网络层级越高,因此,可以看出该图4中的网元是以具有最高网络层级的核心网元为起点,按照网络层级由高到低的顺序由内向外发散地分布的。
当网络拓扑按照该第一种布局方式进行布局时,在执行该步骤204时,其执行流程的顺序请参考图5,在对网络进行网络分割后,可以在分割后的非孤立子网中分别确定核心子网、次级子网、环型子网和树型子网。然后在核心子网中确定核心网元的位置信息。并根据核心网元的位置信息,在次级子网中确定次级网元的位置信息。然后根据核心网元和/或次级网元的位置信息,在环型子网中确定环网元的位置信息。再根据核心网元、次级网元和/或环网元的位置信息,在树型子网中确定树网元的位置信息。并在孤立树型子网中,根据核心网元、次级网元、环网元和/或树网元的位置信息,在孤立树型子网中确定孤立树网元的位置信息。
第二种布局方式:网络拓扑中的网元可以以具有最高网络层级的网元为起点,按照网络层级由高到低的顺序自上向下分布,此时,获取的网络拓扑可称为树状拓扑。当网络拓扑中的网元按照网络层级由高到低的顺序自上向下分布时,获得的网络拓扑中网元的拓扑层次更清晰,能够较清楚地呈现网络的结构、网元的网络层级及不同子网之间的关系。
并且,在该第二种布局方式中,核心网元可以布局在第一图形的边界上。该第一图形可以为:圆形、椭圆形或正多边形等闭合图形。环型子网的环网元可以布局在第三图形的边界上。该第三图形可以包括:单抛物线等图形。
示例地,图6为网元按照网络层级由高到低的顺序自上向下分布的一种示意图,图6中的黑点为网元,图6中两个网元之间的实线表示该两个网元之间存在连接关系,且距离图6所示的网络拓扑的顶部越近的网元的网络层级越高,因此,可以看出该图6中的网元是以具有最高网络层级的网元为起点,按照网络层级由高到低的顺序自上向下分布的。
当网络拓扑按照该第二种布局方式进行布局时,在执行该步骤204时,其执行流程的顺序请参考图7,在对网络进行网络分割后,可以在分割后的非孤立子网中分别确定核心子网、环型子网和树型子网。然后在核心子网中确定核心网元的位置信息。并根据核心网元的位置信息,在环型子网中确定环网元的位置信息。再根据核心网元和/或环网元的位置信息,在树型子网中确定树网元的位置信息。
并且,在执行该步骤204时,当网元的类型不同时,该步骤204的实现方式不同,下面分别针对不同类型的网元,对该步骤204的实现方式进行说明:
当待确定位置信息的网元为核心网元时,如图8所示,该步骤204的实现过程可以包括:
步骤2041a、对组成核心子网的多个核心网元进行排序,得到第一网元队列。
在一种可实现方式中,可以获取各个核心网元的链路的长度,并按照链路的长短对该多个核心网元进行排序。
示例地,可以在核心网元所在网络中,确定以各个核心网元为开始环网元和/或结束环网元的环型子网的大小,并根据环型子网包括环网元的数量由多到少的顺序对该多个核心网元进行排序。并在某个核心子网的网络中不存在对应的环型子网时,将该某个核心子网依次排在根据环型子网的环网元数量排序得到的第一网元队列的队尾。
当所有核心网元所在的网络中均不存在环型子网时,确定包括每个核心子网的最长链路的长度,并按照核心子网对应的最长链路由长到短的顺序,对该多个核心网元进行排序。并在某个核心子网的网络中不存在对应的最长链路时,将该某个核心子网依次排在根据最长链路的长度排序得到的第一网元队列的队尾。
步骤2042a、获取第一网元队列中相邻的每两个核心网元之间的第一间距。
可选的,该第一间距可以为根据实际需要确定的指定值。当网络拓扑按照第二种布局方式进行布局时,该网络拓扑中每两个核心网元之间的第一间距可以根据实际需要确定。
例如,在该第二种布局方式中,该多个核心网元可以布局在圆心角小于180度的圆弧上,即该多个核心网元按照图9所示的弧线模型布局。此时,第一间距可以由每相邻两个核心网元中每个核心网元与指定点的连线之间的第一夹角表征,且该第一夹角可以等于指定的核心网元布局的夹角常量。
或者,可以基于两个核心网元之间的下挂网元的第一总数,确定该第一间距。可选地,当第一间距由每相邻两个核心网元中每个核心网元与指定点的连线之间的第一夹角表征时,该基于两个核心网元之间的下挂网元的第一总数,确定第一间距的实现过程,可以包括:确定第一总数在第二总数中的第一总数占比,然后将第一总数占比与360度的乘积确定为第一夹角。其中,该第二总数为所有核心网元的下挂网元的总数。
示例地,当网络拓扑按照第一种布局方式进行布局时,该多个核心网元可以布局在图10所示的圆形上。此时,该核心网元i和核心网元j中每个核心网元与指定点的连线之间的第一夹角θ
ij、第一总数N
ij和第二总数∑N
ij可以满足下式:
步骤2043a、基于第一间距和核心网元的总数,确定每个核心网元的位置信息。
可选的,当多个核心网元布局在第一图形的边界上时,该步骤2043a的实现过程可以包括:
步骤2043a1、基于核心网元的总数,确定第一图形的第一定长参数。
其中,第一定长参数用于反映第一图形上的点满足的几何特征。
在步骤2043a1的一种可实现方式中,当该第一图形为圆形,且网络拓扑按照第一种方式布局时,该第一定长参数为该圆形的半径。该半径R与核心网元的总数I1可以满足下式:
其中,k1为核心网元布局的半径倍率常量。
在步骤2043a1的另一种可实现方式中,当该第一图形为圆形时,且网络拓扑按照第二种方式布局时,该第一定长参数为该圆形的半径。该半径R、核心网元的总数I1、每相邻两个核心网元中每个核心网元与指定点的连线之间的第一夹角θij可以满足下式:
其中,k1为核心网元布局的半径倍率常量。且在该第二中布局方式中该第一夹角为一指定值。
步骤2043a2、按照每个核心网元在第一网元队列中的顺序,基于第一定长参数和第一间距,依次确定核心网元的位置信息。
对应步骤2043a1的一种可实现方式,当该第一图形为以指定点为圆心的圆形时,该第一网元队列中的第t个核心网元的位置坐标(xt,yt)、该圆形的半径R,及核心网元i与核心网元j对应的第一夹角θ
ij之间可以满足:
其中,该位置坐标(xt,yt)为在图4所示的坐标系中的坐标,该指定点为该坐标系的原点。k1为核心网元布局的半径倍率常量。I1为核心网元的总数。
对应步骤2043a1的另一种可实现方式,当该第一图形为以指定点为圆心的圆形时,该第一网元队列中的第t个网元的位置坐标(xt,yt)、该第一圆形的半径R和核心网元布局的夹角常量θ2之间可以满足:
其中,位置坐标(xt,yt)为在图6所示的坐标系中的坐标,指定点为该坐标系的原点。k1为核心网元布局的半径倍率常量。I1为核心网元的总数。
通过将核心网元布局在第一图形上,且根据两个核心网元之间的下挂网元的第一总数,确定该两个核心网元之间的第一间距,能够保证同一核心网元下的所有下挂网元之间不出现交叉。
当待确定位置信息的网元为次级网元时,如图11所示,该步骤204的实现过程可以包括:
步骤2041b、基于网元之间的连接关系,将次级子网络的多个次级网元划分至多个第一网元组。
可选的,可以在次级网元及其链路中,根据网络连通性进行分组。例如,可以将直接连接次级网元划分至同一个第一网元组,将未直接连接的次级网元划分至不同的第一网元组。
步骤2042b、对每个第一网元组中至少一个次级网元进行排序,得到第二网元队列。
可选的,可以按照链路由长到短的顺序进行排序,其实现过程可以相应参考步骤2041a的实现过程。
步骤2043b、对多个第一网元组进行排序,得到网元组队列。
可选的,该步骤2043b的实现过程可以包括:
步骤2043b1、按照每个第一网元组对应的第三总数由大到小的顺序,对多个第一网元组进行初始排序,得到初始网元组队列。
其中,第三总数为第一网元组中所有次级网元的下挂网元的总数。
步骤2043b2、按照每个第一网元组对应的目标距离由大到小的顺序,对初始网元组队列重新排序,得到网元组队列。
其中,目标距离为第一网元组在初始网元组队列中的位置到初始网元组队列的中心位置的距离。
示例地,当按照每个第一网元组对应的第三总数由大到小的顺序,对多个第一网元组进行初始排序后,第一个网元组1、第二个网元组2、......、第I2-1个网元组I2-1和第I2个网元组I2在该初始网元组队列中的顺序分别为1,2,3,…,I2,在按照每个第一网元组对应的目标距离由大到小的顺序,对初始网元组队列重新排序后,第一个网元组1、第二个网元组2、......、第I2-1个网元组I2-1和第I2个网元组I2在该网元组队列中的顺序分别为1,I2,2,I2-1,3,…。这样,在该网元组队列中,多个第一网元组按照一大一小交错的方式排序,能够使得根据该网元组队列确定的网络拓扑的均匀性更好,且网元之间的网络层级更明显。
步骤2044b、基于每个第一网元组中所有次级网元的下挂网元的第三总数,确定每个第一网元组的布局宽度。
可选的,当第一网元组的布局宽度由第一网元组中位于最外侧的两个次级网元与指定点的连线之间的第二夹角表征时,该步骤2044b的实现过程可以包括:
步骤2044b1、确定任一第一网元组对应的第三总数在第四总数中的第二总数占比。
其中,第四总数为多个第一网元组中所有次级网元的下挂网元的总数。
步骤2044b2、基于任一第一网元组对应的第二总数占比,确定任一第一网元组的第二夹角。
可选地,该第二夹角可视为每个第一网元组所占的夹角。该第i个第一网元组的第二夹角θ
i、第三总数N
i、第四总数∑N
i和核心网元的总数I1满足:
步骤2045b、基于每个第一网元组的布局宽度和任一第一网元组在网元组队列中的顺序,确定任一第一网元组的布局开始位置。
可选的,当每个第一网元组的布局开始位置由布局开始角度表征时,可以基于任一第一网元组在网元组队列中的顺序,及在网元组队列中位于任一第一网元组之前的其他第一网元组的布局宽度,获取任一第一网元组的布局开始角度。其中,该布局开始角度可视为该任一第一网元组的组开始布局角度。
示例地,网元组队列中的第t个第一网元组的布局开始角度β
t,在网元组队列中位于任一第 一网元组之前的其他第一网元组的布局宽度θ
i,满足:
其中,α为每相邻的两个第一网元组间的角度差常量。
步骤2046b、基于布局宽度、布局开始位置、多个第一网元组的总组数、第二网元队列、网元组队列和每个第一网元组中的次级网元的总数,确定每个次级网元的位置信息。
可选的,如图12所示,当多个次级网元布局在至少一个第二图形的边界上时,该步骤2046b的实现过程可以包括:
步骤2046b1、基于每个次级网元所在的第一网元组在网元组队列中的顺序,确定每个次级网元所在的第二图形。
当多个次级网元布局在至少一个第二图形的边界上时,在确定每个次级网元的位置信息之前,需要先确定每个次级网元位于该至少一个第二图形中的哪个第二图形上,以便于根据对应的第二图形的图像参数确定该次级网元的位置信息。
可选地,当多个次级网元布局在多个第二图形上,且该多个第二图形可以为由内至外依次分布的多个第二图形时,由于该网元组队列中的多个第一网元组是按照一大一小交错的方式排序的,因此,该步骤2046b1的实现方式可以包括:根据第一网元组在网元组队列中的顺序,按照第一网元组所在的第二图形由内至外循环排布的方式,依次确定每个第一网元组所在的第二图形,相应的,第一网元组所在的第二图形即为该第一网元组中的次级网元所在的第二图形。
示例地,假设多个次级网元布局在两个第二图形,且该两个第二图形组成的整体图形为同心圆形(也称双层圆形,其示意图请参考图13)时,在确定第一网元组所在的圆形时,可以确定在网元组队列中位于奇数次序的第一网元组位于内部的圆形上,即位于奇数次序的第一网元组中的次级网元位于内部的圆形上,相应的,位于偶数次序的第一网元组位于外部的圆形上,即位于偶数次序的第一网元组中的次级网元位于外部的圆形上。
步骤2046b2、基于次级网元的总数和第一网元组的总组数,确定每个第二图形的第二定长参数。
其中,第二定长参数用于反映对应的第二图形上的点满足的几何特征。例如,第二图形为圆形时,该第二定长参数为圆的半径。
可选地,当多个第二图形为具有相同的几何中心,且每个第二图形互为旋转对称图形时,假设位于该至少一个第二图形最内部的第二图形的第二定长参数为Q1,那么该多个第二图形中除该最内部的第二图形的第二定长参数Q2和该位于最内部的第二图形的第二定长参数Q1应满足Q2=N×Q1,该a为该除该最内部的第二图形与该位于最内部的第二图形的周长的比例。
示例的,当多个次级网元布局在两个第二图形,且该两个第二图形组成的整体图形为同心圆形时,该步骤2046b2的实现过程可以包括:分别确定该两个圆形的半径,且位于外部的圆形的半径为位于内部的圆形的半径的N倍。
例如,当该位于内部的圆形与位于外部的圆形的周长的比例为1:2时,在网元组队列中的第t个圆形的半径r
t、次级网元的总数M和第一网元组的总组数I3可以满足:
其中,k2为次级网元布局的半径倍率常量。α为每相邻的两个第一网元组间的角度差常量。
步骤2046b3、按照每个次级网元在第二网元队列和网元组队列中的顺序,基于次级网元所在的第二图形的第二定长参数、布局宽度,布局开始位置,及每个次级网元所在第一网元组中次级网元的总数,确定次级网元的位置信息。
可选的,次级网元所在的第二图形的第二定长参数ri,布局宽度θ
i,布局开始位置β
i,为第i组的次级网元总数Mi,及网元组队列中第i个第一网元组中第j个次级网元的坐标(x
ij,y
ij)可以满足:
通过将次级网元布局在第二图形上,且根据每个第一网元组中所有次级网元的下挂网元的第三总数,确定每个第一网元组的布局宽度,能够保证每个第一网元组的所有下挂网元之间不出现交叉。
当待确定位置信息的网元为环网元时,如图14所示,该步骤204的实现过程可以包括:
步骤2041c、将至少一个环型子网划分至至少一个第二网元组。
环网元所满足的布局方式不同时,该步骤2041c的实现方式不同,下面以以下两种可实现方式为例对其进行说明:
当环型子网中的环网元按照第一种布局方式进行布局时,该步骤2041c的实现方式可以包括:将具有相同开始环网元和相同结束环网元的环型子网划分至同一第二网元组,得到至少一个第二网元组。
当环型子网中的环网元按照第二种布局方式进行布局时,该步骤2041c的实现方式可以包括:将环等级相同的环型子网划分至同一第二网元组,得到至少一个第二网元组。
步骤2042c、基于每个第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度。
其中,任一环型子网的布局宽度可以由任一环型子网的第三夹角表征,根据环网元所满足的布局方式不同时,该步骤2042c的实现方式不同,下面以以下三种可实现方式为例对其进行说明:
在第一种可实现方式中,当环型子网中的环网元按照第一种布局方式进行布局,且环网元布局在椭圆的边界上时,可以将180度与任一第二网元组对应的第五总数的商,确定为任一第二网元组中每个环型子网所占的第三夹角。该第三夹角可视为在椭圆短轴的两个端点与归属点的连线的夹角。示例地,请参考图15,该第三夹角为椭圆短轴的两个端点与归属点O’的连线的夹角
在第二种可实现方式中,当环型子网中的环网元按照第一种布局方式进行布局,且环网 元布局在双抛物线的边界上时,可以确定第一连线和第二连线所成的第四夹角,并将第四夹角与目标总数的商确定为任一第二网元组中每相邻两个环型子网的第三连线之间的第三夹角。
也即是,在第四夹角和目标总数均已知时,可以确定每相邻两个环型子网的第三连线之间的第三夹角。由于第三连线为由该环型子网的顶点与指定点共同确定的连线,且由于指定点为已知点,因此,在确定第三夹角后,即可确定每个环型子网对应的双抛物线的顶点布局在第三直线所在的方向。
其中,该目标总数等于任一第二网元组对应的第五总数减一。该第一连线为任一第二网元组中开始环网元与指定点的连线,第二连线为任一第二网元组中结束环网元与指定点的连线。
示例地,第二网元组中的五个环型子网分布在双抛物线的边界上的示意图请参考图16,其中,目标总数=5-1=4,开始环网元A1与指定点O的连线为第一连线OA1,结束环网元A2与指定点O的连线为第二连线OA2,第一连线OA1与第二连线OA2之间的夹角为第四夹角,且由于环型子网1的顶点C1与指定点O确定的第三连线与该第一连线重合,该环型子网1对应的第三连线即为第一连线OA1。类似的,由于环型子网5的顶点C5与指定点O确定的第三连线与该第二连线重合,该环型子网1对应的第三连线即为第二连线OA2。环型子网2的顶点C2与指定点O确定的连线为第三连线为OC2,环型子网3的顶点C3与指定点O确定的连线为第三连线为OC3,环型子网4的顶点C4与指定点O确定的连线为第三连线为OC4。从该图16可以看出,该五个环型子网对应的五个第三连线相当于平分了第四夹角,平分后的夹角即为每相邻两个环型子网对应的第三夹角。
在第三种可实现方式中,当环型子网中的环网元按照第二种布局方式进行布局时,可以基于任一环型子网对应的第六总数,确定该任一环型子网的布局宽度。
示例地,当环型子网布局在抛物线上,且环型子网中每相邻两个环网元之间的间距相等时,可以根据该任一环型子网中所有环网元之间的间距之和,及抛物线的常数项,确定该任一环型子网的布局宽度。
例如,可以根据该间距之和与常数项,通过勾股定理的原理,确定该任一环型子网的布
局宽度,即该第i个第二网元组中第j个环型子网的布局宽度w
ij,第i个第二网元组中第j个环型子网的下挂网元数M
ij,相邻环网元之间的理想距离常量D,及抛物线的常数项b满足:
步骤2043c、确定任一环型子网的环网元对应的第三图形的图形参数。
其中,组成任一环型子网的环网元布局对应的第三图形的边界上,第三图形的图形参数用于反映对应的第三图形上的点满足的几何特征。可选地,第三图形可以包括:椭圆形、双抛物线或抛物线(又称单抛物线)等图形。当第三图形为椭圆时,该图形参数为椭圆参数。当第三图形为双抛物线时,该图形参数为双抛物线参数。当第三图形为单抛物线时,该图形参数为单抛物线参数。
在步骤2043c的一种可实现方式中,当环型子网为单归属环时,该环型子网可以分布在椭圆形等图形的边界上。示例地,具有相同归属点的多个环型子网的环网元分别布局在多个 椭圆形的边界上的示意图请继续参考图17。此时,如图18所示,该步骤2043c的实现过程可以包括:
步骤2043c1、基于任一环型子网对应的第六总数,估算任一环型子网对应的第三图形的第一周长。
可选地,可以根据环型子网的下挂网元的第六总数I4,及环型子网中相邻两个环网元之间的距离常量,估算环型子网对应的第三图形的第一周长。例如,第二网元组中第i个环型子网的下挂网元的第六总数I4,环型子网中相邻两个环网元之间的距离常量D,与第一周长L1可以满足:
L1=(max I
4+1)×D。
步骤2043c2、基于任一环型子网对应的第三图形的周长公式,确定第三图形的第二周长。
椭圆形的标准方程为:
其中,a和b为椭圆参数,k3为椭圆形的控制参数。
根据该椭圆形的标准方程,可以得到该椭圆形的第二周长L2、椭圆参数a和b所满足的周长公式为:
步骤2043c3、基于第一周长和第二周长,获取任一环型子网对应的图形参数。
由于该第一周长和第二周长是从不同角度确定的同一个椭圆形的周长,两者应该相等,且两者中均包含椭圆参数a和b,因此,通过假设两者相等,并根据a和b的比例关系,可以确定该椭圆形的椭圆参数为:
在步骤2043c的另一种可实现方式中,当环型子网为双归属环型子网时,该环型子网可以分布在双抛物线的边界上。示例地,具有相同归属点的多个环型子网的环网元分别布局在多个双抛物线的边界上的示意图请参考图19。此时,如图20所示,该步骤2043c的实现过程可以包括:
步骤2043c4、基于任一环型子网对应的第六总数,估算任一环型子网对应的第三图形的第一周长。
该步骤2043c4的实现过程请相应参考步骤2043c1的实现过程。因此,可以得到第二网元组中第i个环型子网的下挂网元的第六总数I4,环型子网中相邻两个环网元之间的距离常量D,与第一周长L1可以满足:
L1=(max I
4+1)×D。
步骤2043c5、基于任一环型子网对应的第三图形的周长公式,确定第三图形的第二周长。
双抛物线的标准方程为:
其中,a1、a2和b均为双抛物线参数。
由于双抛物线所满足的图形性质和单抛物线所满足的图形性质相似,因此,可以根据单抛物线的周长公式估算该双抛物线的第二周长,通过假设双抛物线参数a1=a2,可以得到如下第二周长关于双抛物线的抛物线弧长方程L(b):
其中,d为任一环型子网的两个归属点之间的距离,即该任一环型子网的开始环网元和结束环网元之间的距离。
步骤2043c6、基于任一环型子网对应的第一周长和第二周长,获取任一环型子网对应的图形参数中的第一子参数。
由于该抛物线弧长方程L(b)在(0,+∞)是单调递增的,且第一周长L1为常数,因此,在获取双抛物线的第一周长和第二周长后,可以通过二分迭代的方式求解参数b,即该参数b为双抛物线参数中的第一子参数。
步骤2043c7、基于任一环型子网对应的第一子参数,任一环型子网对应的布局宽度,及任一环型子网中开始环网元和结束环网元之间的距离,确定任一环型子网对应的图形参数中的其他子参数,得到任一环型子网对应的图形参数。
可选地,双抛物线中的其他子参数a1和a2、第一子参数b、该任一环型子网中开始环网元和结束环网元之间的距离d(即两个归属点之间的距离d)可以满足:
其中,θ3为由环型子网的两个归属点所在直线的左端逆时针转到该环型子网的第三连线所经过的夹角。示例地,图21为图16的局部示意图请参考,由环型子网2的顶点C2与指定点O确定的连线为第三连线OC2,由两个归属点所在直线A1A2的左端逆时针转到第三连线OC2所经过的夹角为θ3。该夹角θ3的确定过程包括:在确定该任一环型子网对应的第三夹角后,可以确定该任一环型子网所在的第二网元组中布局在该任一环型子网左侧的环型子网,以及该位于左侧的环型子网对应的第三夹角,然后将该任一环型子网对应的第三夹角和位于左侧的环型子网对应的第三夹角的和确定为该夹角θ3。
在步骤2043c的又一种可实现方式中,当环型子网为双归属环型子网时,该环型子网可以分布在单抛物线的边界上。示例地,具有相同归属点的多个环型子网的环网元分别布局在多个单抛物线的边界上的示意图请参考图22。此时,如图23所示,该步骤2043c的实现过程可以包括:
步骤2043c8、基于任一第二网元组中每个环型子网的开始环网元和结束环网元的位置信 息,对任一第二网元组中至少一个环型子网进行排序,得到第一网络队列。
可选地,可以分别根据每个环型子网的开始环网元和结束环网元的位置信息,计算每个环型子网的开始环网元和结束环网元在一个坐标方向上的坐标的平均值,然后按照该平均值由小到大的顺序,对该任一第二网元组中至少一个环型子网进行排序,得到第一网络队列。
并且,在第二种布局方式中,由于各个网元是按照网络层级由高到低的顺序自上向下布局的,即布局方向平行于y坐标方向,因此,在执行该步骤2043c8的过程中,可以按照环网元的x坐标的平均值对至少一个环型子网进行排序。
步骤2043c9、基于任一第二网元组中环型子网的开始环网元和结束环网元的位置信息,确定任一第二网元组的第一重心的位置信息。
在第二种布局方式中,由于各个网元是按照网络层级由高到低的顺序自上向下布局的,即布局方向平行于y坐标方向,因此,该步骤2043c9的实现过程可以包括:确定任一第二网元组在x坐标方向上的第一重心的位置信息,相应的,任一第二网元组的第一重心可理解为该任一第二网元组的在x坐标方向上的重心。该任一第二网元组在x坐标方向上的第一重心的位置信息等于组内所有环型子网的开始环网元和结束环网元在x坐标方向上的坐标之和与该任一第二网元组对应的第五总数的商。
步骤2043c10、基于任一第二网元组的第一重心的位置信息、任一环型子网的布局宽度、任一环型子网在第一网络队列中的顺序,及任一环型子网的环等级,确定与开始环网元直接连接的环网元和与结束环网元直接连接的环网元中的至少一个目标环网元的位置信息。
在确定单抛物线的单抛物线参数时,可以先根据开始环网元和结束环网元的位置信息确定该环型子网中一个环网元的位置信息,然后将该环网元的位置信息带入单抛物线的标准方程,以得到该单抛物线参数。该环型子网中待计算位置信息的环网元可以为该环型子网中除开始环网元和结束环网元外的环网元重组的环型子网中的任一个环网元。
在确定任一第二网元组的第一重心的位置信息后,即可确定该任一第二网元组的布局位置,在确定该第二网元组环型子网的环网元的位置信息时,可以基于该布局位置,并参考各个环型子网的布局宽度和环型子网在第一网络队列中的顺序等信息,确定该环型子网中环网元在x坐标方向上的位置信息,然后根据该环型子网的环等级等信息确定该环型子网中环网元在y坐标方向上的位置信息。
可选地,为便于计算,该待计算位置信息的环网元可以为该重组的环型子网的开始环网元和结束环网元。示例地,在第二种布局方式中,对于第i个第二网元组对应的第一网络队列中第t个环型子网,其重组的环型子网的开始环网元的位置信息(x
s
it,y
s
it),该第一网络队列中各个环型子网的布局宽度w
ij,该第二网元组在x坐标方向上的第一重心的位置信息z
i,及该环型子网的环等级k4,满足:
其中,ymin1为核心网元的y坐标的最小值,drw为该环型子网在x坐标方向上的间距常量,drh为该环型子网所在的第二网元组在y坐标方向上的间距常量。
重组的环型子网的结束环网元的位置信息(x
e
it,y
e
it),及该重组的环型子网布局宽 度w
it,满足:
其中,获取该重组的环型子网的布局宽度的实现过程请相应参考步骤2042c获取任一环型子网的布局宽度的实现过程。
步骤2043c11、基于任一环型子网对应的目标环网元的位置信息和对应的第三图形所满足的函数关系,确定图形参数。
单抛物线的标准方程为:
y=ax
2-b;
其中,b为常量。
由于该重组的环型子网中的环网元均布局在该单抛物线上,该重组环型子网中所有环网元的位置信息均应满足该标准方程,因此,可以将该重组环型子网中位置信息已知的环网元的带入该标准方程,以得到该单抛物线参数a。将重组的环型子网的开始环网元的位置信息(x
s
it,y
s
it)和结束环网元的位置信息(x
e
it,y
e
it)中的任一个的位置信息(x
s,y
s)带入该标准方程,可得:
步骤2044c、基于任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网中每个环网元的位置信息。
当环型子网中的环网元按照第一种布局方式进行布局时,如图24所示,该步骤2044c的实现方式可以包括:
步骤2044c1、基于任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网对应的第三图形坐标系。
当环网元所分布的第三图形的形状不同时,该步骤2044c1的实现方式也不同,下面以该第三图形分别为椭圆和双抛物线为例,分别对其进行说明:
当第三图形为椭圆形时,如图25所示,步骤2044c1的实现过程可以包括:
步骤2044c11、基于任一环型子网对应的图形参数,确定任一环型子网对应的第三图形的几何中心在第三图形中的第一相对位置。
椭圆形的椭圆参数a和b分别对应椭圆的长轴和短轴,因此,在获取该椭圆参数a和b后,就可以确定该椭圆形的形状,相应的,就可以确定该椭圆形的几何中心在该椭圆形中的第一相对位置。该第一相对位置可视为该几何中心相对于该椭圆形的定点的相对位置。
步骤2044c12、基于任一环型子网对应的第一相对位置和对应的布局宽度,确定任一环型子网对应几何中心在任一环型子网所在的目标第二网元组中的第二相对位置。
在确定任一环型子网所布局的椭圆形的几何中心在该椭圆形中的第一相对位置,及该任一环型子网所在的目标第二网元组中所有环型子网对应的布局宽度后,可以确定每个环型子网对应的椭圆形所占的面积大小,即可以确定每个环型子网对应的椭圆形的大小,相应的,根据该任一环型子网在该目标第二网元组对应的第一网络队列中的顺序,及每个环型子网对 应的椭圆形的大小,即可确定该任一环型子网在该目标第二网元组中的第二相对位置。该第二相对位置可视为该环型子网的几何中心相对于该目标第二网元组中归属点的相对位置。
步骤2044c13、基于任一环型子网对应的第二相对位置和归属点的位置信息,确定任一环型子网对应的几何中心的位置信息。
归属点的位置信息用于指示该目标第二网元组的具体布局位置,在确定该任一环型子网在该目标第二网元组中的第二相对位置后,由于第二相对位置可视为该环型子网的几何中心相对于该目标第二网元组中归属点的相对位置,因此,可以根据该归属点的位置信息确定该几何中心的位置信息。
步骤2044c14、将任一环型子网对应的几何中心的位置信息确定为对应的第三图形坐标系的原点的位置信息,将任一环型子网对应的几何中心与对应的归属点的连线所在的方向确定为任一环型子网对应的第三图形坐标系的第一方向,将与第一方向垂直的方向确定为任一环型子网对应的第三图形坐标系的第二方向。
每个环型子网对应的第三图形坐标系为针对该环型子网建立的坐标系,因此,可以将该环型子网对应的几何中心确定为该第三图形坐标系的原点。将该几何中心与对应的归属点的连线所在的方向确定为对应环型子网所在的第三图形坐标系的第一方向。并将与该第一方向垂直的方向确定为对应环型子网所在的第三图形坐标系的第二方向。例如,请参考图16,该第一方向可以为x坐标方向,在确定该第三图形坐标系的x方向后,可以根据右手坐标系原则,确定该y坐标方向。
当第三图形为双抛物线时,如图26所示,该步骤2044c1的实现过程可以包括:
步骤2044c15、将任一环型子网的开始环网元和结束环网元的中点确定为任一环型子网对应的第三图形坐标系的坐标原点。
步骤2044c16、确定任一环型子网所在的第二网元组对应的参考图形。
当第三图形为双抛物线时,每个第二网元组中多个环型子网的顶点可以分布在该参考图形的边界上。为保证获取的网络拓扑的层次清晰性和美观性,该其参考图形可以为以指定定长为半径,以对应的第三图形坐标系的坐标原点为圆心的圆。该指定定长可以等于环型子网所分布的双抛物线的标准方程中的常数项。
在确定环型子网的布局宽度后,可以确定每个环型子网对应的双抛物线的顶点布局在对应的第三直线所在的方向上。且由于每个环型子网对应的双抛物线的顶点分布在该参考图形的边界上,因此,可以将环型子网对应的第三直线和参考图形的目标交点所处的位置确定为该环型子网对应的双抛物线的顶点所在的位置。
步骤2044c17、将对应的第三图形坐标系的坐标原点与目标交点的连线所在的方向确定为对应的第三图形坐标系的第二方向,将与第二方向垂直的方向确定为对应的第三图形坐标系的第一方向。
示例地,请参考图16,虚线所示的圆形为该第二网元组对应的参考图形,该参考图形的原点为开始环网元A1与结束环网元A2的中点A3,相应的,环型子网4对应的第三图形坐标系的坐标原点也位于该环型子网4的开始环网元和结束环网元的中点A3处。根据该图16可知该环型子网4对应的第三连线OC4与该参考图形存在目标交点,因此,可以确定该环型子网4对应的双抛物线的顶点位于该目标交点处,且该环型子网4对应的第三图形坐标系的y坐标方向可以沿该目标交点指向该第三图形坐标系的原点的方向。并且,根据右手坐标系 原则,可以该第三图形坐标系的x坐标方向。
步骤2044c2、基于任一环型子网对应的第六总数,对应的第三图形坐标系和对应的图形参数,及对应的布局宽度,确定任一环型子网中每个环网元的位置信息。
当环网元所分布的第三图形的形状不同时,该步骤2044c2的实现方式也不同,下面以该第三图形分别为椭圆和双抛物线为例,分别对其进行说明:
当第三图形为椭圆形时,可以分别根据每个环型子网对应的第六总数,对应的第三图形坐标系和对应的图形参数,及对应的布局宽度,确定任一环型子网中每个环网元的位置信息。并且在确定每个环型子网上的环网元的位置信息时,可以根据待确定位置信息的环网元的布局大概位置,分别按照以下两条原则,确定对应环网元的位置信息:
若环网元位于椭圆的短轴左侧,该任一环型子网对应的第六总数I4,对应的第三图形坐标系和对应的椭圆的图形参数a和b,及该任一环型子网中每个环网元i的位置信息(x
i,y
i),可以满足:
若环网元位于椭圆的短轴右侧,该任一环型子网对应的第六总数I4,对应的第三图形坐标系和对应的椭圆的图形参数a和b,及该任一环型子网中每个环网元i的位置信息(x
i,y
i),可以满足:
当第三图形为双抛物线时,如图27所示,该步骤2044c2的实现过程可以包括:
步骤2044c21、基于任一环型子网对应的布局宽度、对应的第六总数、对应的图形参数,及任一环型子网中开始环网元和结束环网元之间的距离,在任一环型子网所包括的多个环网元中,确定作为任一环型子网的顶点的目标环网元。
可选地,如图28所示,步骤2044c21的实现过程可以包括:
步骤c211、基于任一环型子网对应的图形参数和对应的布局宽度,及任一环型子网中开始环网元和结束环网元之间的距离,确定任一环型子网对应的第三图形的第一弧长和第二弧长。
其中,第一弧长为位于第三图形的顶点左侧的弧的长度,第二弧长为位于第三图形的顶点右侧的弧的长度。第一弧长L
l和第二弧长L
r的计算公式可以为:
其中,θ4为该双抛物线的布局宽度,d为该任一环型子网中开始环网元和结束环网元之间的距离,a1和a2分别为双抛物线的图形参数。
步骤c212、基于任一环型子网对应的第一弧长和第二弧长,及任一环型子网对应的第六总数,确定作为任一环型子网的顶点的目标环网元。
可选地,可以根据第一弧长在该双抛物线中的弧长占比,在任一环型子网所包括的多个下挂网元中,确定作为该任一环型子网的顶点的目标环网元。
例如,该目标环网元在多个下挂网元中的次序t、多个下挂网元的第六总数I4、第一弧长L
l和第二弧长L
r可以满足:
其中,round为四舍五入函数。
在确定该次序t后,可以按照该任一环型子网中环网元之间的连接关系,从开始环网元向结束环网元开始计数,将计数到t的环网元确定为作为该任一环型子网的顶点的目标环网元。
步骤2044c22、基于任一环型子网对应的布局宽度,目标环网元在任一环型子网中多个环网元中的次序,任一环型子网中开始环网元和结束环网元之间的距离,任一环型子网对应的第三图形坐标系和对应的图形参数,确定每个环网元的位置信息。
可选地,对于该任一环型子网上的第i个环网元,该环网元的x坐标应满足下面的方程,且由于该方程为在各自区间内的单调函数,因此,在确定任一环型子网对应的布局宽度,及任一环型子网中开始环网元和结束环网元之间的距离后,可以将该布局宽度和该距离带入该方程,并通过二分迭代的方式求解每个环网元的x坐标,然后将该x坐标代入双抛物线的标准方程,以得到该x坐标对应的y坐标,进而得到每个环网元的位置信息。
其中,θ5为该任一环型子网对应的布局宽度,d为该任一环型子网中开始环网元和结束环网元之间的距离,t为目标环网元在该任一环型子网的多个下挂网元中的次序,a1和a2分别为双抛物线的图形参数,I4为该任一环型子网多个下挂网元的第六总数,L
l为该任一环型子网对应的双抛物线的第一弧长,L
r为该任一环型子网对应的双抛物线的第二弧长。
需要说明的是,当环网元按照该第一种布局方式进行布局时,由于每个环网元的位置关 系均是根据每个环型子网对应的第三图形坐标系确定的,因此,在获取到每个环网元在第三图形坐标系中的位置信息后,还需要根据该对应的第三图像坐标系和网络拓扑对应的全局坐标系,将该环网元在第三图形坐标系中的位置信息转换到该全局坐标系中,以得到在相同参考标准下的位置信息。可选地,在进行坐标转换时,环网元在转换前的坐标(x,y)和转换后的坐标(x’,y’)可以满足:
其中,η为第三图像坐标系相对于全局坐标系的坐标系旋转角度,dx为第三图像坐标系相对于全局坐标系的x轴方向偏移大小,dy为第三图像坐标系相对于全局坐标系的y坐标方向方向偏移大小。
当环型子网中的环网元按照第二种布局方式进行布局时,如图29所示,该步骤2044c的实现方式可以包括:
步骤2044c3、基于任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,通过二分迭代算法获取任一环型子网中每个环网元在第一方向上的位置信息。
可选地,对于该任一环型子网上的第i个环网元,该环网元的x坐标应满足下面的方程,且由于该方程为在区间[-w/2,w/2]内的单调函数,因此,在确定任一环型子网下挂网元的第六总数,对应的图形参数及对应的布局宽度后,可以将该布局宽度和该距离带入该方程,在该任一环型子网的开始环网元和结束环网元的位置信息限定的范围内,通过二分迭代的方式求解任一环型子网中每个环网元在第一方向上的位置信息。
可选地,环网元的x坐标应满足的方程为:
其中,I4为该任一环型子网下挂网元的第六总数,a为该任一环型子网的图形参数,w为该任一环型子网的布局宽度。
步骤2044c4、基于对应的图形参数和任一环网元在第一方向上的位置信息,确定任一环网元在第二方向上的位置信息。
在确定任一环型子网中每个环网元在第一方向上的位置信息后,可以将该环网元在第一方向上的位置信息带入该环型子网对应的第三图形的标准方程中,通过求解该方程得到该环网元在第二方向上的位置信息。
需要说明的是,以上为计算一个环型子网中环网元的位置信息的说明。但是,网络中通常包括多个环型子网。在计算该多个环型子网中环网元的位置信息的过程中,通常采用遍历并迭代的方式确定下一个环网元的位置信息的。且在该遍历迭代的过程中,是将当前网元的最短路径对应的网元确定为下一个需要计算位置信息的环网元,但是当网络结构比较复杂时, 该迭代计算方式的性能较低,导致网络中网元位置信息的效率较低。为了提高计算网络中网元位置信息的效率,可以先按照网络的连通性及最短路径原则,将网络分成若干簇,并优先计算属于同一个簇内的环型子网中环网元的位置信息,然后计算不同簇之间的环型子网中环网元的位置信息。
将网络分簇的实现过程可以包括:将直接连接的次级网元划分至同一组,然后按照每个其余网元到次级网元的路径远近,将每个其余网元划分到最近路径对应的次级网元所在的组,完成分组后,每个组中包括的网元和链路组成的集合为一簇。并且,若某其他网元到不同组中次级网元的路径相等,可将该网元划分至任一组。且核心网元可以作为公共网元,属于每个簇。示例地,如图30所示,网元F1与网元F2属于核心网元,网元F4、网元F3、网元F5与网元F6属于次级网元,网元F7至F16属于低层级网元,按照以上网络分簇规则可将网络分为图30所示的簇1、簇2、簇3和簇4四个簇。其中,位于同一虚线圆内的网元属于同一簇。
在计算属于同一个簇内的环型子网中环网元的位置信息的过程中,可以通过以下策略将跨环链路并入环型子网,以及,在计算不同簇之间的环型子网中环网元的位置信息中,可以通过以下策略将跨簇链路并入环型子网,以便于在环型子网的计算过程,按照环网元之间的连接关系对各个环网元进行遍历,以提高遍历的效率,进而提高计算环网元位置信息的效率。
可选地,将跨环链路并入环型子网的过程可以包括:以任意一条跨环链路作为发起点,寻找该链路上任一网元到除该链路上网元的其他网元的路径。当该任一网元到该簇中环网元对应的路径为该任一网元到其他网元的路径中的最短路径时,可以确定该链路与最短路径经过的所有网元构成一个最小环结构,此时,可以将该最小环结构上的网元确定为新加入环型子网的环网元,即完成了该跨环链路并入环型子网的过程。当该任一网元到该簇中环网元对应的路径不是该任一网元到其他网元的路径中的最短路径时,继续遍历其他跨环链路,直到遍历完该簇内的所有跨环链路。并且在遍历过程中,可以按照网络层级由高到低的顺序进行遍历。且在计算最短路径的过程中,可以优先考虑同层环型子网,双归属环型子网,再考虑单归属环型子网和跨层环型子网,以减少网络中的链路交叉,使环结构显示更加明显。
可选地,将跨簇链路并入环型子网的过程可以包括:首先找到跨簇链路中的不是环网元的网元,并计算其到任一簇中环网元的最短路径,该最短路径经过的网元和该跨簇链路可构成一个跨层环,此时,可将该最短路径经过的网元更新为该环网元所在环的新入环网元,即完成了该跨簇链路并入环型子网的过程。并按照计算簇内环网元的原则,计算该新入环网元在对应簇内的下挂环。然后继续遍历其他跨簇链路,直到遍历完所有跨簇链路。
当待确定位置信息的网元为树网元时,由于每个树型子网与其他树型子网之间不会存在连接关系,通过将网络划分为树型子网络,并获取每个树型网元的位置信息,能够有效减少获得的网络拓扑中网元链路之间的交叉。
并且,对于不同类型的树型子网,该步骤204的实现方式不同。下面分别针对树型子网不同的类型,对该步骤204的实现方式进行说明:
当网络拓扑按照第一种布局方式进行布局且树网元为非孤立网元时,或者,当树型子网属于短树子网时,如图31所示,该步骤204的实现过程可以包括:
步骤2041d1、在组成树型子网的多个树网元中,确定第一根网元。
在一个树型子网中,网络层级最高的网元为该树型子网的第一根网元。且每个树型子网 中通常只有一个第一根网元。因此,在执行该步骤2041d1时,可以将该树型子网中具有最高网络层级的树网元确定为该树型子网的第一根网元。
步骤2042d1、获取每个树网元的布局开始位置。
在该实现方式中,与同一第一根网元连接的多个其他树网元布局在以第一根网元为圆心,以指定长度为半径的圆上。也即是,树型子网中处于同一深度上的树网元可以布局在一个以指定半径,以第一根网元为圆心的圆弧上,不同深度的树网元可以分别布局在不同半径且以第一根网元为圆心的圆弧上。且树网元深度越大时,该树网元对应的圆弧的半径越大。此时,可以视为每个树型子网中的树网元布局在弧线树模型上,其示意图请参考图32,该图32中黑点为树网元,每两个树网元之间的实线用于表示该两个树网元之间存在连接关系,图32中深度相同的树网元布局在同一圆的圆弧上,深度不同的树网元布局同一圆心但半径不同的圆弧上,且树网元的深度越大时,树网元对应的圆弧的半径越大。其中,该其他树网元为树型子网中处根网元外的树网元。
每个树网元的布局开始位置可以由布局开始角度表征,对于不同类型的树网元,获取布局开始角度的实现方式可以包括:
当第一根网元所属的树型子网为短树子网时,第一根网元的布局开始角度可以为-180度。
当第一根网元为第一种布局方式中的非孤立网元时,如图33所示,可以基于第一根网元A和指定点O的位置信息,将第一根网元A和指定点O所在的直线确定为目标直线,并将目标射线OZ与指定直线的夹角确定为该第一根网元A的布局开始角度μ。其中,目标射线OZ为垂直于该目标直线,且发射方向背离该指定点的射线。该指定直线可以为在全局坐标系中,x坐标方向所在的直线。
当其他树网元所属的树型子网为短树子网,或者,其他树网元为第一种布局方式中的非孤立网元时,可以根据树网元之间的连接关系,对与同一父网元连接的多个子网元进行排序,得到第三网元队列。并基于任一其他树网元所连接的父网元的布局开始角度、布局宽度和宽度,及在第三网元队列中顺序位于该任一其他树网元之前的其他树网元的宽度,确定该任一其他树网元的布局开始角度。其中,其他树网元为多个树网元中除第一根网元外的树网元。
例如:第三网元队列中第t个其他树网元所连接的父网元的布局开始角度α
f、布局宽度θ
f和宽度w
f,及在第三网元队列中顺序位于任一其他树网元之前的其他树网元i的宽度w
c
i,及该任一其他树网元的布局开始角度a
c
t,可以满足:
其中,每个树网元的宽度等于该树网元的子网元的宽度之和,且没有子网元的树网元的宽度为1。例如,如图34所示,该树型子网包括:树网元e1、树网元e2、树网元e3、树网元e4和树网元e5,树网元e4和树网元e5为树网元e3的子网元,树网元e2和树网元e3为树网元e1的子网元。该树网元e2、树网元e4和树网元e5没有子网元,可以确定该树网元e2、树网元e4和树网元e5的宽度均为1,树网元e3的宽度为该树网元e4的宽度和树网元e5的宽度的和,即该树网元e3的宽度为2,树网元e1的宽度为该树网元e2的宽度和树网元e3的宽度的和,即该树网元e1的宽度为3。
步骤2043d1、获取每个树网元的布局宽度。
其中,每个树网元的布局宽度可以由第五夹角表征。
当树网元为第一根网元时,该第一根网元的第五夹角为180度。
当树网元为其他树网元时,可以根据树网元之间的连接关系,基于任一其他树网元的宽度,任一其他树网元所连接的父网元的第五夹角和宽度,确定任一其他树网元的第五夹角。例如,该任一其他树网元t的第五夹角θ
c
t、任一其他树网元的宽度w
c
t、该任一其他树网元所连接的父网元的第五夹角θ
f和宽度w
f,可以满足:
通过将树网元布局在弧线树上,能够根据树网元的宽度分配树网元的布局宽度的大小,进而保证同一根网元下的所有树网元之间不出现交叉。
步骤2044d1、获取每个其他网元的深度。
树型子网中每个网元的深度等于网元到达该树型子网的根网元的最短路径中包括的网元的总数。因此,在执行该步骤2044d1时,对于任一其他网元,可以先确定该任一其他网元到达该任一其他网元所在的树型子网的根网元的最短路径,并统计该最短路径包括的网元的总数,该总数即为该任一其他环网元的深度。
步骤2045d1、基于任一其他树网元深度、布局开始位置和布局宽度,及第一根网元的位置信息,确定任一其他树网元的位置信息。
可选地,该任一其他树网元的深度p、布局开始位置ɑ、布局宽度θ6、第一根网元的位置信息(x
0,y
0),及该任一其他树网元的位置信息(x,y),可以满足:
其中,h为树的每一层的高度常量。
当待确定位置信息的网元为孤立网元时,该孤立网元之间可以按照树型连接,下面以孤立网元均为树型子网中的树网元为例,对该步骤204的实现过程进行说明。如图35所示,该步骤204的实现过程可以包括:
步骤2041d2、在组成树型子网的多个树网元中,确定第二根网元。
该步骤2041d2的实现过程请相应相应参考步骤2041d1的实现过程。
步骤2042d2、对所有孤立树型子网中的第二根网元进行排序,得到第四网元队列。
由于孤立树型子网中的第二根网元与核心网元之间不存在连通路径,因此,可以随机对网络中的多个第二根网元进行初始排序,并根据多个第二根网元的深度对该初始排序结果进行调整,以得到该第四网元队列。例如,对初始排序结果进行调整的过程,可以按照将具有较大深度的多个孤立树型子网对应的第二根网元岔开的原则进行。其中,孤立树型子网的深度可以等于该孤立树型子网中具有最大深度的树网元的深度。
步骤2043d2、获取每个树网元的布局宽度。
可选地,每个树网元的布局宽度可以由第五夹角表征。此时,可以根据树网元之间的连接关系,获取每个树网元的宽度,并基于每个树网元的宽度,确定每个树网元的布局宽度。
可选地,树网元的宽度与夹角之间存在对应关系,当在根据该树网元的宽度确定该树网元对应的第五夹角时,可以根据树网元的宽度查询该对应关系,并将该宽度对应的夹角确定 为该树网元的宽度。例如,假设宽度与夹角之间的对应关系为:宽度与夹角成正比,且度量为1的宽度对应的夹角阈值为ω度,则宽度为m的树网元的布局宽度w=m×ω。
步骤2044d2、获取每个树网元的布局开始位置。
可选地,孤立网元可以布局在非孤立网元的布局区域外。例如,如图36所示,图36中黑点表示孤立网元,每两个孤立网元之间的实线用于表示该两个孤立网元之间存在连接关系,当非孤立网元按照第一种布局方式布局时,孤立网元可以布局在非孤立网元所在的圆形区域的外部。且存在连接关系的孤立网元可以布局在树型子网中。
此时,每个树网元的布局开始位置可以由布局开始角度表征,该布局开始角度可以通过圆形区域的圆心角表示。相应的,在确定任一第二根网元的布局开始角度时,可以基于第四网元队列中顺序位于该任一第二根网元之前的其他第二根网元的宽度,确定第二根网元的布局开始位置。例如,可以假设第四网元队列中的第一个第二根网元的布局开始角度为0,则第四网元队列中第t个第二根网元的布局开始角度β
t,第四网元队列中第i个根网元的宽度为w
i,可以满足:
其中,α为每相邻的两个第二根网元间的角度差常量。
步骤2045d2、基于指定半径、所有第二根网元的宽度之和,及在第四网元队列中顺序位于任一第二根网元之前的其他第二根网元的宽度之和,确定任一第二根网元的位置信息。
可选地,该指定半径可以为非孤立网元到原点的距离的最大值作为半径Rr。这样一来,可以使所有孤立网元均布局在非孤立网元的外部,使得孤立网元和非孤立网元之间不会存在干扰。
并且,第四网元队列中第t个第二根网元的位置信息(x
t,y
t),指定半径Rr、第四网元队列中所有第二根网元的宽度之和∑w,及在第四网元队列中顺序位于该第t个第二根网元之前的其他第二根网元的宽度之和
可以满足:
步骤2046d2、基于任一其他树网元的布局开始位置和布局宽度,及第一根网元的位置信息,确定任一其他树网元的位置信息。
该步骤2046d2的实现过程请相应参考步骤2045d1的实现过程。
当树型子网属于长树子网时,请参考图37,该步骤204的实现过程可以包括:
步骤2041d3、获取多个树型子网组成的整体网络的第二重心的位置信息。
在第二种布局方式中,由于各个网元是按照网络层级由高到低的顺序自上向下布局的,即布局方向平行于y坐标方向,因此,该步骤2041d3的实现过程可以包括:确定该整体网络 在x坐标方向上的第二重心的位置信息,相应的,该整体网络的第二重心可理解为该整体网络在x坐标方向上的重心。该整体网络在x坐标方向上的第二重心的位置信息等于该整体网络中所有树型子网的原始根网元在x坐标方向上的坐标之和与长树的个数的商。
步骤2042d3、获取每个树型子网的宽度。
树型子网的宽度可以等于该树型子网中根网元的宽度。
步骤2043d3、按照每个树型子网的第三根网元的位置信息,对多个树型子网进行排序,得到第二网络队列。
该第三根网元可以为树型子网的树型子网中的根网元。在执行该步骤2043d3时,可以按照多个树型子网所属的树型子网中第三根网元的x值由小到大的顺序,对该多个树型子网进行排序,以得到第二网络队列。
步骤2044d3、基于每个树型子网的宽度,第二重心的位置信息,及在第二网络队列中顺序位于任一树型子网之前的其他树型子网的宽度,确定任一树型子网的第三根网元的位置信息。
可选地,该树型子网中的树网元的布局方式可以满足:处于同一深度上的树网元可以布局在一条水平线上,且所有树网元在同一水平面上的投影形成点等间距排布。也即是,该树型子网中的树网元可以布局在直线树模型上。例如,图38为本申请实施例提供的一种直线树模型的结构示意图,该图38中的黑点表示网元,网元之间的实线表示网元之间存在连接关系。如图38所示,处于同一深度上的树网元可以布局在一条水平线上,所有树网元在同一水平面上的投影形成的点等间距排布(即图38中每相邻两个箭头之间的间距相等),每相邻两个深度上的树网元的竖直方向上的间距相等,且每个树网元所占的宽度与该树网元的宽度成正比。
当将树网元布局在直线树模型上时,由于树的发散方向竖直向下,使得树型子网的每一层网元分布在一条水平线上,可以根据树网元的宽度分配其所占水平宽度的大小,保证了同一个根网元下的所有树网元之间不存在交叉。
相应的,在该布局方式中,第二网络队列中第j个第三根网元的位置信息(x
j,y
j)、每个树型子网的宽度w
i,x坐标方向上的第二重心的位置信息z,可以满足:
其中,k5为长树宽度倍数常量,d
tw为树型子网之间在x坐标方向上的间距常量,d
th为长树网元与其它网元在y坐标方向上的间距常量,ymin2为非长树网元在y坐标方向上的最小值,I5为第二网络队列中树型子网的总数。
步骤2045d3、根据树网元之间的连接关系,对与同一父网元连接的多个子网元进行排序,得到第五网元队列。
可选地,对于与同一父网元连接的多个子网元,可以随机地对该多个子网元进行初始排序,并根据多个子网元的宽度对该初始排序结果进行调整,以得到该第五网元队列。例如,对初始排序结果进行调整的过程,可以按照将具有较大宽度的多个子网元岔开的原则进行。
步骤2046d3、基于任一其他树网元所连接的父网元的位置信息,任一其他树网元的宽度,及在第五网元队列中顺序位于任一其他树网元之前的其他树网元的位置信息和宽度,确定任 一其他树网元的位置信息。
可选地,基于任一其他树网元所连接的父网元的位置信息(x
f,y
f),任一其他树网元的宽度w
t,及在第五网元队列中顺序位于任一其他树网元之前的其他树网元的宽度w
i,在该第五网元队列中该其他树网元前一个其他网元在x坐标方向上的位置信息x
c
t-1,及第五网元队列中第t个其他树网元的位置信息(x
c
t,y
c
t),可以满足:
其中,k5为长树宽度倍数常量,h为树的每一层的高度常量,I6为第五网元队列中其他树网元的总数。且当t=1时,x
c
t-1=0。
步骤205、基于多个网元之间的连接关系和每个网元的位置信息,建立网络拓扑。
在获取网络中每个网元的位置信息后,可以根据该位置信息和网络中网元之间的连接关系,将该网络拓扑可视化,在网络组网信息的表示和分析上,具有举足轻重的作用。例如,可以对网络资源管理、评估分析、规划设计、实施整改和例行维护等均具有重大参考意义。
示例地,当网络中的多个网元按照第一种布局方式进行布局时,根据本申请实施例提供的网络拓扑的确定方法获得的网络拓扑的示意图请参考图39。如图39所示,该网络拓扑中的网元是以该图的几何中心为起点由内向外分布的,且该网络拓扑中的核心网元布局在以几何中心处为圆心的圆形上,次级网元布局在以几何中心为圆心且包括两个圆形的同心圆形上,环网元中的一部分布局在双抛物线上,环网元中的另一部分布局在椭圆形上,树网元布局在弧线树模型上,孤立网元布局在非孤立网元所在的圆形区域外的区域中。
当网络中的多个网元按照第二种布局方式进行布局时,根据本申请实施例提供的网络拓扑的确定方法获得的网络拓扑的示意图请参考图40。如图40所示,该网络拓扑中的网元(如黑点所示)是自上向下分布的,且该网络拓扑中的核心网元布局在一段圆弧上,环网元布局在单抛物线上,短树子网中的树网元布局在弧线树模型上,长树子网中的树网元布局在直线树模型上。
从该图39和图40均可以看出:该网络拓扑中的链路交叉较少,该网络拓扑具有较好的对称性,且该网络拓扑能够较清楚地呈现网络的结构、网元的网络层级及不同子网之间的关系。
综上所述,本申请提供了一种网络拓扑的确定方法,通过基于多个网元之间的连接关系和每个网元的网络层级,分别确定多个子网络,按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息,并基于多个网元之间的连接关系和每个网元的位置信息,建立网络拓扑,相较于相关技术,能够自动地获取网元的位置信息,无需手动对网络拓扑进行调整,有效地提高了获取网络拓扑的效率。还能够有效地减少网络拓扑中的链路交叉,且无需预置网元的初始位置,使得获取的网络拓扑的结果唯一,且获取的网络拓扑能够较清楚地呈现网络的结构、网元的网络层级及不同子网之间的关系。并且,由于在确定网元的位置信息时,采用的图形均为具有较好对称性的图形,使得获取的网络拓扑具有较好的对称性。同时,在该计算网元的位置信息的过程中,通过采用定积分、二分迭代、图形参数求解以及坐标变换等方式简化计算量,能够减少确定网元位置 信息的耗时,解决了相关中算法不收敛和效率低的问题。
需要说明的是,本申请实施例提供的网络拓扑的确定方法步骤的先后顺序可以进行适当调整,步骤也可以根据情况进行相应增减,任何熟悉本技术领域的技术人员在本发明揭露的技术范围内,可轻易想到变化的方法,都应涵盖在本发明的保护范围之内,因此不再赘述。
下述为本申请的装置实施例,可以用于执行本申请的方法实施例。对于本申请装置实施例中未披露的细节,请参照本申请方法实施例。
图41示出了本申请示例性实施例提供的一种网络拓扑的确定装置900的框图,如图41所示,该装置900可以包括:
获取模块901,用于获取用于组成网络的多个网元之间的连接关系和每个网元的网络层级,网络层级用于反映网元在网络中的重要程度。
第一确定模块902,用于基于多个网元之间的连接关系和每个网元的网络层级,分别确定多个子网络。
第二确定模块903,用于按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息。
建立模块904,用于基于多个网元之间的连接关系和每个网元的位置信息,建立网络拓扑。
可选地,第二确定模块903,用于:
对组成核心子网的多个核心网元进行排序,得到第一网元队列,核心网元为多个网元中具有最高网络层级的网元。
获取第一网元队列中相邻的每两个核心网元之间的第一间距。
基于第一间距和核心网元的总数,确定每个核心网元的位置信息。
可选地,多个核心网元布局在第一图形的边界上,第二确定模块903,用于基于第一间距和核心网元的总数,确定每个核心网元的位置信息时,具体用于:
基于核心网元的总数,确定第一图形的第一定长参数,第一定长参数用于反映第一图形上的点满足的几何特征。
按照每个核心网元在第一网元队列中的顺序,基于第一定长参数和第一间距,依次确定核心网元的位置信息。
可选地,第一图形包括:圆形、椭圆形或正多边形。
可选地,第二确定模块903,用于获取第一网元队列中相邻的每两个核心网元之间的第一间距时,具体用于:基于两个核心网元之间的下挂网元的第一总数,确定第一间距。
可选地,第一间距由两个核心网元中每个核心网元与指定点的连线之间的第一夹角表征,第二确定模块903用于基于两个核心网元之间的下挂网元的第一总数,确定第一间距时,具体用于:
确定第一总数在第二总数中的第一总数占比,第二总数为所有核心网元的下挂网元的总数。
将第一总数占比与360度的乘积确定为第一夹角。
可选地,第二确定模块903,用于:
基于网元之间的连接关系,将次级子网络的多个次级网元划分至多个第一网元组,次级 网元为多个网元中与核心网元直接连接的网元,核心网元为多个网元中具有最高网络层级的网元。
对每个第一网元组中至少一个次级网元进行排序,得到第二网元队列。
对多个第一网元组进行排序,得到网元组队列。
基于每个第一网元组中所有次级网元的下挂网元的第三总数,确定每个第一网元组的布局宽度。
基于每个第一网元组的布局宽度和任一第一网元组在网元组队列中的顺序,确定任一第一网元组的布局开始位置。
基于布局宽度、布局开始位置、多个第一网元组的总组数、第二网元队列、网元组队列和每个第一网元组中的次级网元的总数,确定每个次级网元的位置信息。
可选地,多个次级网元布局在至少一个第二图形的边界上,第二确定模块903用于基于布局宽度、布局开始位置、多个第一网元组的总组数、第二网元队列、网元组队列和每个第一网元组中的次级网元的总数,确定每个次级网元的位置信息时,具体用于:
基于每个次级网元所在的第一网元组在网元组队列中的顺序,确定每个次级网元所在的第二图形。
基于次级网元的总数和第一网元组的总组数,确定每个第二图形的第二定长参数,第二定长参数用于反映对应的第二图形上的点满足的几何特征。
按照每个次级网元在第二网元队列和网元组队列中的顺序,基于次级网元对应的第二定长参数、布局宽度,布局开始位置,及每个次级网元所在第一网元组中次级网元的总数,确定次级网元的位置信息。
可选地,每个第二图形均位于核心网元对应的第一图形的外部。
当至少一个第二图形为一个第二图形时,第二图形包括:圆形、椭圆形或正多边形。
当至少一个第二图形为多个第二图形时,多个第二图形构成的整体图形包括:同心圆形、同心椭圆形或同心正多边形。
可选地,第二确定模块903用于对多个第一网元组进行排序,得到网元组队列时,具体用于:
按照每个第一网元组对应的第三总数由大到小的顺序,对多个第一网元组进行初始排序,得到初始网元组队列。
按照每个第一网元组对应的目标距离由大到小的顺序,对初始网元组队列重新排序,得到网元组队列,目标距离为第一网元组在初始网元组队列中的位置到初始网元组队列的中心位置的距离。
可选地,每个第一网元组的布局宽度由第一网元组中位于最外侧的两个次级网元与指定点的连线之间的第二夹角表征,第二确定模块903用于基于每个第一网元组中所有次级网元的下挂网元的第三总数,确定每个第一网元组的布局宽度时,具体用于:
确定任一第一网元组对应的第三总数在第四总数中的第二总数占比,第四总数为多个第一网元组中所有次级网元的下挂网元的总数。
基于任一第一网元组对应的第二总数占比,确定任一第一网元组的第二夹角。
可选地,每个第一网元组的布局开始位置由布局开始角度表征,布局开始角度为布局开始位置与指定点的连线相对于指定0度的偏移角度,第二确定模块903用于基于每个第一网 元组的布局宽度和任一第一网元组在网元组队列中的顺序,确定任一第一网元组的布局开始位置时,具体用于:
基于任一第一网元组在网元组队列中的顺序,及在网元组队列中位于任一第一网元组之前的其他第一网元组的布局宽度,获取任一第一网元组的布局开始角度。
可选地,第二确定模块903,用于:
将至少一个环型子网划分至至少一个第二网元组,环型子网中的网元呈环状连接,属于环型子网的网元为环网元。
基于每个第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度。
确定任一环型子网的环网元对应的第三图形的图形参数,组成任一环型子网的环网元布局在对应的第三图形的边界上,图形参数用于反映对应的第三图形上的点满足的几何特征。
基于任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网中每个环网元的位置信息。
可选地,第二确定模块903用于基于任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网中每个环网元的位置信息时,具体用于:
基于任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,通过二分迭代算法获取任一环型子网中每个环网元在第一方向上的位置信息。
基于对应的图形参数和任一环网元在第一方向上的位置信息,确定任一环网元在第二方向上的位置信息。
可选地,第二确定模块903还用于:
基于任一第二网元组中每个环型子网的开始环网元和结束环网元的位置信息,对任一第二网元组中至少一个环型子网进行排序,得到第一网络队列。
相应的,第二确定模块903用于确定任一环型子网的环网元对应的第三图形的图形参数时,具体用于:
基于任一第二网元组中环型子网的开始环网元和结束环网元的位置信息,确定任一第二网元组的第一重心的位置信息。
基于任一第二网元组的第一重心的位置信息、任一环型子网的布局宽度、任一环型子网在第一网络队列中的顺序,及任一环型子网的环等级,确定与开始环网元直接连接的环网元和与结束环网元直接连接的环网元中的至少一个目标环网元的位置信息。
基于任一环型子网对应的目标环网元的位置信息和对应的第三图形所满足的函数关系,确定图形参数。
可选地,第二确定模块903用于基于任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网中每个环网元的位置信息时,具体用于:
基于任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网对应的第三图形坐标系。
基于任一环型子网对应的第六总数,及对应的第三图形坐标系和对应的图形参数,确定 任一环型子网中每个环网元的位置信息。
可选地,第二确定模块903用于基于任一环型子网对应的第六总数,及对应的第三图形坐标系和对应的图形参数,确定任一环型子网中每个环网元的位置信息时,具体用于:
基于任一环型子网对应的布局宽度、对应的第六总数、对应的图形参数,及任一环型子网中开始环网元和结束环网元之间的距离,在任一环型子网所包括的多个环网元中,确定作为任一环型子网的顶点的目标环网元。
基于任一环型子网对应的布局宽度,目标环网元在任一环型子网中多个环网元中的次序,任一环型子网中开始环网元和结束环网元之间的距离,任一环型子网对应的第三图形坐标系和对应的图形参数,确定每个环网元的位置信息。
可选地,第二确定模块903用于基于任一环型子网对应的布局宽度、对应的第六总数、对应的图形参数,及任一环型子网中开始环网元和结束环网元之间的距离,在任一环型子网所包括的多个环网元中,确定作为任一环型子网的顶点的目标环网元时,具体用于:
基于任一环型子网对应的图形参数和对应的布局宽度,及任一环型子网中开始环网元和结束环网元之间的距离,确定任一环型子网对应的第三图形的第一弧长和第二弧长,第一弧长和第二弧长分别为位于第三图形的顶点两侧的弧的长度。
基于任一环型子网对应的第一弧长和第二弧长,及任一环型子网对应的第六总数,确定作为任一环型子网的顶点的目标环网元。
可选地,第二确定模块903用于基于任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网对应的第三图形坐标系时,具体用于:
将任一环型子网的开始环网元和结束环网元的中点确定为任一环型子网对应的第三图形坐标系的坐标原点。
确定任一环型子网所在的第二网元组对应的参考图形,参考图形为以指定定长为半径,以对应的第三图形坐标系的坐标原点为圆心的圆。
确定任一环型子网对应的目标交点,目标交点为任一环型子网所在的第二网元组对应的参考图形与任一环型子网的第三连线的交点,任一环型子网的顶点与指定点位于第三连线上。
将对应的第三图形坐标系的坐标原点与目标交点的连线所在的方向确定为对应的第三图形坐标系的第二方向,将与第二方向垂直的方向确定为对应的第三图形坐标系的第一方向。
可选地,第二确定模块903用于基于任一环型子网的开始环网元和结束环网元的位置信息,确定任一环型子网对应的第三图形坐标系时,具体用于:
基于任一环型子网对应的图形参数,确定任一环型子网对应的第三图形的几何中心在第三图形中的第一相对位置。
基于任一环型子网对应的第一相对位置和对应的布局宽度,确定任一环型子网对应几何中心在任一环型子网所在的目标第二网元组中的第二相对位置。
基于任一环型子网对应的第二相对位置和归属点的位置信息,确定任一环型子网对应的几何中心的位置信息,归属点为目标第二网元组中至少一个环型子网中共同存在的环网元。
将任一环型子网对应的几何中心的位置信息确定为对应的第三图形坐标系的原点的位置信息,将任一环型子网对应的几何中心与对应的归属点的连线所在的方向确定为任一环型子网对应的第三图形坐标系的第一方向,将与第一方向垂直的方向确定为任一环型子网对应的第三图形坐标系的第二方向。
可选地,第二确定模块903用于确定任一环型子网的环网元对应的第三图形的图形参数时,具体用于:
基于任一环型子网对应的第六总数,估算任一环型子网对应的第三图形的第一周长。
基于任一环型子网对应的第三图形的周长公式,确定第三图形的第二周长。
基于第一周长和第二周长,获取任一环型子网对应的图形参数。
可选地,第二确定模块903用于基于第一周长和第二周长,获取任一环型子网对应的图形参数时,具体用于:
基于任一环型子网对应的第一周长和第二周长,获取任一环型子网对应的图形参数中的第一子参数。
基于任一环型子网对应的第一子参数,任一环型子网对应的布局宽度,及任一环型子网中开始环网元和结束环网元之间的距离,确定任一环型子网对应的图形参数中的其他子参数,得到任一环型子网对应的图形参数。
可选地,第二确定模块903用于将至少一个环型子网划分至至少一个第二网元组时,具体用于:
将具有相同开始环网元和相同结束环网元的环型子网划分至同一第二网元组,得到至少一个第二网元组。
可选地,第二确定模块903用于将至少一个环型子网划分至至少一个第二网元组时,具体用于:将环等级相同的环型子网划分至同一第二网元组,得到至少一个第二网元组。
可选地,任一环型子网的布局宽度由任一环型子网的第三夹角表征,第二确定模块903用于基于每个第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度时,具体用于:将180度与任一第二网元组对应的第五总数的商,确定为任一第二网元组中每个环型子网所占的第三夹角。
可选地,任一环型子网的布局宽度由任一环型子网的第三夹角表征,第二确定模块903用于基于每个第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度时,具体用于:
确定第一连线和第二连线所成的第四夹角,第一连线为任一第二网元组中开始环网元与指定点的连线,第二连线为任一第二网元组中结束环网元与指定点的连线。
将第四夹角与目标总数的商确定为任一第二网元组中每相邻两个环型子网的第三连线之间的第三夹角,环型子网的顶点与指定点位于第三连线上,目标总数等于任一第二网元组对应的第五总数减一。
可选地,任一环型子网的布局宽度由任一环型子网的第三夹角表征,第二确定模块903用于基于每个第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度时,具体用于:基于任一环型子网对应的第六总数,确定任一环型子网的布局宽度。
可选地,第二确定模块903,用于:
在组成树型子网的多个树网元中,确定第一根网元,树型子网中的网元呈树状连接,属于树型子网的网元为树网元。
获取每个树网元的布局开始位置和布局宽度。
基于任一其他树网元的布局开始位置和布局宽度,及第一根网元的位置信息,确定任一其他树网元的位置信息,其他树网元为多个树网元中除第一根网元外的树网元。
可选地,第二确定模块903还用于:
获取每个其他网元的深度。
第二确定模块903用于基于任一其他树网元的布局开始位置和布局宽度,及第一根网元的位置信息,确定任一其他树网元的位置信息时,具体用于:
基于任一其他树网元深度、布局开始位置和布局宽度,及第一根网元的位置信息,确定任一其他树网元的位置信息。
可选地,每个树网元的布局开始位置由布局开始角度表征,第二确定模块903用于获取每个树网元的布局开始位置时,具体用于:
基于第一根网元的位置信息,将第一根网元和指定点所在的直线确定为目标直线。
将目标射线与指定直线的夹角确定为第一根网元的布局开始角度,目标射线为垂直于目标直线,且发射方向背离指定点的射线。
或者,第一根网元的布局开始角度为-180度。
可选地,每个树网元的布局开始位置由布局开始角度表征,第二确定模块903用于获取每个树网元的布局开始位置时,具体用于:
根据树网元之间的连接关系,对与同一父网元连接的多个子网元进行排序,得到第三网元队列。
基于任一其他树网元所连接的父网元的布局开始角度、布局宽度和宽度,及在第三网元队列中顺序位于任一其他树网元之前的其他树网元的宽度,确定任一其他树网元的布局开始角度。
可选地,每个树网元的布局宽度由第五夹角表征,第二确定模块903用于获取每个树网元的布局宽度时,具体用于:
第一根网元的第五夹角为180度。
和/或,
根据树网元之间的连接关系,基于任一其他树网元的宽度,任一其他树网元所连接的父网元的第五夹角和宽度,确定任一其他树网元的第五夹角。
可选地,第二确定模块903,还用于:
对所有孤立树型子网中的第二根网元进行排序,得到第四网元队列,孤立树型子网中的网元呈树状连接,属于孤立树型子网的网元为孤立树网元,孤立树网元与核心网元之间不存在连接路径,核心网元为多个网元中具有最高网络层级的网元。
基于指定半径、所有第二根网元的宽度之和,及在第四网元队列中顺序位于任一第二根网元之前的其他第二根网元的宽度之和,确定任一第二根网元的位置信息。
可选地,每个树网元的布局开始位置由布局开始角度表征,第二确定模块903用于获取每个树网元的布局开始位置时,具体用于:基于在第四网元队列中顺序位于任一第二根网元之前的其他第二根网元的宽度,确定第二根网元的布局开始位置。
可选地,每个树网元的布局宽度由第五夹角表征,第二确定模块903获取每个树网元的布局宽度时,具体用于:
根据树网元之间的连接关系,获取每个树网元的宽度。
基于每个树网元的宽度,确定每个树网元的布局宽度。
可选地,与同一第一根网元连接的多个其他树网元布局在以第一根网元为圆心,以指定 长度为半径的圆上。
可选地,第二确定模块903,用于:
获取多个树型子网组成的整体网络的第二重心的位置信息。
获取每个树型子网的宽度。
按照每个树型子网的第三根网元的位置信息,对多个树型子网进行排序,得到第二网络队列。
基于每个树型子网的宽度,第二重心的位置信息,及在第二网络队列中顺序位于任一树型子网之前的其他树型子网的宽度,确定任一树型子网的第三根网元的位置信息。
根据树网元之间的连接关系,对与同一父网元连接的多个子网元进行排序,得到第五网元队列。
基于任一其他树网元所连接的父网元的位置信息,任一其他树网元的宽度,及在第五网元队列中顺序位于任一其他树网元之前的其他树网元的位置信息和宽度,确定任一其他树网元的位置信息。
可选地,第一确定模块902,用于:将由核心网元连接组成的网络确定为核心子网络,核心网元为具有最高网络层级的网元。
可选地,第一确定模块902,用于:
将呈环状连接的其他网元组成的网络确定为环型子网络,其他网元为网络中除核心网元外的网元。
和/或,将呈树型连接的其他网元组成的网络确定为树型子网。
可选地,网络拓扑中的网元以具有最高网络层级的网元为起点,按照网络层级由高到低的顺序由内向外分布。
可选地,网络拓扑中的网元以具有最高网络层级的网元为起点,按照网络层级由高到低的顺序自上向下分布。
综上所述,本申请提供了一种网络拓扑的确定装置,通过第一确定模块基于多个网元之间的连接关系和每个网元的网络层级,分别确定多个子网络,第二确定模块按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息,并基于多个网元之间的连接关系和每个网元的位置信息,建立网络拓扑,相较于相关技术,能够自动地获取网元的位置信息,无需手动对网络拓扑进行调整,有效地提高了获取网络拓扑的效率。还能够有效地减少网络拓扑中的链路交叉,且无需预置网元的初始位置,使得获取的网络拓扑的结果唯一,且获取的网络拓扑能够较清楚地呈现网络的结构、网元的网络层级及不同子网之间的关系。并且,由于在确定网元的位置信息时,采用的图形均为具有较好对称性的图形,使得获取的网络拓扑具有较好的对称性。同时,在该计算网元的位置信息的过程中,通过采用定积分、二分迭代、图形参数求解以及坐标变换等方式简化计算量,能够减少确定网元位置信息的耗时,解决了相关中算法不收敛和效率低的问题。
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的装置、模块和子模块的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
以上装置中的各个模块可以通过软件或硬件或软硬件结合的方式来实现。当至少一个模块是硬件的时候,该硬件可以是逻辑集成电路模块,可具体包括晶体管、逻辑门阵列或算法逻辑电路等。至少一个模块是软件的时候,该软件以计算机程序产品形式存在,并被存储于 计算机可读存储介质中。该软件可以被一个处理器执行,也即是,在该软件对应的计算机程序产品被运行时,该软件被执行,以实现前述各个模块的功能。因此可替换地,网络拓扑的确定装置可以由一个处理器执行软件程序来实现,本实施例对此不限定。
本申请示例性实施例还提供了一种网络拓扑的确定装置。示例地,该网络拓扑的确定装置可以为终端。该网络拓扑的确定装置包括:处理器和存储器。在处理器执行存储器存储的计算机程序时,网络拓扑的确定装置执行本申请实施例提供的网络拓扑的确定方法。例如:处理器被配置为:获取用于组成网络的多个网元之间的连接关系和每个网元的网络层级,网络层级用于反映网元在网络中的重要程度;基于多个网元之间的连接关系和每个网元的网络层级,分别确定多个子网络;按照网络中网元的网络层级由高到低的顺序,基于每个子网络中各个网元之间的连接关系,确定每个网元的位置信息;基于多个网元之间的连接关系和每个网元的位置信息,建立网络拓扑。
示例地,请参考图42,其示出了本申请示例性实施例涉及的一种网络拓扑的确定装置20的结构示意图,该网络拓扑的确定装置20可以包括:处理器22和信号接口24。
处理器22包括一个或者一个以上处理核心。处理器22通过运行软件程序以及模块,从而执行各种功能应用以及数据处理。处理器22可以是通用处理器,例如,中央处理器(central processing unit,CPU),转发芯片,或者CPU与转发芯片的组合。或者,上述处理器也可以是硬件芯片,该硬件芯片可以是专用集成电路(application-specific integrated circuit,ASIC),可编程逻辑器件(programmable logic device,PLD)或其组合。上述PLD可以是复杂可编程逻辑器件(complex programmable logic device,CPLD),现场可编程门阵列(field-programmable gate array,FPGA),通用阵列逻辑(generic array logic,GAL)或其任意组合。其中,上述转发芯片可以包括网络处理器(network processor,NP),FPGA或ASIC。
信号接口24可以为多个,该信号接口24用于与其它装置或模块建立连接,例如:可以通过该信号接口24与收发机进行连接。因此,可选地,该装置20还可包括所述收发机(图中未示出)。该收发机具体执行信号收发。当处理器22需要执行信号收发操作的时候可以调用或驱动收发机执行相应收发操作。因此,当装置20进行信号收发的时候,处理器22用于决定或发起收发操作,相当于发起者,而收发机用于具体收发执行,相当于执行者。该收发机也可以是收发电路、射频电路或射频单元,本实施例对此不限定。
可选的,网络拓扑的确定装置20还包括存储器26、总线28等部件。其中,存储器26与信号接口24分别通过总线28与处理器22相连。
存储器26可用于存储软件程序以及模块。具体的,存储器26可存储至少一个功能所需的程序模块262,该程序可以是应用程序或驱动程序。
其中,该程序模块262可以包括:
获取单元2621,具有与获取模块901相同或相似的功能。
第一确定单元2622,具有与第一确定模块902相同或相似的功能。
第二确定单元2623,具有与第二确定模块903相同或相似的功能。
建立单元2624,具有与建立模块904相同或相似的功能。
本申请实施例还提供了一种存储介质,该存储介质可以为非易失性计算机可读存储介质, 存储介质内存储有计算机程序,该计算机程序指示网络拓扑的确定装置执行本申请实施例提供的任一的网络拓扑的确定方法。该存储介质可以包括:只读存储器(read-only memory,ROM)或随机存取存储器(random access memory,RAM)、磁碟或者光盘等各种可存储程序代码的介质。
本申请实施例还提供了一种包含指令的计算机程序产品,当计算机程序产品在计算机上运行时,使得计算机执行本申请实施例提供的网络拓扑的确定方法。该计算机程序产品可以包括一个或多个计算机指令。在计算机上加载和执行该计算机程序指令时,全部或部分地产生按照本申请实施例所述的流程或功能。该计算机可以是通用计算机、专用计算机、计算机网络、或者其他可编程装置。该计算机指令可以存储在计算机可读存储介质中,或者通过该计算机可读存储介质进行传输。该计算机可读存储介质可以是计算机能够存取的任何可用介质或者是包含一个或多个可用介质集成的服务器、数据中心等数据存储设备。该可用介质可以是磁性介质,(例如,软盘、硬盘、磁带)、光介质(例如,DVD)、或者半导体介质(例如,固态硬盘(solid state disk,SSD))等。
本领域普通技术人员可以理解实现上述实施例的全部或部分步骤可以通过硬件来完成,也可以通过程序来指令相关的硬件完成,所述的程序可以存储于一种计算机可读存储介质中,上述提到的存储介质可以是只读存储器,磁盘或光盘等。
以上所述仅为本申请的可选实施例,并不用以限制本申请,凡在本申请的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本申请的保护范围之内。
Claims (30)
- 一种网络拓扑的确定装置,其特征在于,所述装置包括:获取模块,用于获取用于组成网络的多个网元之间的连接关系和每个所述网元的网络层级,所述网络层级用于反映所述网元在所述网络中的重要程度;第一确定模块,用于基于所述多个网元之间的连接关系和每个所述网元的网络层级,分别确定多个子网络;第二确定模块,用于按照所述网络中网元的网络层级由高到低的顺序,基于每个所述子网络中各个网元之间的连接关系,确定每个所述网元的位置信息;建立模块,用于基于所述多个网元之间的连接关系和每个所述网元的位置信息,建立所述网络拓扑。
- 根据权利要求1所述的装置,其特征在于,所述第二确定模块,用于:对组成核心子网的多个核心网元进行排序,得到第一网元队列,所述核心网元为所述多个网元中具有最高网络层级的网元;获取所述第一网元队列中相邻的每两个核心网元之间的第一间距;基于所述第一间距和核心网元的总数,确定每个所述核心网元的位置信息。
- 根据权利要求2所述的装置,其特征在于,所述多个核心网元布局在第一图形的边界上,所述第二确定模块用于基于所述第一间距和核心网元的总数,确定每个所述核心网元的位置信息时,具体用于:基于所述核心网元的总数,确定所述第一图形的第一定长参数,所述第一定长参数用于反映所述第一图形上的点满足的几何特征;按照每个所述核心网元在所述第一网元队列中的顺序,基于所述第一定长参数和所述第一间距,依次确定所述核心网元的位置信息。
- 根据权利要求2至3任一所述的装置,其特征在于,所述第二确定模块用于获取所述第一网元队列中相邻的每两个核心网元之间的第一间距时,具体用于:基于所述两个核心网元之间的下挂网元的第一总数,确定所述第一间距。
- 根据权利要求4所述的装置,其特征在于,所述第一间距由所述两个核心网元中每个核心网元与指定点的连线之间的第一夹角表征,所述第二确定模块用于基于所述两个核心网元之间的下挂网元的第一总数,确定所述第一间距时,具体用于:确定所述第一总数在第二总数中的第一总数占比,所述第二总数为所有核心网元的下挂网元的总数;将所述第一总数占比与360度的乘积确定为所述第一夹角。
- 根据权利要求1至5任一所述的装置,其特征在于,所述第二确定模块,用于:基于网元之间的连接关系,将次级子网络的多个次级网元划分至多个第一网元组,所述次级网元为所述多个网元中与核心网元直接连接的网元,所述核心网元为所述多个网元中具有最高网络层级的网元;对每个所述第一网元组中至少一个次级网元进行排序,得到第二网元队列;对所述多个第一网元组进行排序,得到网元组队列;基于每个所述第一网元组中所有次级网元的下挂网元的第三总数,确定每个所述第一网元组的布局宽度;基于每个所述第一网元组的布局宽度和任一第一网元组在所述网元组队列中的顺序,确定所述任一第一网元组的布局开始位置;基于所述布局宽度、所述布局开始位置、所述多个第一网元组的总组数、所述第二网元队列、所述网元组队列和每个所述第一网元组中的次级网元的总数,确定每个所述次级网元的位置信息。
- 根据权利要求6所述的装置,其特征在于,所述多个次级网元布局在至少一个第二图形的边界上,所述第二确定模块用于基于所述布局宽度、所述布局开始位置、所述多个第一网元组的总组数、所述第二网元队列、所述网元组队列和每个所述第一网元组中的次级网元的总数,确定每个所述次级网元的位置信息时,具体用于:基于每个所述次级网元所在的第一网元组在所述网元组队列中的顺序,确定每个所述次级网元所在的第二图形;基于所述次级网元的总数和所述第一网元组的总组数,确定每个所述第二图形的第二定长参数,所述第二定长参数用于反映对应的第二图形上的点满足的几何特征;按照每个所述次级网元在所述第二网元队列和所述网元组队列中的顺序,基于所述次级网元对应的第二定长参数、所述布局宽度,所述布局开始位置,及每个所述次级网元所在第一网元组中次级网元的总数,确定所述次级网元的位置信息。
- 根据权利要求6或7所述的装置,其特征在于,每个所述第一网元组的布局宽度由所述第一网元组中位于最外侧的两个次级网元与指定点的连线之间的第二夹角表征,所述第二确定模块用于基于每个所述第一网元组中所有次级网元的下挂网元的第三总数,确定每个所述第一网元组的布局宽度时,具体用于:确定任一第一网元组对应的第三总数在第四总数中的第二总数占比,所述第四总数为所述多个第一网元组中所有次级网元的下挂网元的总数;基于所述任一第一网元组对应的第二总数占比,确定所述任一第一网元组的第二夹角。
- 根据权利要求6至8任一所述的装置,其特征在于,每个所述第一网元组的布局开始位置由布局开始角度表征,所述布局开始角度为所述布局开始位置与指定点的连线相对于指定0度的偏移角度,所述第二确定模块用于基于每个所述第一网元组的布局宽度和任一第一网元组在所述网元组队列中的顺序,确定所述任一第一网元组的布局开始位置时,具体用于:基于所述任一第一网元组在所述网元组队列中的顺序,及在所述网元组队列中位于所述 任一第一网元组之前的其他第一网元组的布局宽度,获取所述任一第一网元组的布局开始角度。
- 根据权利要求1至9任一所述的装置,其特征在于,所述第二确定模块,用于:将至少一个环型子网划分至至少一个第二网元组,所述环型子网中的网元呈环状连接,属于所述环型子网的网元为环网元;基于每个所述第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度;确定所述任一环型子网的环网元对应的第三图形的图形参数,组成所述任一环型子网的环网元布局在所述对应的第三图形的边界上,所述图形参数用于反映对应的第三图形上的点满足的几何特征;基于所述任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及所述任一环型子网的开始环网元和结束环网元的位置信息,确定所述任一环型子网中每个所述环网元的位置信息。
- 根据权利要求10所述的装置,其特征在于,所述第二确定模块用于基于所述任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及所述任一环型子网的开始环网元和结束环网元的位置信息,确定所述任一环型子网中每个所述环网元的位置信息时,具体用于:基于所述任一环型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及所述任一环型子网的开始环网元和结束环网元的位置信息,通过二分迭代算法获取所述任一环型子网中每个所述环网元在第一方向上的位置信息;基于所述对应的图形参数和任一环网元在所述第一方向上的位置信息,确定所述任一环网元在第二方向上的位置信息,所述第二方向与所述第一方向垂直。
- 根据权利要求10或11所述的装置,其特征在于,所述第二确定模块还用于:基于任一第二网元组中每个环型子网的开始环网元和结束环网元的位置信息,对所述任一第二网元组中至少一个环型子网进行排序,得到第一网络队列;所述第二确定模块用于确定所述任一环型子网的环网元对应的第三图形的图形参数时,具体用于:基于任一第二网元组中环型子网的开始环网元和结束环网元的位置信息,确定所述任一第二网元组的第一重心的位置信息;基于所述任一第二网元组的第一重心的位置信息、所述任一环型子网的布局宽度、所述任一环型子网在所述第一网络队列中的顺序,及所述任一环型子网的环等级,确定与所述开始环网元直接连接的环网元和与所述结束环网元直接连接的环网元中的至少一个目标环网元的位置信息;基于所述任一环型子网对应的目标环网元的位置信息和对应的第三图形所满足的函数关系,确定所述图形参数。
- 根据权利要求10所述的装置,其特征在于,所述第二确定模块用于基于所述任一环 型子网中下挂网元的第六总数,对应的图形参数,对应的布局宽度,及所述任一环型子网的开始环网元和结束环网元的位置信息,确定所述任一环型子网中每个所述环网元的位置信息时,具体用于:基于所述任一环型子网的开始环网元和结束环网元的位置信息,确定所述任一环型子网对应的第三图形坐标系;基于所述任一环型子网对应的第六总数,及对应的第三图形坐标系和对应的图形参数,确定每所述任一环型子网中每个所述环网元的位置信息。
- 根据权利要求13所述的装置,其特征在于,所述第二确定模块用于基于所述任一环型子网对应的第六总数,及对应的第三图形坐标系和对应的图形参数,确定每所述任一环型子网中每个所述环网元的位置信息时,具体用于:基于所述任一环型子网对应的布局宽度、对应的第六总数、对应的图形参数,及所述任一环型子网中开始环网元和结束环网元之间的距离,在所述任一环型子网所包括的多个环网元中,确定作为所述任一环型子网的顶点的目标环网元;基于所述任一环型子网对应的布局宽度,所述目标环网元在所述任一环型子网中多个环网元中的次序,所述任一环型子网中开始环网元和结束环网元之间的距离,所述任一环型子网对应的第三图形坐标系和对应的图形参数,确定每个所述环网元的位置信息。
- 根据权利要求10或13所述的装置,其特征在于,所述任一环型子网的布局宽度由所述任一环型子网的第三夹角表征,所述第二确定模块用于基于每个所述第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度时,具体用于:将180度与任一第二网元组对应的第五总数的商,确定为所述任一第二网元组中每个所述环型子网所占的第三夹角。
- 根据权利要求10或13所述的装置,其特征在于,所述任一环型子网的布局宽度由所述任一环型子网的第三夹角表征,所述第二确定模块用于基于每个所述第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度时,具体用于:确定第一连线和第二连线所成的第四夹角,所述第一连线为所述任一第二网元组中开始环网元与指定点的连线,所述第二连线为所述任一第二网元组中结束环网元与所述指定点的连线;将所述第四夹角与目标总数的商确定为所述任一第二网元组中每相邻两个所述环型子网的第三连线之间的第三夹角,所述环型子网的顶点与所述指定点位于所述第三连线上,所述目标总数等于所述任一第二网元组对应的第五总数减一。
- 根据权利要求10至12所述的装置,其特征在于,所述任一环型子网的布局宽度由所述任一环型子网的第三夹角表征,所述第二确定模块用于基于每个所述第二网元组中环型子网的第五总数,确定任一环型子网的布局宽度时,具体用于:基于任一环型子网对应的第六总数,确定所述任一环型子网的布局宽度。
- 根据权利要求1至17任一所述的装置,其特征在于,所述第二确定模块,用于:在组成树型子网的多个树网元中,确定第一根网元,所述树型子网中的网元呈树状连接,属于所述树型子网的网元为树网元;获取每个所述树网元的布局开始位置和布局宽度;基于任一其他树网元的布局开始位置和布局宽度,及所述第一根网元的位置信息,确定所述任一其他树网元的位置信息,所述其他树网元为所述多个树网元中除所述第一根网元外的树网元。
- 根据权利要求18所述的装置,其特征在于,所述第二确定模块还用于:获取每个所述其他网元的深度;所述第二确定模块用于基于任一其他树网元的布局开始位置和布局宽度,及所述第一根网元的位置信息,确定所述任一其他树网元的位置信息时,具体用于:基于所述任一其他树网元深度、布局开始位置和布局宽度,及所述第一根网元的位置信息,确定所述任一其他树网元的位置信息。
- 根据权利要求18或19所述的装置,其特征在于,每个所述树网元的布局开始位置由布局开始角度表征,所述第二确定模块用于获取每个所述树网元的布局开始位置时,具体用于:基于所述第一根网元的位置信息,将所述第一根网元和指定点所在的直线确定为目标直线;将目标射线与指定直线的夹角确定为所述第一根网元的布局开始角度,所述目标射线为垂直于所述目标直线,且发射方向背离所述指定点的射线;或者,所述第一根网元的布局开始角度为-180度。
- 根据权利要求18至20任一所述的装置,其特征在于,每个所述树网元的布局开始位置由布局开始角度表征,所述第二确定模块用于获取每个所述树网元的布局开始位置时,具体用于:根据树网元之间的连接关系,对与同一父网元连接的多个子网元进行排序,得到第三网元队列;基于任一其他树网元所连接的父网元的布局开始角度、布局宽度和宽度,及在所述第三网元队列中顺序位于所述任一其他树网元之前的其他树网元的宽度,确定所述任一其他树网元的布局开始角度。
- 根据权利要求18至21任一所述的装置,其特征在于,所述第二确定模块,还用于:对所有孤立树型子网中的第二根网元进行排序,得到第四网元队列,所述孤立树型子网中的网元呈树状连接,属于所述孤立树型子网的网元为孤立树网元,所述孤立树网元与核心网元之间不存在连接路径,所述核心网元为所述多个网元中具有最高网络层级的网元;基于指定半径、所有第二根网元的宽度之和,及在所述第四网元队列中顺序位于所述任一第二根网元之前的其他第二根网元的宽度之和,确定所述任一第二根网元的位置信息。
- 根据权利要求22所述的装置,其特征在于,每个所述树网元的布局开始位置由布局开始角度表征,所述第二确定模块用于获取每个所述树网元的布局开始位置时,具体用于:基于在所述第四网元队列中顺序位于所述任一第二根网元之前的其他第二根网元的宽度,确定所述第二根网元的布局开始位置。
- 根据权利要求22或23所述的装置,其特征在于,每个所述树网元的布局宽度由第五夹角表征,所述第二确定模块获取每个所述树网元的布局宽度时,具体用于:根据树网元之间的连接关系,获取每个所述树网元的宽度;基于每个所述树网元的宽度,确定每个所述树网元的布局宽度。
- 根据权利要求1至24任一所述的装置,其特征在于,所述第二确定模块,用于:获取多个树型子网组成的整体网络的第二重心的位置信息;获取每个所述树型子网的宽度;按照每个所述树型子网的第三根网元的位置信息,对多个所述树型子网进行排序,得到第二网络队列;基于每个所述树型子网的宽度,所述第二重心的位置信息,及在所述第二网络队列中顺序位于任一树型子网之前的其他树型子网的宽度,确定所述任一树型子网的第三根网元的位置信息;根据树网元之间的连接关系,对与同一父网元连接的多个子网元进行排序,得到第五网元队列;基于任一其他树网元所连接的父网元的位置信息,所述任一其他树网元的宽度,及在所述第五网元队列中顺序位于所述任一其他树网元之前的其他树网元的位置信息和宽度,确定所述任一其他树网元的位置信息。
- 根据权利要求1至25任一所述的装置,其特征在于,所述第一确定模块,用于:将由核心网元连接组成的网络确定为核心子网络,所述核心网元为具有最高网络层级的网元。
- 根据权利要求26所述的装置,其特征在于,所述第一确定模块,用于:将呈环状连接的其他网元组成的网络确定为环型子网络,所述其他网元为所述网络中除所述核心网元外的网元;和/或,将呈树型连接的其他网元组成的网络确定为树型子网。
- 根据权利要求1至27任一所述的装置,其特征在于,所述网络拓扑中的网元以具有最高网络层级的网元为起点,按照网络层级由高到低的顺序由内向外分布。
- 根据权利要求1至27任一所述的装置,其特征在于,所述网络拓扑中的网元以具有最高网络层级的网元为起点,按照网络层级由高到低的顺序自上向下分布。
- 一种网络拓扑的确定方法,其特征在于,所述方法包括:获取用于组成网络的多个网元之间的连接关系和每个所述网元的网络层级,所述网络层级用于反映所述网元在所述网络中的重要程度;基于所述多个网元之间的连接关系和每个所述网元的网络层级,分别确定多个子网络;按照所述网络中网元的网络层级由高到低的顺序,基于每个所述子网络中各个网元之间的连接关系,确定每个所述网元的位置信息;基于所述多个网元之间的连接关系和每个所述网元的位置信息,建立所述网络拓扑。
Priority Applications (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| EP19902285.6A EP3869738A4 (en) | 2018-12-27 | 2019-12-19 | METHOD AND APPARATUS FOR DETERMINING NETWORK AND SYSTEM TOPOLOGY |
| US17/337,694 US11929905B2 (en) | 2018-12-27 | 2021-06-03 | Network topology determining method and apparatus, and system |
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201811613944.0 | 2018-12-27 | ||
| CN201811613944.0A CN109842520B (zh) | 2018-12-27 | 2018-12-27 | 网络拓扑的确定方法、装置及系统 |
Related Child Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| US17/337,694 Continuation US11929905B2 (en) | 2018-12-27 | 2021-06-03 | Network topology determining method and apparatus, and system |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2020135218A1 true WO2020135218A1 (zh) | 2020-07-02 |
Family
ID=66883458
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2019/126612 Ceased WO2020135218A1 (zh) | 2018-12-27 | 2019-12-19 | 网络拓扑的确定方法、装置及系统 |
Country Status (4)
| Country | Link |
|---|---|
| US (1) | US11929905B2 (zh) |
| EP (1) | EP3869738A4 (zh) |
| CN (1) | CN109842520B (zh) |
| WO (1) | WO2020135218A1 (zh) |
Cited By (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN113934341A (zh) * | 2021-10-20 | 2022-01-14 | 迈普通信技术股份有限公司 | 网络策略拓扑的显示方法、装置、电子设备及存储介质 |
| CN114641020A (zh) * | 2020-12-15 | 2022-06-17 | 中国联合网络通信集团有限公司 | 应用于无线接入网ip化网络的预警方法、装置和设备 |
| WO2022253058A1 (zh) * | 2021-05-31 | 2022-12-08 | 华为技术有限公司 | 一种网络拓扑展示方法以及通信装置 |
Families Citing this family (12)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN109842520B (zh) * | 2018-12-27 | 2021-06-22 | 华为技术有限公司 | 网络拓扑的确定方法、装置及系统 |
| CN112511321B (zh) * | 2019-09-16 | 2021-12-10 | 大唐移动通信设备有限公司 | 一种配置5g核心网的方法及装置 |
| CN110611591B (zh) * | 2019-09-18 | 2022-09-09 | 重庆特斯联智慧科技股份有限公司 | 一种网络拓扑建立方法及装置 |
| CN110958144B (zh) * | 2019-11-29 | 2021-06-22 | 腾讯科技(深圳)有限公司 | 获取网络的方法及装置 |
| CN111210017B (zh) * | 2019-12-24 | 2023-09-26 | 北京迈格威科技有限公司 | 确定布局顺序及数据处理的方法、装置、设备及存储介质 |
| CN113572624B (zh) * | 2020-04-28 | 2023-07-14 | 中国移动通信集团浙江有限公司 | 一种基于dran的传输接入层规划方法及装置 |
| CN113746652B (zh) * | 2020-05-29 | 2023-12-19 | 华为技术服务有限公司 | 确定主备保护对的方法及装置 |
| CN113904738B (zh) * | 2020-07-06 | 2025-07-18 | 北京佰才邦技术股份有限公司 | 分布式多输入多输出下天线校准时频资源调度方法及设备 |
| CN111865701B (zh) * | 2020-08-03 | 2023-08-11 | 北京知道创宇信息技术股份有限公司 | 资产确定方法、装置、电子设备及存储介质 |
| CN116192562A (zh) * | 2022-11-02 | 2023-05-30 | 浪潮通信信息系统有限公司 | 基于传输环网的串接方法及系统 |
| CN116055334B (zh) * | 2023-01-13 | 2024-04-19 | 中国联合网络通信集团有限公司 | 一种网络布局方法、装置、电子设备及存储介质 |
| CN119583434A (zh) * | 2025-02-10 | 2025-03-07 | 山东云海国创云计算装备产业创新中心有限公司 | 网络拓扑结构及网络拓扑结构的构建系统 |
Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN102143007A (zh) * | 2011-05-03 | 2011-08-03 | 中国南方电网有限责任公司 | 基于分布式的多级网络拓扑发现方法 |
| CN103634147A (zh) * | 2013-11-28 | 2014-03-12 | 华为技术服务有限公司 | 一种网络拓扑管理方法及设备 |
| US20170208377A1 (en) * | 2016-01-19 | 2017-07-20 | Infinera Corporation | System and method for virtual network topologies and vpn in multi-layer networks |
| CN108055207A (zh) * | 2017-10-26 | 2018-05-18 | 北京天元创新科技有限公司 | 一种网络拓扑感知方法及装置 |
| CN109842520A (zh) * | 2018-12-27 | 2019-06-04 | 华为技术服务有限公司 | 网络拓扑的确定方法、装置及系统 |
Family Cites Families (14)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20070201384A1 (en) * | 2006-02-28 | 2007-08-30 | Microsoft Corporation | Network explorer |
| CA2669435A1 (en) * | 2008-06-18 | 2009-12-18 | Solana Networks Inc. | Method and system for network topology discovery |
| CN101754055A (zh) * | 2008-12-05 | 2010-06-23 | 华为技术有限公司 | 网元标识自动设置方法、标识管理服务器及代理网元 |
| CN101483935B (zh) * | 2008-12-19 | 2011-11-16 | 北京邮电大学 | 无线自组织网络的拓扑绘制算法 |
| EP2394392B1 (en) * | 2009-02-05 | 2019-04-10 | Telefonaktiebolaget LM Ericsson (publ) | Topological location discovery in an ethernet network |
| US8923113B2 (en) * | 2012-06-27 | 2014-12-30 | Cisco Technology, Inc. | Optimizations in multi-destination tree calculations for layer 2 link state protocols |
| CN103580897A (zh) * | 2012-07-31 | 2014-02-12 | 华为技术有限公司 | 生成网络拓扑图的方法及装置 |
| US9025469B2 (en) * | 2013-03-15 | 2015-05-05 | Arris Technology, Inc. | Method for estimating cable plant topology |
| CN103475513A (zh) * | 2013-09-02 | 2013-12-25 | 华为技术有限公司 | 基于位置信息的拓扑信息处理方法、装置及系统 |
| CN103533102B (zh) * | 2013-10-25 | 2017-06-06 | 深圳市多尼卡电子技术有限公司 | 网元网络地址的配置方法及数据传输系统和音视频系统 |
| CN104125154B (zh) * | 2014-08-12 | 2017-09-26 | 华为技术有限公司 | 网络拓扑发现方法和设备 |
| CN105634763B (zh) * | 2014-10-28 | 2019-02-26 | 中国移动通信集团北京有限公司 | 一种传输网络拓扑结构图形的呈现方法及装置 |
| CN105991334B (zh) * | 2015-02-28 | 2019-07-05 | 中国移动通信集团广西有限公司 | 一种网络拓扑自发现方法及装置 |
| CN108880899B (zh) * | 2018-06-30 | 2021-10-15 | 华为技术有限公司 | 一种网络拓扑图生成方法及服务器 |
-
2018
- 2018-12-27 CN CN201811613944.0A patent/CN109842520B/zh active Active
-
2019
- 2019-12-19 WO PCT/CN2019/126612 patent/WO2020135218A1/zh not_active Ceased
- 2019-12-19 EP EP19902285.6A patent/EP3869738A4/en active Pending
-
2021
- 2021-06-03 US US17/337,694 patent/US11929905B2/en active Active
Patent Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN102143007A (zh) * | 2011-05-03 | 2011-08-03 | 中国南方电网有限责任公司 | 基于分布式的多级网络拓扑发现方法 |
| CN103634147A (zh) * | 2013-11-28 | 2014-03-12 | 华为技术服务有限公司 | 一种网络拓扑管理方法及设备 |
| US20170208377A1 (en) * | 2016-01-19 | 2017-07-20 | Infinera Corporation | System and method for virtual network topologies and vpn in multi-layer networks |
| CN108055207A (zh) * | 2017-10-26 | 2018-05-18 | 北京天元创新科技有限公司 | 一种网络拓扑感知方法及装置 |
| CN109842520A (zh) * | 2018-12-27 | 2019-06-04 | 华为技术服务有限公司 | 网络拓扑的确定方法、装置及系统 |
Non-Patent Citations (1)
| Title |
|---|
| See also references of EP3869738A4 |
Cited By (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN114641020A (zh) * | 2020-12-15 | 2022-06-17 | 中国联合网络通信集团有限公司 | 应用于无线接入网ip化网络的预警方法、装置和设备 |
| CN114641020B (zh) * | 2020-12-15 | 2023-08-01 | 中国联合网络通信集团有限公司 | 应用于无线接入网ip化网络的预警方法、装置和设备 |
| WO2022253058A1 (zh) * | 2021-05-31 | 2022-12-08 | 华为技术有限公司 | 一种网络拓扑展示方法以及通信装置 |
| CN113934341A (zh) * | 2021-10-20 | 2022-01-14 | 迈普通信技术股份有限公司 | 网络策略拓扑的显示方法、装置、电子设备及存储介质 |
| CN113934341B (zh) * | 2021-10-20 | 2024-04-09 | 迈普通信技术股份有限公司 | 网络策略拓扑的显示方法、装置、电子设备及存储介质 |
Also Published As
| Publication number | Publication date |
|---|---|
| CN109842520A (zh) | 2019-06-04 |
| US11929905B2 (en) | 2024-03-12 |
| EP3869738A1 (en) | 2021-08-25 |
| US20210297338A1 (en) | 2021-09-23 |
| EP3869738A4 (en) | 2022-01-19 |
| CN109842520B (zh) | 2021-06-22 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN109842520B (zh) | 网络拓扑的确定方法、装置及系统 | |
| CN109451540B (zh) | 一种网络切片的资源分配方法和设备 | |
| Halldórsson et al. | Minimizing interference of a wireless ad-hoc network in a plane | |
| CN108574970A (zh) | 父节点选择方法及网络节点 | |
| CN113160235B (zh) | 一种基于内部圆和邻接图的房间分割方法 | |
| CN112258515B (zh) | 一种基于固定顶点的图分割方法 | |
| CN102193998B (zh) | 一种含边拓扑信息的不规则三角网弧扫式构建方案 | |
| CN107750056B (zh) | 超密集网络中的干扰消减方法 | |
| CN113709754B (zh) | 基于聚类算法的无线宽带通信系统布站组网方法及系统 | |
| US12488521B2 (en) | Force-directed graph layout method and apparatus, electronic device, and storage medium | |
| CN105722091A (zh) | 无线可充电传感网络的定向充电基站部署方法 | |
| CN111181792B (zh) | 基于网络拓扑的sdn控制器部署方法、装置及电子设备 | |
| CN114070773B (zh) | 一种基于最短路径长度的空间网络路由策略 | |
| CN106652036B (zh) | 面向高效渲染的二维三角网格生成方法 | |
| CN110084355B (zh) | 大量相互作用粒子运动仿真系统的网格尺度寻优方法 | |
| CN107391247B (zh) | 一种片上网络应用的广度优先贪心映射方法 | |
| CN105978740A (zh) | 一种在软件定义网络中部署控制器的方法 | |
| CN108509532A (zh) | 一种应用于地图的聚点方法和装置 | |
| CN109525407B (zh) | 一种同层无交集全覆盖嵌套容器生成方法及可读存储介质 | |
| CN110110736A (zh) | 增量聚类方法和装置 | |
| CN106162668A (zh) | 确定网络参数的方法和装置 | |
| CN114416329A (zh) | 计算任务部署方法、装置、电子设备及存储介质 | |
| CN119995183A (zh) | 无线电能传输网中能量传输路径的构建与优化方法 | |
| CN113014302A (zh) | 一种面向卫星网络的网络功能服务链部署方法 | |
| WO2020043120A1 (zh) | 一种在网络中划分内部网关协议区域的方法和装置 |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 19902285 Country of ref document: EP Kind code of ref document: A1 |
|
| ENP | Entry into the national phase |
Ref document number: 2019902285 Country of ref document: EP Effective date: 20210520 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |



























