Inquiry minimum range and the dynamic monitoring and controlling method and system of position
Technical field
The present invention relates to the dynamic monitoring and controlling method and system of a kind of inquiry minimum range and position.
Background technology
In the past few years, have the class of many work sutdies one in the case where there is client's point set " facility place ask
Topic "(Referring to document 8:Farahani,R.Z.,Hekmatfar,M.:Facility Location:Concepts,Models,
Algorithms and Case Studies, 1st edn.Physica-Verlag HD (2009), document 15:Nickel,S.,
Puerto,J.:Location Theory:A Unified Approach,1st edn.Springer(2005)).Most universal
In the case of, problem is included:(1)The set C of one client's point and facility point candidate collection P, and(2)K is inquired about in P
The position of new facility point is so as to meeting the optimum condition of a predefined.Such issues that in the case where k is constant exist it is many
Algorithm in the item formula time, is NP-hard problems in the case where k is general variance(Referring to document 8 and 15), existed
Its approximate data is mainly studied in work.
Optimum position inquiry problem can be seen as a mutation of facility Placement Problems, and P first is a unlimited set;
Then usual k=1, that is to say, that only need to carry out chosen position for a newly-built facility point;Finally generally have one in advance
Individual facility point set F.The above is difference of the optimum position inquiry problem relative to general " facility Placement Problems ".
The research work of problem is inquired about in optimum position before(Referring to document 2:Cabello,S.,
J.M.,Langerman,S.,Seara,C.,Ventura,I.:Reverse facility location problems.In:
CCCG, pp.68-71 (2005), document 6:Du,Y.,Zhang,D.,Xia,T.:The optimal-location
query.In:SSTD, pp.163-180 (2005), document 21:Wong,R.C.W.,¨Ozsu,T.,Yu,P.S.,Fu,A.W.C.,
Liu,L.:Efficient method for maximizing bichromatic reverse nearest
Neighbor.PVLDB2 (1), 1126-1137 (2009), document 24:Zhang,D.,Du,Y.,Xia,T.,Tao,Y.:
Progressive computation of the min-dist optimal-location query.In:VLDB,
pp.643–654(2006))Middle consideration is distance between facility point and client's point in Lp spaces.Wherein Cabello et al.
(Referring to document 2)With Wong et al.(Referring to document 21)Research based on L2 spaces, and Du et al.(Referring to document 6)With
Zhang et al.(Referring to document 24)Research based on L1 spaces.Optimum position inquiry problem is not studied in these work
Situation in road network.
Existing research work includes other two kinds of problems relevant with the position selection of facility point:Single facility point is inquired about
Problem(Referring to document 8 and 15)And facility point sets up in real time problem(Referring to document 9:Fotakis,D.:Incremental
algorithms for facility location and kmedian.Theor.Comput.Sci.361(2-3),275–
313 (2006), document 13:Meyerson,A.:Online facility location.In:FOCS,pp.426–431
(2001)), but both Study on Problems contents are similar different with optimum position inquiry problem.Single facility point inquires about problem
Research, gives the set of client's point, finds a facility and sets up point so as to meet an optimum condition, asks at this
In topic, the facility point set not having built up in input data, but in optimum position inquiry problem, need to consider one
The set of existing facility point.Facility point sets up in real time Study on Problems, with being continuously increased for client's point, position is chosen in real time
Set up vertical new facility point to meet a given optimal conditions, with optimum position inquiry problem similarly, such issues that
When new facility point is found, it is also considered that existing facility point set, but the method that [9] and [13] are adopted can not be solved
Problem is inquired about in optimum position, this is because setting up in real time in problem in facility point, the candidate locations for setting up new facility point are one
Limited set, but in optimum position inquiry problem, the candidate locations for setting up new facility point are a unlimited set, example
Such as the set in all places in Lp spaces or all places on all sides in road network.Research work in our prior
In we have proposed the method for optimum position in static one query road network(Referring to document 22:Xiao,X.,Yao,B.,Li,F.:
Optimal location queries in road network databases.In:ICDE,pp.804–815(2011)),
Compared with that article, our invention proposes the solution of optimum position in new Dynamic Maintenance road network, and for three
Different optimum position inquiry problems devise concrete implementation method.
Finally, many researchs with regard to querying method in Traffic network database are there are in existing research work(Referring to 3:
Chen,Z.,Shen,H.T.,Zhou,X.,Yu,J.X.:Monitoring path nearest neighbor inroad
networks.In:SIGMOD, pp.591-602 (2009), document 4:Deng,K.,Zhou,X.,Shen,H.T.,Sadiq,S.,
Li,X.:Instance optimal query processing in spatial networks.VLDBJ18(3),675–
693 (2009), document 11:Jensen,C.S.,Kol′aˇrvr,J.,Pedersen,T.B.,Timko,I.:Nearest
neighbor queries in road networks.In:GIS, pp.1-8 (2003), document 12:Kolahdouzan,
M.R.,Shahabi,C.:Voronoi-based k-nearest neighbor search for spatial network
databases.In:VLDB, pp.840-851 (2004), document 14:Mouratidis,K.,Yiu,M.L.,Papadias,D.,
Mamoulis,N.:Continuous nearest neighbor monitoring in road networks.In:VLDB,
Pp.43-54 (2006), document 16:Papadias,D.,Zhang,J.,Mamoulis,N.,Tao,Y.:Query
processing in spatial network databases.In:VLDB, pp.802-813 (2003), document 17:
Samet,H.,Sankaranarayanan,J.,Alborzi,H.:Scalable network distance browsing in
spatial databases.In:SIGMOD, pp.43-54 (2008), document 18:Sankaranarayanan,J.,Samet,
H.:Distance oracles for spatial networks.In:ICDE, pp.652-663 (2009), document 19:
Sankaranarayanan,J.,Samet,H.,Alborzi,H.:Path oracles for spatial
Networks.PVLDB2 (1), 1210-1221 (2009), document 23:Yiu,M.L.,Mamoulis,N.,Papadias,D.:
Aggregate nearest neighbor queries in road networks.TKDE17(6),820–833(2005)).
But these research work are all the inquiries for paying close attention to closest approach in Traffic network database(Referring to document 12,16 and 17)And its mutation:
Closest approach approximate query(Referring to document 18 and 19), aggregate query(Referring to document 23), continuous closest approach inquiry(Referring to document
14), the inquiry of path closest approach(Referring to document 3)Etc..Technology in these research work can not solve optimum position inquiry
Problem, because closest approach inquiry problem is inherently different with optimum position inquiry problem.
In addition, the related bibliography of the present invention is also including as follows:
Document 1:de Berg,M.,Cheong,O.,van Kreveld,M.,Overmars,M.:Computational
Geometry:Algorithms and Applications,3rd edn.Springer-Verlag(2008);
Document 5:Dijkstra,E.W.:A note on two problems in connexion with
graphs.Numerische Mathematik1,269–271(1959);
Document 7:Erwig,M.,Hagen,F.:The graph voronoi diagram with
applications.Networks36,156–163(2000);
Document 10:Hershberger,J.:Finding the upper envelope of n line segments
in o(n log n)time.Inf.Process.Lett.33(4),169–174(1989);
Document 20:Shekhar,S.,Liu,D.R.:CCAM:A connectivity-clustered access
method for networks and network computations.TKDE9(1),102–119(1997)。
The content of the invention
It is an object of the invention to provide the dynamic monitoring and controlling method and system of a kind of inquiry minimum range and position, can be fast
Speed and dynamically inquiry minimum range and position.
To solve the above problems, the present invention provides the dynamic monitoring and controlling method of a kind of inquiry minimum range and position, including:
Give the set C of the client's point and set F of a facility point, and a location candidate set P, most narrow spacing
It is from positionWhereinWeighting for client point c attracts distance, and w (c) is visitor
The weight of family point c, if client point c and facility point f in road network be apart from d (c, f) point in c and F minimum,
The attraction person that f is c is then defined, c is attracted by f, a (c)=d (c, f) is the attraction distance of c;
P is obtained according to facility point set F initial in road network and client's point set C;
According to the renewal p of dynamic monitoring at any time that facility point set F in road network or client's point set C occur.
Further, in the above-mentioned methods, obtain p's according to facility point set F initial in road network and client's point set C
Step includes:
By the Connected undigraph G to expression road networko=(Vo,Eo) all of facility point f and client point c are inserted by EoIn
When being divided into new, for each point ρ ∈ C ∪ F, first consider the side e ∈ E that ρ is locatedo, two end points for making e are vlWith
vr, it is then two parts i.e. from v by e pointlTo ρ and from ρ to vr, so that ρ becomes a new summit of Connected undigraph, add institute
Some new summits are generating a new Connected undigraph G=(V, E), and V=Vo∪C∪F;
For every a line e ∈ EcInitialization calculates its local optimum positions I and corresponding financial value m, wherein, EcBe comprising
In location candidate set P side a little set, the financial value of certain position σ is
Local optimum positions I is all point sets with maximum return value on the e of side;
According to the local optimum positions I on all sides select corresponding financial value m it is maximum as maximum contention power position
p。
Further, in the above-mentioned methods, for every a line e ∈ EcInitialization calculate its local optimum positions I and
The step of corresponding financial value m, includes:
By the algorithm of Erwig and Hagen to calculate G in each vertex v nearest facility point f and apart from d (v,
f);
Two end points v of e are calculated respectivelylAnd vrAttraction set A (vl) and A (vr), wherein, give a vertex v, A
V () is the set of all client point c and respective distances d (c, v) that can be attracted to comprising v;
According to the A (v for having calculatedl) and A (vr) calculate e local optimum positions I and corresponding financial value m.
Further, in the above-mentioned methods, it is known that a vertex v, A (v) is obtained as follows:
Initialization A (v) is empty set;
All summits in G are traveled through with dijkstra's algorithm apart from ascending order according to v;
For the vertex v ' that each is traversed, a (v ') is made to be distances of the v ' to its nearest facility point f, if d (v,
V ')≤a (v '), and v ' is client's point, then will be<v′,d(v′,v)>Vertex v is added to attract after set A (v);If d
(v,v′)>A (v '), then ignore all sides with v ' as end points.
Further, in the above-mentioned methods, according to the A (v for having calculatedl) and A (vr) calculate e local optimum positions I
And the step of corresponding financial value m includes:
Calculate the financial value of two end points of e;
If the financial value of two end points is different, that larger end points of financial value is returned as the local optimum position of e
I is put, the larger corresponding financial value m as e in two financial values;Otherwise, using the two equal financial values as e correspondence
Financial value m, and investigate the financial value at the midpoint of e, if less than end points financial value, using two end points as e local optimum
Position I, if the financial value at the midpoint of e is equal with the financial value of two end points, using whole piece side e all as local optimum positions
I。
Further, in the above-mentioned methods, the renewal for being occurred according to facility point set F in road network or client's point set C with
When dynamic monitoring p the step of include:
The renewal of facility point and client's point in road network can be attributed to one client's point of increase(AddC(c)), reduce one
Client's point DelC (c), increases facility point AddF (f), reduces by facility point DelF (f) totally four kinds of basic operation;
When one updates operation arrives, the set for attracting distance to be updated affected client's point is calculated first
VcIf operation is AddC (c) or DelC (c), Vc={c};If operation is AddF (f) or DelF (f), Vc={c|<c,d
(c,v)>∈A(f)};
For each client point c ∈ Vc, the attraction before client's point is found out apart from a0C () and new attraction are apart from a'
(c), and set up two setWith
For each client point c ∈ Vc, according to a0(c), a'(c),Come update every a line e local most
Best placement I and corresponding financial value m, the local optimum positions and corresponding financial value before order renewal are respectively I0And m0;
According to the local optimum positions I on all sides select corresponding financial value m it is maximum as minimum range and position
p。
Further, in the above-mentioned methods, it is known that the local optimum positions and corresponding financial value before renewal are respectively
I0And m0, according to a0(c), a'(c),To update the local optimum positions I and corresponding financial value m of every a line e
The step of include:
Set up a vertex set
For each vertex v in S:IfAndThen set m (v)=m (v)-
w(c)(a0(c)-d(v,c));IfAndThen set m (v)=m (v)+w (c) (a '
(c)-d(v,c));IfWithAll set up, then set m (v)=m (v)+w (c) (a '
(c)-a0(c));Wherein m (v) represents the financial value of vertex v;
For every a line e, if at least one changed in the financial value of two end points of e:
Read e two end points update after financial value, if the financial value of two end points is different, return financial value compared with
Local optimum positions I, in two financial values larger corresponding financial value m as e of that the big end points as e;Otherwise, will
The two equal financial values and investigate the financial value at the midpoint of e as the corresponding financial value m of e, if than end points financial value
It is little, then using two end points as e local optimum positions I, if the financial value phase of the financial value at the midpoint of e and two end points
Deng then using whole piece side e all as local optimum positions I.
A kind of another side of the invention, there is provided the dynamic monitoring system of inquiry minimum range and position, including:
Definition module, for giving the set C of the client's point and set F of a facility point, and a candidate bit
Set P is put, minimum range and position areWhereinWeighting for client point c is inhaled
Draw distance, w (c) is the weight of client point c, if client point c and facility point f in road network apart from d (c, f) be c and F
In point minimum, then define the attraction person that f is c, c attracted by f, a (c)=d (c, f) for c attraction distance;
Acquisition module, for obtaining p according to facility point set F initial in road network and client's point set C;
Update module, for the renewal dynamic monitoring at any time occurred according to facility point set F in road network or client's point set C
p。
Further, in said system, the acquisition module is used for:
By the Connected undigraph G to expression road networko=(Vo,Eo) all of facility point f and client point c are inserted by EoIn
When being divided into new, for each point ρ ∈ C ∪ F, first consider the side e ∈ E that ρ is locatedo, two end points for making e are vlWith
vr, it is then two parts i.e. from v by e pointlTo ρ and from ρ to vr, so that ρ becomes a new summit of Connected undigraph, add institute
Some new summits are generating a new Connected undigraph G=(V, E), and V=Vo∪C∪F;
For every a line e ∈ EcInitialization calculates its local optimum positions I and corresponding financial value m, wherein, EcFor bag
In P containing location candidate set side a little set, the financial value of certain position σ is
Local optimum positions I is all point sets with maximum return value on the e of side;
According to the local optimum positions I on all sides select corresponding financial value m it is maximum as maximum contention power position
p。
Further, in said system, the acquisition module is used for:
By the algorithm of Erwig and Hagen to calculate G in each vertex v nearest facility point f and apart from d (v,
f);
Two end points v of e are calculated respectivelylAnd vrAttraction set A (vl) and A (vr), wherein, give a vertex v, A
V () is the set of all client point c and respective distances d (c, v) that can be attracted to comprising v;
According to the A (v for having calculatedl) and A (vr) calculate e local optimum positions I and corresponding financial value m.
Further, in said system, the acquisition module is used for:
Initialization A (v) is empty set;
All summits in G are traveled through with dijkstra's algorithm apart from ascending order according to v;
For the vertex v ' that each is traversed, a (v ') is made to be distances of the v ' to its nearest facility point f, if d (v,
V ')≤a (v '), and v ' is client's point, then will be<v′,d(v′,v)>Vertex v is added to attract after set A (v);If d
(v,v′)>A (v '), then ignore all sides with v ' as end points.
Further, in said system, the acquisition module is used for:
Calculate the financial value of two end points of e;
If the financial value of two end points is different, that larger end points of financial value is returned as the local optimum position of e
I is put, the larger corresponding financial value m as e in two financial values;Otherwise, using the two equal financial values as e correspondence
Financial value m, and investigate the financial value at the midpoint of e, if less than end points financial value, using two end points as e local optimum
Position I, if the financial value at the midpoint of e is equal with the financial value of two end points, using whole piece side e all as local optimum positions
I。
Further, in said system, the update module is used for:
The renewal of facility point and client's point in road network can be attributed to one client's point of increase(AddC(c)), reduce one
Client's point DelC (c), increases facility point AddF (f), reduces by facility point DelF (f) totally four kinds of basic operation;
When one updates operation arrives, the set for attracting distance to be updated affected client's point is calculated first
VcIf operation is AddC (c) or DelC (c), Vc={c};If operation is AddF (f) or DelF (f), Vc={c|<c,d
(c,v)>∈A(f)};
For each client point c ∈ Vc, the attraction before client's point is found out apart from a0C () and new attraction are apart from a'
(c), and set up two setWith
For each client point c ∈ Vc, according to a0(c), a'(c),Come update every a line e local most
Best placement I and corresponding financial value m, the local optimum positions and corresponding financial value before order renewal are respectively I0And m0;
According to the local optimum positions I on all sides select corresponding financial value m it is maximum as minimum range and position
p。
Further, in said system, it is known that the local optimum positions and corresponding financial value before renewal are respectively
I0And m0, the update module is used for:
Set up a vertex set
For each vertex v in S:IfAndThen set m (v)=m (v)-
w(c)(a0(c)-d(v,c));IfAndThen set m (v)=m (v)+w (c) (a '
(c)-d(v,c));IfWithAll set up, then set m (v)=m (v)+w (c) (a '
(c)-a0(c));Wherein m (v) represents the financial value of vertex v;
For every a line e, if at least one changed in the financial value of two end points of e:
Read e two end points update after financial value, if the financial value of two end points is different, return financial value compared with
Local optimum positions I, in two financial values larger corresponding financial value m as e of that the big end points as e;Otherwise, will
The two equal financial values and investigate the financial value at the midpoint of e as the corresponding financial value m of e, if than end points financial value
It is little, then using two end points as e local optimum positions I, if the financial value phase of the financial value at the midpoint of e and two end points
Deng then using whole piece side e all as local optimum positions I.
Compared with prior art, the set F of the set C and a facility point by giving client's point of the invention, with
And a location candidate set P, minimum range and position areWhereinFor visitor
The weighting of family point c attracts distance, and w (c) is the weight of client point c, if client point c and facility point f in road network away from
It is the minimum of the point in c and F from d (c, f), then defines the attraction person that f is c, c is attracted by f, a (c)=d (c, f) is the attraction of c
Distance;P is obtained according to facility point set F initial in road network and client's point set C;According to facility point set F or visitor in road network
The renewal that family point set C the occurs p of dynamic monitoring at any time, can quickly and dynamically inquire about minimum range and position.
Description of the drawings
Fig. 1 is the flow chart of the dynamic monitoring and controlling method of the inquiry minimum range and position of one embodiment of the invention.
Specific embodiment
It is understandable to enable the above objects, features and advantages of the present invention to become apparent from, it is below in conjunction with the accompanying drawings and concrete real
The present invention is further detailed explanation to apply mode.
Embodiment one
As shown in figure 1, the present invention provides the dynamic monitoring and controlling method of a kind of inquiry minimum range and position, including step S1 is extremely
Step S3.
Step S1, gives the set C of the client's point and set F of a facility point, and a location candidate set
P, minimum range and position areWhereinWeighting for client point c attracts distance,
W (c) is the weight of client point c, if client point c and facility point f in road network apart from d (c, f) be point in c and F
Minimum, then define the attraction person that f is c, c attracted by f, a (c)=d (c, f) for c attraction distance;
Step S2, according to facility point set F initial in road network and client's point set C p is obtained;
Preferably, step S2 includes:
Included the step of obtaining p according to facility point set F initial in road network and client's point set C:
By the Connected undigraph G to expression road networko=(Vo,Eo) all of facility point f and client point c are inserted by EoIn
When being divided into new, for each point ρ ∈ C ∪ F, first consider the side e ∈ E that ρ is locatedo, two end points for making e are vlWith
vr, it is then two parts i.e. from v by e pointlTo ρ and from ρ to vr, so that ρ becomes a new summit of Connected undigraph, add institute
Some new summits are generating a new Connected undigraph G=(V, E), and V=Vo∪C∪F;
For every a line e ∈ EcInitialization calculates its local optimum positions I and corresponding financial value m, wherein, EcBe comprising
In location candidate set P side a little set, the financial value of certain position σ is
Local optimum positions I is all point sets with maximum return value on the e of side;
According to the local optimum positions I on all sides select corresponding financial value m it is maximum as maximum contention power position
p。
Preferably, for every a line e ∈ EcInitialization calculates its local optimum positions I's and corresponding financial value m
Step includes:
By the algorithm of Erwig and Hagen to calculate G in each vertex v nearest facility point f and apart from d (v,
f);
Two end points v of e are calculated respectivelylAnd vrAttraction set A (vl) and A (vr), wherein, give a vertex v, A
V () is the set of all client point c and respective distances d (c, v) that can be attracted to comprising v;
According to the A (v for having calculatedl) and A (vr) calculate e local optimum positions I and corresponding financial value m.
Preferably, a known vertex v, A (v) is obtained as follows:
Initialization A (v) is empty set;
All summits in G are traveled through with dijkstra's algorithm apart from ascending order according to v;
For the vertex v ' that each is traversed, a (v ') is made to be distances of the v ' to its nearest facility point f, if d (v,
V ')≤a (v '), and v ' is client's point, then will be<v′,d(v′,v)>Vertex v is added to attract after set A (v);If d
(v,v′)>A (v '), then ignore all sides with v ' as end points.
Preferably, according to the A (v for having calculatedl) and A (vr) calculate e local optimum positions I and corresponding income
The step of value m, includes:
Calculate the financial value of two end points of e;
If the financial value of two end points is different, that larger end points of financial value is returned as the local optimum position of e
I is put, the larger corresponding financial value m as e in two financial values;Otherwise, using the two equal financial values as e correspondence
Financial value m, and investigate the financial value at the midpoint of e, if less than end points financial value, using two end points as e local optimum
Position I, if the financial value at the midpoint of e is equal with the financial value of two end points, using whole piece side e all as local optimum positions
I。
Step S3, according to the renewal p of dynamic monitoring at any time that facility point set F in road network or client's point set C occur.
Preferably, step S3 includes:
Included the step of at any time dynamic monitors p according to the renewal that facility point set F in road network or client's point set C occur:
The renewal of facility point and client's point in road network can be attributed to one client's point of increase(AddC(c)), reduce one
Client's point DelC (c), increases facility point AddF (f), reduces by facility point DelF (f) totally four kinds of basic operation;
When one updates operation arrives, the set for attracting distance to be updated affected client's point is calculated first
VcIf operation is AddC (c) or DelC (c), Vc={c};If operation is AddF (f) or DelF (f), Vc={c|<c,d
(c,v)>∈A(f)};
For each client point c ∈ Vc, the attraction before client's point is found out apart from a0C () and new attraction are apart from a'
(c), and set up two setWith
For each client point c ∈ Vc, according to a0(c), a'(c),Come update every a line e local most
Best placement I and corresponding financial value m, the local optimum positions and corresponding financial value before order renewal are respectively I0And m0;
According to the local optimum positions I on all sides select corresponding financial value m it is maximum as minimum range and position
p。
Preferably, the local optimum positions and corresponding financial value before known renewal are respectively I0And m0, according to a0(c),
A'(c),The step of come the local optimum positions I and corresponding financial value m that update every a line e, includes:
Set up a vertex set
For each vertex v in S:IfAndThen set m (v)=m (v)-
w(c)(a0(c)-d(v,c));IfAndThen set m (v)=m (v)+w (c) (a '
(c)-d(v,c));IfWithAll set up, then set m (v)=m (v)+w (c) (a '
(c)-a0(c));Wherein m (v) represents the financial value of vertex v;
For every a line e, if at least one changed in the financial value of two end points of e:
Read e two end points update after financial value, if the financial value of two end points is different, return financial value compared with
Local optimum positions I, in two financial values larger corresponding financial value m as e of that the big end points as e;Otherwise, will
The two equal financial values and investigate the financial value at the midpoint of e as the corresponding financial value m of e, if than end points financial value
It is little, then using two end points as e local optimum positions I, if the financial value phase of the financial value at the midpoint of e and two end points
Deng then using whole piece side e all as local optimum positions I.
Embodiment two
The present invention also provides the dynamic monitoring system of another kind of inquiry minimum range and position, including:
Definition module, for giving the set C of the client's point and set F of a facility point, and a candidate bit
Set P is put, minimum range and position areWhereinWeighting for client point c is inhaled
Draw distance, w (c) is the weight of client point c, if client point c and facility point f in road network apart from d (c, f) be c and F
In point minimum, then define the attraction person that f is c, c attracted by f, a (c)=d (c, f) for c attraction distance;
Acquisition module, for obtaining p according to facility point set F initial in road network and client's point set C;
Update module, for the renewal dynamic monitoring at any time occurred according to facility point set F in road network or client's point set C
p。
Further, in said system, the acquisition module is used for:
By the Connected undigraph G to expression road networko=(Vo,Eo) all of facility point f and client point c are inserted by EoIn
When being divided into new, for each point ρ ∈ C ∪ F, first consider the side e ∈ E that ρ is locatedo, two end points for making e are vlWith
vr, it is then two parts i.e. from v by e pointlTo ρ and from ρ to vr, so that ρ becomes a new summit of Connected undigraph, add institute
Some new summits are generating a new Connected undigraph G=(V, E), and V=Vo∪C∪F;
For every a line e ∈ EcInitialization calculates its local optimum positions I and corresponding financial value m, wherein, EcBe comprising
In location candidate set P side a little set, the financial value of certain position σ is
Local optimum positions I is all point sets with maximum return value on the e of side;
According to the local optimum positions I on all sides select corresponding financial value m it is maximum as maximum contention power position
p。
Further, in said system, the acquisition module is used for:
By the algorithm of Erwig and Hagen to calculate G in each vertex v nearest facility point f and apart from d (v,
f);
Two end points v of e are calculated respectivelylAnd vrAttraction set A (vl) and A (vr), wherein, give a vertex v, A
V () is the set of all client point c and respective distances d (c, v) that can be attracted to comprising v;
According to the A (v for having calculatedl) and A (vr) calculate e local optimum positions I and corresponding financial value m.
Further, in said system, the acquisition module is used for:
Initialization A (v) is empty set;
All summits in G are traveled through with dijkstra's algorithm apart from ascending order according to v;
For the vertex v ' that each is traversed, a (v ') is made to be distances of the v ' to its nearest facility point f, if d (v,
V ')≤a (v '), and v ' is client's point, then will be<v′,d(v′,v)>Vertex v is added to attract after set A (v);If d
(v,v′)>A (v '), then ignore all sides with v ' as end points.
Further, in said system, the acquisition module is used for:
Calculate the financial value of two end points of e;
If the financial value of two end points is different, that larger end points of financial value is returned as the local optimum position of e
I is put, the larger corresponding financial value m as e in two financial values;Otherwise, using the two equal financial values as e correspondence
Financial value m, and investigate the financial value at the midpoint of e, if less than end points financial value, using two end points as e local optimum
Position I, if the financial value at the midpoint of e is equal with the financial value of two end points, using whole piece side e all as local optimum positions
I。
Further, in said system, the update module is used for:
The renewal of facility point and client's point in road network can be attributed to one client's point of increase(AddC(c)), reduce one
Client's point DelC (c), increases facility point AddF (f), reduces by facility point DelF (f) totally four kinds of basic operation;
When one updates operation arrives, the set for attracting distance to be updated affected client's point is calculated first
VcIf operation is AddC (c) or DelC (c), Vc={c};If operation is AddF (f) or DelF (f), Vc={c|<c,d
(c,v)>∈A(f)};
For each client point c ∈ Vc, the attraction before client's point is found out apart from a0C () and new attraction are apart from a'
(c), and set up two setWith
For each client point c ∈ Vc, according to a0(c), a'(c),Come update every a line e local most
Best placement I and corresponding financial value m, the local optimum positions and corresponding financial value before order renewal are respectively I0And m0;
According to the local optimum positions I on all sides select corresponding financial value m it is maximum as minimum range and position
p。
Further, in said system, it is known that the local optimum positions and corresponding financial value before renewal are respectively
I0And m0, the update module is used for:
Set up a vertex set
For each vertex v in S:IfAndThen set m (v)=m (v)-
w(c)(a0(c)-d(v,c));IfAndThen set m (v)=m (v)+w (c) (a '
(c)-d(v,c));IfWithAll set up, then set m (v)=m (v)+w (c) (a '
(c)-a0(c));Wherein m (v) represents the financial value of vertex v;
For every a line e, if at least one changed in the financial value of two end points of e:
Read e two end points update after financial value, if the financial value of two end points is different, return financial value compared with
Local optimum positions I, in two financial values larger corresponding financial value m as e of that the big end points as e;Otherwise, will
The two equal financial values and investigate the financial value at the midpoint of e as the corresponding financial value m of e, if than end points financial value
It is little, then using two end points as e local optimum positions I, if the financial value phase of the financial value at the midpoint of e and two end points
Deng then using whole piece side e all as local optimum positions I.
Other detailed contents of embodiment two specifically can be found in embodiment one, will not be described here.
The present invention is by giving the set C of the client's point and set F of a facility point, and a position candidate collection
P is closed, minimum range and position areWhereinFor client point c weighting attract away from
From, w (c) is the weight of client point c, if client point c and facility point f in road network apart from d (c, f) be in c and F
The minimum of point, then define the attraction person that f is c, and c is attracted by f, and a (c)=d (c, f) is the attraction distance of c;According to first in road network
Facility point set F of beginning and client's point set C obtain p;Occurred more according to facility point set F in road network or client's point set C
The new monitoring p of dynamic at any time, can quickly and dynamically inquire about minimum range and position.
Each embodiment is described by the way of progressive in this specification, and what each embodiment was stressed is and other
The difference of embodiment, between each embodiment identical similar portion mutually referring to.For system disclosed in embodiment
For, due to corresponding to the method disclosed in Example, so description is fairly simple, related part is referring to method part illustration
.
Professional further appreciates that, with reference to the unit of each example of the embodiments described herein description
And algorithm steps, can with electronic hardware, computer software or the two be implemented in combination in, in order to clearly demonstrate hardware and
The interchangeability of software, according to function has generally described the composition and step of each example in the above description.These
Function is performed with hardware or software mode actually, depending on the application-specific and design constraint of technical scheme.Specialty
Technical staff can use different methods to realize described function to each specific application, but this realization should not
Think beyond the scope of this invention.
Obviously, those skilled in the art can carry out the spirit of various changes and modification without deviating from the present invention to invention
And scope.So, if these modifications of the present invention and modification belong to the claims in the present invention and its equivalent technologies scope it
Interior, then the present invention is also intended to including including these changes and modification.