Summary of the invention
The purpose of embodiment of the present invention is to provide a kind of supply chain progress Order Batch configuration for intelligence manufacture
Method and system, this method can improve intelligence manufacture supply chain configuration reasonability, improve the production efficiency of element.
To achieve the goals above, embodiment of the present invention provides a kind of supply chain progress order for intelligence manufacture
The method configured in batches, which comprises
The technique for obtaining every kind of workpiece of production, according to preset technique collection construction process information matrix;
Calculate separately the similitude of every two kinds of workpiece;
Similarity matrix is constructed according to the similitude;
Cluster operation is carried out to the workpiece in the similarity matrix using K central point (K-Mediods) algorithm;
The production order of every kind of workpiece is adjusted according to the cluster result of the cluster operation.
Optionally, the technique for obtaining every kind of workpiece of production, according to preset technique collection construction process information matrix packet
It includes:
The technique information matrix is constructed using formula (1),
Wherein, Tn×mBeing includes the workpiece of n type and the technique information matrix of the m technique, and W is 0 or 1, n
For the type of workpiece, m is the quantity of technique.
Optionally, the similitude for calculating separately every two kinds of workpiece includes:
The Euclidean distance of every two kinds of workpiece is calculated according to formula (2),
Wherein, dijFor the Euclidean distance of i-th of workpiece and j-th of workpiece, m is the technique
Quantity, WipFor p-th of element in the vector of i-th of workpiece, WjpIt is p-th yuan of the vector of j-th of workpiece
Element, Wip、WjpValue be 0 or 1.
Optionally, described to include: according to similitude construction similarity matrix
The similarity matrix is constructed according to formula (3),
Wherein, DnxmFor the similarity matrix.
Optionally, it is described using K central point algorithm to the workpiece in the similarity matrix carry out cluster operation include:
The workpiece of K type of preset quantity is randomly choosed as current central point;
The workpiece for calculating remaining type arrives the Euclidean distance of preset quantity K current central points respectively, respectively
Centered on each current central point, preset distance is radius, and the workpiece of all kinds is divided into K current collection
It closes;
Calculate separately the central point other workpiece into the current collection of each current collection Europe it is several in
Obtain the current summation of distance;
The workpiece of a non-central point is randomly selected in each current collection respectively as new central point;
Respectively centered on each new central point, preset distance is radius, and the workpiece of all kinds is divided into K newly
Set;
Calculate separately each new central point into corresponding new set the Euclidean distance of other workpiece it is new
Summation;
Judge whether the current summation and the difference of new summation are equal to 0;
In the case where judging the difference not equal to 0, judge whether the difference is greater than 0;
Judge the difference be greater than 0 in the case where, using new central point, new set and new summation as currently in
Heart point, current collection and current summation randomly select the work of a non-central point in each current collection respectively again
Part is as new central point and executes the corresponding steps of the method, until the difference is equal to 0;
In the case where judging the difference less than 0, one is randomly selected in each current collection respectively again
The workpiece of non-central point is as new central point and executes the corresponding steps of the method, until the difference is equal to 0;
In the case where judging that the difference is equal to 0, further judge whether the number of iterations reaches preset times;
In the case where judging that the number of iterations reaches preset times, the current collection is exported to tie as cluster
Fruit;
In the case where judging that the number of iterations is not up to preset times, again respectively in each current collection
The workpiece of a non-central point is randomly selected as new central point and executes the corresponding steps of the method, until the iteration
Number reaches preset times.
Optionally, the method further includes:
The silhouette coefficient of the cluster result is calculated to evaluate the result.
Optionally, the method further includes:
The silhouette coefficient is calculated according to formula (4),
Wherein, Avg (s) is the silhouette coefficient, and n is the quantity of the type of the workpiece, njFor the institute in j-th of set
State the quantity of the type of workpiece, sjThe value of the summation for the Euclidean distance gathered for j-th.
What another aspect of the present invention also provided that a kind of supply chain for intelligence manufacture carries out Order Batch configuration is
System, the system comprises processor, the processor is used to execute any of the above-described method.
Another aspect of the invention also provides a kind of storage medium, and the storage medium is stored with instruction, and described instruction is used
In being read by a machine so that the machine executes any of the above-described method.
Through the above technical solutions, carrying out Order Batch configuration provided by the present invention for the supply chain to intelligence manufacture
The production technology of every kind of workpiece is converted to technique information matrix by using preset technique collection by method and system, passes through calculating
The Euclidean distance of every two kinds of workpiece simultaneously classifies to every kind of workpiece using K central point algorithm, according to classification results to confession
It answers the configuration of chain to be regulated and controled, so that the configuration of supply chain rationalizes, improves the production efficiency of workpiece.
The other feature and advantage of embodiment of the present invention will the following detailed description will be given in the detailed implementation section.
Specific embodiment
It is described in detail below in conjunction with specific embodiment of the attached drawing to embodiment of the present invention.It should be understood that
Embodiment that the specific embodiments described herein are merely illustrative of the invention is not intended to restrict the invention implementation
Mode.
It is according to embodiment of the present invention for the supply chain progress order point to intelligence manufacture as shown in Figure 1
The flow chart of the method for batch configuration.In Fig. 1, this method may include:
In step slo, the technique for obtaining every kind of workpiece of production, according to preset technique collection construction process information matrix.
In an example of the invention, with the supply chain data instance of certain company, obtained from the customer order and BOM inventory of the said firm
The workpiece of processing in need and all technique (process).Preset technique collection can be the set of all technique.It is right
The corresponding element of the technique is preset as 1, at this in the case where a kind of workpiece includes the technique in the technique that technique is concentrated
In the case that workpiece does not include the technique, the corresponding element of the technique is preset as 0, to form every kind of (n) workpiece
Vector tn=W1,W2,W3,…,Wm.It is technique information matrix that the vector of every kind of workpiece, which is merged into a matrix,.Such as formula (1) institute
Show,
Wherein, Tn×mBeing includes the workpiece of n type and the technique information matrix of m technique, and W is 0 or 1, and n is workpiece
Type, m are the quantity of technique.
In step s 11, the similitude of every two kinds of workpiece is calculated separately.Taking the above example as an example, due to the work of supply chain
Technique involved by part is m.It so can establish the space of m dimension, exist within this space a bit, so that the space
Origin be directed toward the point vector it is equal with the vector of workpiece, so that it is empty that the vector of all kinds workpiece is abstracted as m dimension
Between multiple points.
In the m-dimensional space, the similitude for calculating the technique of any two kinds of workpiece, which can be, for example to be calculated often according to formula (2)
The Euclidean distance of two kinds of workpiece,
Wherein, dijFor the Euclidean distance of i-th of workpiece and j-th of workpiece, m is the quantity of technique, WipIt is i-th
P-th of element in the vector of workpiece, WjpFor p-th of element of the vector of j-th of workpiece, Wip、WjpValue be 0 or 1.
In step s 12, similarity matrix is constructed according to similitude.In an example of the invention, based on above-mentioned
The Euclidean distance of calculating, the similarity matrix constructed can be as shown in formula (3),
Wherein, DnxmFor similarity matrix, d21、dn1、dn2Etc. all can be calculated Euclidean distance.
In step s 13, cluster fortune is carried out to the workpiece in similarity matrix using K central point (K-Mediods) algorithm
It calculates.Taking the above example as an example, in an example of the invention, step S14 may include step as illustrated in FIG. 2.?
In Fig. 2, step S14 may include:
In step S20, the workpiece of K type of preset quantity is randomly choosed as current central point;
In the step s 21, calculate remaining type workpiece arrive respectively the Euclids of preset quantity K current central points away from
From respectively centered on each current central point, preset distance is radius, and the workpiece of all kinds is divided into K current collection
It closes (class in cluster result);
In step S22, the central point of each current collection is calculated separately in the Europe of other workpiece is several into current collection
Obtain the current summation of distance;
In step S23, the workpiece of a non-central point is randomly selected in each current collection respectively as in new
Heart point;
In step s 24, respectively centered on each new central point, preset distance is radius, by the work of all kinds
Part is divided into K new set;
In step s 25, calculate separately each new central point other workpiece into corresponding new set Europe it is several in
Obtain the new summation of distance;
In step S26, judge whether current summation and the difference of new summation are equal to 0;
In step s 27, in the case where judging difference not equal to 0, judge whether difference is greater than 0;
In step S28, in the case where judging that difference is greater than 0, new central point, new set and new summation are made
For current central point, current collection and current summation, a non-central point is randomly selected in each current collection respectively again
Workpiece as new central point and execute method corresponding steps (step S23 to step S26), until the difference be equal to 0;
In the case where judging calculated difference less than 0, one is randomly selected in each current collection respectively again
The workpiece of non-central point is as new central point and executes corresponding steps (the step S23 to step S26), until the difference of method
Equal to 0;
In step S29, in the case where judging that the difference is equal to 0, further judge whether the number of iterations reaches default
Number;
In step s 30, in the case where judging that the number of iterations reaches preset times, output current collection is using as cluster
As a result;
In the case where judging that the number of iterations is not up to preset times, randomly selected in each current collection respectively again
The workpiece of one non-central point as new central point and execute method corresponding steps (step S23 to step S9), until repeatedly
Generation number reaches preset times.
In step S14, the production order of every kind of workpiece is adjusted according to the cluster result of cluster operation.
In an embodiment of the invention, as shown in figure 3, this method can also include step 36.It, should in Fig. 3
Step S36, which can be, calculates the silhouette coefficient of cluster result for example to evaluate cluster result.Specifically, of the invention
In one example, step S35, which can be, calculates silhouette coefficient according to formula (4),
Wherein, Avg (s) is silhouette coefficient, and n is the quantity of the type of workpiece, njFor the type of the workpiece in j-th of set
Quantity, sjThe value of the summation for the Euclidean distance gathered for j-th.
What another aspect of the present invention also provided that a kind of supply chain for intelligence manufacture carries out Order Batch configuration is
Completely, which may include processor, which can be used for executing any of the above-described method.
Another aspect of the invention also provides a kind of storage medium, and storage medium is stored with instruction, instructs for by machine
It reads so that machine executes any of the above-described method.
Through the above technical solutions, carrying out Order Batch configuration provided by the present invention for the supply chain to intelligence manufacture
The production technology of every kind of workpiece is converted to technique information matrix by using preset technique collection by method and system, passes through calculating
The Euclidean distance of every two kinds of workpiece simultaneously classifies to every kind of workpiece using K central point algorithm, according to classification results to confession
The configuration of chain is answered to be regulated and controled, it is middle compared with the existing technology to rely on the artificial mode for determining supply chain batch, solve supply chain
The low problem of allocative efficiency.
By taking the order of certain model hydraulic pump of the processing of B company as an example, using method provided by the invention to every in order
Kind workpiece is clustered.
According to the BOM inventory of certain model hydraulic pump of B company, technique collection includes 35 techniques and workpiece is 71 kinds, according to
Above-mentioned data generate the vector t of every kind of workpiecen=W1,W2,W3,…,Wm。
The vector of every kind of workpiece is merged by technique information matrix using Java language and MySql database.Technique letter
Ceasing matrix can be
After calculating similarity matrix, using K central point algorithm (taking K=10) according to the similarity matrix to the work
Part is clustered, and cluster result is as shown in table 1,
Above-mentioned cluster result is analyzed, 71 kinds of workpiece are divided into 10 classes, calculate separately the profile system of 10 classes
Number, since the mode of the calculating silhouette coefficient is known to those skilled in the art, details are not described herein again.
According to calculated result it is found that the 1st, 7, the silhouette coefficient values of 9 classes is larger and has significant difference with other classes.With
For 1 class, according to BOM inventory it is found that the workpiece of the 1st class is mainly components relevant to axis, the life of each workpiece therein
Production. art is close, and production efficiency can be improved to production together in the work piece configuration in the 1st class, saves production cost.Thus may be used
See, this method can effectively improve the reasonability of the configuration of supply chain, improve the production efficiency of workpiece.
The optional embodiment of example of the present invention is described in detail in conjunction with attached drawing above, still, embodiment of the present invention is not
The detail being limited in above embodiment can be to of the invention real in the range of the technology design of embodiment of the present invention
The technical solution for applying mode carries out a variety of simple variants, these simple variants belong to the protection scope of embodiment of the present invention.
It is further to note that specific technical features described in the above specific embodiments, in not lance
In the case where shield, it can be combined in any appropriate way.In order to avoid unnecessary repetition, embodiment of the present invention
To various combinations of possible ways, no further explanation will be given.
It will be appreciated by those skilled in the art that realizing that all or part of the steps in above embodiment method is can to lead to
Program is crossed to instruct relevant hardware and complete, which is stored in a storage medium, including some instructions use so that
One (can be single-chip microcontroller, chip etc.) or processor (processor) execute each embodiment the method for the application
All or part of the steps.And storage medium above-mentioned includes: USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only
Memory), random access memory (RAM, Random Access Memory), magnetic or disk etc. are various can store journey
The medium of sequence code.
In addition, any combination can also be carried out between a variety of different embodiments of embodiment of the present invention, as long as its
Without prejudice to the thought of embodiment of the present invention, embodiment of the present invention disclosure of that equally should be considered as.