Tobacco raw material warehouse-in allocation method based on spatial mapping genetic algorithm
Through the tobacco leaf raw material storage allocation method based on spatial mapping genetic algorithm, the problem of reliance on manual experience in tobacco leaf storage management is solved, intelligent stack allocation is realized, storage efficiency and quality are improved, local optimality is avoided, and inventory and production plans are optimized.
Patent Information
- Application Number
- CN202311238529.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-23
- Publication Date
- 2025-10-17
- Estimated Expiration
- 2043-09-23
AI Technical Summary
In the existing tobacco raw material storage management, the allocation of storage stacks relies on manual experience, has a low level of intelligence, and is difficult to achieve efficient optimization. In addition, the existing algorithms are difficult to effectively reuse in specific scenarios and are prone to falling into local optimality.
A spatial mapping genetic algorithm is used to establish the spatial model, task model and optimization model of the tobacco raw material warehouse. The optimal storage allocation plan is solved by the genetic algorithm, combined with crossover and mutation operations with correction strategies to avoid local optimality.
It improves the intelligence level of tobacco raw material storage, ensures storage quality and supply quality, optimizes inventory management and production planning, avoids local optimality, and improves computing efficiency.
Smart Images

Figure CN117273610B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the warehouse storage and logistics process of tobacco raw materials, and belongs to the storage location optimization technology in intelligent logistics technology. BACKGROUND
[0002] The storage link of tobacco raw materials is a crucial link in the tobacco logistics process, and its effect on tobacco quality and supply is affected by many factors. Due to the different value classification, storage characteristics of tobacco raw materials, the required storage environment and time are also different. In addition, the quality guarantee capacity of different storage locations such as floor climate environment, equipment, and storage capacity also differs. For different raw material planning inventory cycle, aging cycle and use cycle, how to develop an allocation strategy for warehouse entry has a great influence on tobacco maintenance and the quality of tobacco supply.
[0003] Currently, the allocation of tobacco raw material storage locations mainly relies on manual experience, and the degree of intelligence is low, which is difficult to achieve the purpose of efficient optimization. Therefore, by applying intelligent optimization algorithms to develop a tobacco raw material warehouse entry allocation strategy, it is of great significance to improve the quality of tobacco maintenance and supply. Based on the algorithm, the characteristics of tobacco raw materials and the situation of the storage location can be analyzed to automatically optimize the allocation strategy of the storage location, reduce the factors of manual intervention, and improve work efficiency. In addition, the intelligent allocation strategy of tobacco raw material warehouse entry can also play an important role in inventory management and production planning. Through a reasonable allocation strategy, the loss and waste of tobacco raw materials can be minimized to ensure that the quality and quantity of tobacco are fully guaranteed. At the same time, a scientific allocation strategy for tobacco raw material warehouse entry can also help to develop a scientific tobacco production plan to improve production efficiency and product quality.
[0004] At present, the academic community has carried out a large number of researches on the warehouse location allocation problem. The public literature "Dynamic Storage Allocation of Automated Warehouse Based on Genetic Algorithm" proposes a dynamic storage allocation model of automated warehouse based on genetic algorithm, taking the storage allocation of the warehouse area and the travel time of the stacker based on the random storage strategy as the optimization control target, and using the genetic algorithm to obtain the Pareto optimal solution of the dynamic storage allocation and the picking path optimization. The public literature "Optimization of Storage Allocation of Three-dimensional Warehouse Based on Improved Particle Swarm Algorithm" proposes an improved particle swarm algorithm (PSO) based on Pareto optimal solution based on the optimization model considering the stability of the shelf and the efficiency of warehouse in and out, and uses the niche technology to improve the dispersion of the non-inferior solution set. The public literature "Research on Storage Allocation Strategy Based on Product Frequency and Deviation" proposes a storage allocation strategy based on product frequency for single-zone warehouse and a storage allocation strategy based on deviation for outbound, realizing the rapid outbound of high-demand products and the rapid positioning of products. The public literature "Integrated Optimization of Storage Allocation and Operation Scheduling of Multi-vehicle Automated Three-dimensional Warehouse" proposes an integrated optimization method of storage allocation and operation scheduling, combines the actual operation law of the stacker, and designs a double-layer genetic search algorithm to solve the integrated optimization model. The public literature "Research on Storage Allocation Optimization Method of Flying-V Type Warehouse Layout" proposes a multi-objective optimization model in line with the characteristics of the layout for the non-traditional Flying-V type warehouse layout, and uses the genetic algorithm (GA) with adaptive strategy and the particle swarm algorithm (PSO) for solution.
[0005] With the in-depth research on the mathematical model and algorithm of warehouse location allocation in the academic field, more complex evaluation methods and solution strategies are constantly introduced, which greatly improves the effectiveness, solution speed and quality of warehouse location allocation. However, the above research results are still based on traditional commercial logistics scenarios, and the characteristics and evaluation indexes of inbound goods are relatively similar. For different warehouse layouts and goods characteristics, the classic model is difficult to cover all scenarios, and cannot be effectively reused in more characteristic inbound allocation scenarios. At the same time, due to the particularity of the warehouse location allocation code, a considerable part of the algorithm is prone to local optimum due to the lack of effective iteration strategy. SUMMARY
[0006] The technical problem to be solved by the present application is to overcome the shortcomings of the existing tobacco raw material warehouse management method, and to provide a tobacco raw material warehouse allocation method based on a space mapping genetic algorithm.
[0007] To solve the technical problem, the solution of the present application is:
[0008] A tobacco raw material warehouse allocation method based on a space mapping genetic algorithm is provided, comprising the following steps:
[0009] (1) Establish a space model:
[0010] Space mapping coding is performed on each pile position in the tobacco raw material warehouse to establish a space model; after actual space position mapping and key-value pair mapping, the actual space position of each pile position is mapped to a unique code corresponding to the space coordinates;
[0011] (2) Establish a task model:
[0012] According to the warehouse plan, the warehouse-in tasks of the tobacco raw material are counted to form a batch-in warehouse task set; then, according to the actual use demand, the task set is further split into a set composed of multiple sub-tasks;
[0013] (3) Establish an optimization model:
[0014] Based on the characteristics of tobacco raw material storage and maintenance, an optimization model is constructed for the calculation of warehouse-in and warehouse-out efficiency, dispersion degree of similar tobaccos, aging quality and utilization rate of storage capacity;
[0015] (4) Genetic algorithm solution
[0016] The data sets of the space model, the task model and the optimization model are taken as inputs, and the genetic algorithm is used for solution to obtain an optimized warehouse-in allocation scheme.
[0017] As a preferred scheme of the present application, in step (1), the coding of each pile position in the warehouse is obtained by the following way:
[0018] (1.1) Each pile position is marked as a three-dimensional coordinate (f, r, c), wherein f is the floor number, r is the row number of the pile position of a single-layer warehouse, and c is the column number of the pile position of a single-layer warehouse;
[0019] (1.2) Based on the warehouse single-layer space layout plan, the lower left corner in the plan is defined as the first pile position of the layer; in this way, the coordinate (f, r, c) is mapped to (f, m s ); wherein f is the floor number, and m s is the unique number of the pile position of a single-layer warehouse;
[0020] (1.3) Based on the actual space position of each pile position, (f, m s ) is mapped to a key-value pair (m u , v); wherein m u is the unique number of the pile position in the entire warehouse; and v is the space coordinates (x, y, z) of the center point of the pile position with the entrance of the first floor warehouse as the origin, wherein x is the x-direction distance of the center of the pile position from the entrance, y is the y-direction distance of the center of the pile position from the entrance, and z is the z-direction distance of the center of the pile position from the entrance;
[0021] The unique number m u of the pile position is calculated according to the following formula:
[0022] mu = f x M + m s , f e [1, F], m e [1, M] s i n
[0023] In the formula, F is the total number of floors, and M is the total number of single-layer warehouse shelves.
[0024] As a preferred scheme of the present application, in step (2), the task model for the storage allocation of tobacco raw materials is established in the following manner:
[0025] (2.1) The storage task of tobacco raw materials is counted, and an initial task set T for batch storage is established:
[0026] T = {S1, S2,... S i ,... S n}
[0027] wherein S i is the i-th task in the initial task set, corresponding to the storage order of the i-th batch of tobacco; and n is the set capacity.
[0028] (2.2) Taking k boxes of tobacco raw materials as a basic unit, the basic unit is taken as a sub-task granularity k; and the initial task set T is split into a sub-task set T si :
[0029]
[0030] wherein the tobacco attribute (R, K, C, P) of the task S ij is consistent with that of the parent task S i , and the number of raw material boxes is updated to the result of the re-division accordingly.
[0031] (2.3) The calculation rules and constraint conditions of the capacity n si of the sub-task set T si and the number of raw material boxes N ij of the sub-task S ij are shown in the following formulas:
[0032] L mod k = 0, k e (0, L)
[0033]
[0034]
[0035]
[0036] In the above formulas: L is the shelf capacity; mod is the modulus operator; N i is the number of raw material boxes of the parent task S i , and N lis the number of remaining boxes after re-division, k is the granularity of sub-tasks, and S ij is the jth task in the ith sub-task set; N ij is the number of raw material boxes of the jth task in the ith sub-task set; n si is the number of sub-task sets divided by the ith parent task; T sub is the total task set after re-division.
[0037] As a preferred scheme of the present application, in step (3), the total in-out warehouse time of tobacco raw materials is calculated according to the following formula:
[0038]
[0039] In the above formula, v x , v y , and v z are the in-out warehouse speeds in x, y, and z directions, respectively; x i , y i , and z i are the distances of the pile position of the ith batch of raw materials from the entrance and exit in x, y, and z directions, respectively; R i is the turnover rate of the ith batch of raw materials; n t is the total number of tasks after task division; i = 1 indicates that the calculation starts from the first batch.
[0040] As a preferred scheme of the present application, in step (3), the dispersion degree of the same kind of tobacco raw materials in the warehouse is calculated according to the following formula:
[0041] The center coordinates are defined as follows:
[0042]
[0043] The overall dispersion degree is represented as:
[0044]
[0045] In the above formula, λ is an environmental coefficient set according to the difference in horizontal and vertical position environment, and its value range is [1, 5]; n k is the total number of tasks of the kth kind of raw material; x ki , y ki , and z ki are the distances of the pile position of the ith batch of the kth kind of raw material from the entrance and exit in x, y, and z directions, respectively; i = 1 indicates that the calculation starts from the first batch; k n is the total number of raw material types; x kc , y kc , and z kc are the distances of the center coordinates of the kth kind of raw material from the entrance and exit in x, y, and z directions, respectively.
[0046] As a preferred scheme of the present application, in the step (3), the tobacco aging quality evaluation function is determined according to the following formula:
[0047] The tobacco aging quality evaluation function of each batch of tobacco is expressed as:
[0048] A i (x, y, z) = C i × P i × a zi
[0049] The overall aging quality evaluation function is expressed as:
[0050]
[0051] In the above formula, C i is the aging speed of the i-th batch of raw materials; P i is the service period of the i-th batch of raw materials; a zi is the aging coefficient of each floor, with a value range of [0, 1]; A i is the aging degree of the i-th batch of tobacco; A std is the standard aging value; n t is the total number of tasks after task division; i = 1 indicates that the calculation starts from the first batch.
[0052] As a preferred scheme of the present application, in the step (3), the warehouse capacity utilization evaluation function is determined according to the following formula:
[0053]
[0054] In the above formula, U i is the amount of tobacco raw materials on the stack position with the i-th stack position number; C i is the total capacity of the stack position; n t is the total number of tasks after task division; i = 1 indicates that the calculation starts from the first batch.
[0055] As a preferred scheme of the present application, in the step (4), the process of solving by the genetic algorithm includes: randomly initializing the population using stack task granularity coding, calculating the fitness F of the population individuals; then generating a new population based on selection, crossover with correction strategy, and mutation; after iteration reaches the maximum iteration number, the optimal warehouse allocation scheme is obtained by decoding; the warehouse allocation scheme is in array form, with an array size of n t , an array subscript of task number, and an array value of the globally unique stack number corresponding to the placement position of the batch of raw materials. The effectiveness of the scheme is judged by evaluating the warehouse-in and warehouse-out efficiency, the dispersion of similar raw materials, the aging quality, and the warehouse capacity utilization of the final warehouse allocation scheme.
[0056] Compared with the prior art, the technical effects of the present invention are:
[0057] 1. This paper establishes a spatial model and a task model for the specific research object of tobacco raw material storage. By analyzing the characteristics and storage location of tobacco raw materials, an evaluation function that conforms to the production rules of tobacco raw material storage is selected, and a genetic algorithm with a correction strategy is used for optimization to avoid falling into local optimality.
[0058] 2. The tobacco raw material warehouse space model, warehousing order task model, and evaluation function optimization model proposed in this invention are based on in-depth research on actual scenarios and conform to the characteristics and laws of tobacco raw material storage logistics. Taking into account the different storage requirements and characteristics between tobacco raw materials and ordinary commodities, as well as the impact of the storage environment on the preservation and aging quality of tobacco raw materials, the proposed model can effectively ensure the storage quality and supply of tobacco raw materials. At the same time, combined with production and use plans, a new model is proposed for the management of tobacco raw material warehouses, introducing intelligent logistics concepts into the stack allocation process, which has certain reference value for the intelligent transformation of tobacco raw material warehouses.
[0059] 3. This invention utilizes a genetic algorithm with spatial mapping encoding, using task capacity as chromosome length, to improve computational efficiency. Furthermore, to address infeasible solutions that arise during the iterations of the warehouse allocation model algorithm, a modified two-point crossover strategy and a reverse insertion mutation interval strategy are proposed. Compared to simply discarding infeasible solutions, this improved strategy can introduce new elements into the population and effectively expand the search range to neighboring regions, avoiding local optima and enhancing the algorithm's ability to find the global optimal solution.
[0060] 4. The present invention is of great significance for improving the quality of tobacco leaf maintenance and supply, optimizing inventory management and production planning, and is worthy of further research and application. BRIEF DESCRIPTION OF THE DRAWINGS
[0061] Figure 1 Flowchart of the genetic algorithm to solve the optimal inventory allocation plan.
[0062] Figure 2 Schematic diagram of the modified two-point crossover strategy in the genetic algorithm.
[0063] Figure 3 Flowchart of the crossover operation in the genetic algorithm.
[0064] Figure 4 Schematic diagram of the mutation interval strategy for reverse insertion in the genetic algorithm.
[0065] Figure 5 is the population convergence curve in the application example. DETAILED DESCRIPTION
[0066] The application will be described in further detail below with reference to the drawings:
[0067] The tobacco raw material warehouse allocation method based on the space mapping genetic algorithm comprises the following steps:
[0068] 1. Establish a space model
[0069] The warehouse is coded by space mapping. Each stack position is marked as a three-dimensional coordinate (f, r, c), where f is the floor number, r is the row number of the stack position in the single-layer warehouse, and c is the column number of the stack position in the single-layer warehouse; based on the overhead view of the single-layer space layout of the warehouse, the lower left corner in the figure is defined as No. 1 stack position on the layer; in this way, the coordinate (f, m s ) is mapped; where f is the floor number, m s is the unique number of the stack position in the single-layer warehouse; based on the actual space position of each stack position, (f, m s ) is mapped into a key-value pair (m u , v); where m u is the unique number of the stack position in the entire warehouse; v is the space coordinate (x, y, z) of the center point of the stack position with the entrance of the first floor warehouse as the origin, where x is the x-direction distance of the center of the stack position from the entrance, y is the y-direction distance of the center of the stack position from the entrance, and z is the z-direction distance of the center of the stack position from the entrance.
[0070] The unique number m u of the stack position is calculated according to the following formula:
[0071] m u = f x M + m s , f ∈ [1, F], m s ∈ [1, M]
[0072] In the formula, F is the total number of floors, and M is the total number of stack positions in the single-layer warehouse.
[0073] At this point, after two mappings, each stack position in the warehouse is mapped into a unique code, and corresponds to a stack center coordinate.
[0074] Through the establishment of the space model, the stack position can be quickly located according to the stack position code, so as to arrange the storage of the raw materials, and provide a basis for subsequent calculation. At the same time, the space model can also be used for inventory analysis to predict the supply and consumption of tobacco raw materials, provide data support for production planning, and improve production efficiency and quality.
[0075] 2. Establish a task model
[0076] According to the warehouse plan of the procurement center, the tobacco raw material warehouse task is counted, and an initial batch warehouse task set T is established; for example, the initial task set T with a capacity of n is represented as:
[0077] T = {S1, S2,... S i ,..., S n}
[0078] where S i is the i-th task in the initial task set, corresponding to the i-th batch of tobacco warehouse entry order; n is the set capacity.
[0079] According to the use requirements, each batch of tobacco has attributes (N, R, K, C, P), and the meanings of each attribute are shown in Table 1:
[0080] Table 1. Warehouse task attributes
[0081] Number of raw materials N Number of tobacco raw material boxes Turnover rate R Indicates the average frequency of warehouse in and out of this batch of tobacco Raw material type K According to the origin, grade division Alcoholization speed C Determined by the nature of this raw material type Use cycle P Indicates the storage time of this batch of raw materials
[0082] Due to the large amount of tobacco raw materials N, considering the capacity of the stack and the complexity of the code, it is necessary to reasonably split the task in order to realize effective allocation and management.
[0083] Taking k boxes of tobacco raw materials as the basic unit, it is used as the sub-task granularity k for the secondary division of the initial task set T. The value of k is a discrete interval, and the capacity L of a single stack can be divided by k as the principle.
[0084] Specifically, the initial warehouse task set T can be split into a set composed of multiple sub-tasks, for example, for each task S i in the above warehouse task T, it can be split into a sub-task set T si :
[0085]
[0086] Taking k boxes of tobacco raw materials as the basic unit, it is used as the sub-task granularity k; the initial task set T is split into a sub-task set T si composed of multiple sub-tasks:
[0087]
[0088] where the tobacco attribute (R, K, C, P) of the task S ij is consistent with the parent task S i , and the raw material box number is updated to the result of the re-division accordingly;
[0089] The calculation rules and constraint conditions of the capacity n si of the sub-task set T si and the raw material box number N ij of the sub-task S ij are shown in the following formulas:
[0090] L mod k = 0, k E (0, L)
[0091]
[0092]
[0093]
[0094] In the above formulae: L is the capacity of the stack; mod is the modulo operator; N i is the number of raw material boxes of the parent task S i , N l is the remaining number of boxes after re-division, k is the granularity of the subtask, S ij is the jth task in the ith subtask set; N ij is the number of raw material boxes of the jth task in the ith subtask set; n si is the number of subtask sets divided by the ith parent task; T sub is the total task set after re-division.
[0095] 3. Establishing an optimization model
[0096] In view of the particularity of tobacco raw material storage and maintenance, the storage environment has a direct impact on the preservation and aging quality of tobacco raw materials. Therefore, the present application proposes an optimization objective suitable for tobacco raw material storage.
[0097] (1) First, the efficiency of the tobacco in and out of the warehouse needs to be considered, that is, the tobacco with high turnover rate is temporarily stored in a place close to the exit to realize fast in and fast out, and the total in and out time of the tobacco is represented as:
[0098]
[0099] In the above formula, v x , v y , v z are the in and out speeds in the x, y and z directions, respectively; x i , y i , z i are the distances of the ith batch of raw materials from the exit in the x, y and z directions, respectively; R i is the turnover rate of the ith batch of raw materials; n t is the total number of tasks after task division; i = 1 indicates that the calculation starts from the first batch.
[0100] (2) In the evaluation of tobacco aging quality, it is generally assumed that the aging degree of tobacco in the same batch is the same. However, due to the difference in actual storage environment, the aging speed and the quality after storage of tobacco in different floor stacks often differ. In order to ensure the stability of the quality of finished tobacco, it is necessary to ensure the centralized placement of the same tobacco as much as possible. Therefore, the present application introduces a tobacco raw material storage dispersion degree index to represent the consistency of the environment in which the raw materials are placed. The center coordinates are defined as follows:
[0101]
[0102] The overall dispersion degree is expressed as:
[0103]
[0104] In the above formulas, λ is an environmental coefficient set according to the difference in horizontal and vertical position environment, and the value range is [1, 5]; n k is the total number of tasks of the kth raw material; x ki , y ki , z ki are the distances of the i th batch of the kth raw material in the stack from the entrance and exit in the x, y, and z directions, respectively; i = 1 represents the calculation from the first batch; k n is the total number of raw material types; x kc , y kc , z kc are the distances of the center coordinates of the kth raw material in the x, y, and z directions from the entrance and exit, respectively.
[0105] (3) Generally, the temperature between floors is also different. For example, the temperature of the top floor of the warehouse is often higher than that of the bottom floor, and accordingly the tobacco aging speed will be faster. If the top floor is used to store tobacco with a larger guarantee month, it is necessary to provide a low-temperature environment through air conditioning to inhibit aging; on the contrary, if the bottom floor is used to store tobacco with a smaller guarantee month, it is also necessary to provide a high-temperature and high-oxygen environment to accelerate aging, thereby increasing energy consumption. Therefore, it is necessary to select a suitable floor for storing tobacco raw materials according to the aging speed, guarantee month, and floor conditions, so as to reduce energy consumption and improve the supply quality of tobacco raw materials.
[0106] The aging coefficient α zi of each floor is defined, and the standard aging value A std , then the tobacco aging quality evaluation function is as follows:
[0107] A i (x, y, z) = C i × P i × α zi
[0108] The overall aging quality evaluation function is expressed as:
[0109]
[0110] In the above formula, C i is the alcoholization speed of the i-th batch of raw materials; P i is the service life of the i-th batch of raw materials; alpha zi is the alcoholization coefficient of each floor, and the value range is [0, 1]; A i is the alcoholization degree of the i-th batch of tobacco leaves; A std is the standard alcoholization value; n t is the total number of tasks after task division; i=1 indicates that the calculation starts from the first batch.
[0111] (4) The storage utilization rate is also an important factor that needs to be considered in the allocation of tobacco raw materials into the warehouse, especially for areas where the cost of warehouse occupation is high. The improvement of the storage utilization rate is a key link for cost reduction and efficiency improvement. In order to improve the storage utilization rate, the greedy idea is adopted, and the principle of reserving as many idle stacking positions as possible for subsequent incoming materials is set. The storage utilization rate evaluation function is set as follows:
[0112]
[0113] In the above formula, U i is the amount of tobacco raw materials on the stacking position with the number i; C i is the total capacity of the stacking position; n t is the total number of tasks after task division; i=1 indicates that the calculation starts from the first batch. The formula is summed up for the utilization rate of each used stacking position to obtain the overall storage utilization rate.
[0114] After normalizing the evaluation functions, appropriate weights are set for the three evaluation functions, and the final optimization model is obtained as follows:
[0115] min f(x, y, z) = omega1f1(x, y, z) + omega2f2(x, y, z) + omega3f3(x, y, z) + omega4f4(x, y, z)
[0116] Since the optimization objective of the model needs to solve the minimum value, that is, the smaller the objective function, the higher the fitness of the chromosome, and the more inclined to be retained in the next round of iteration. Therefore, the reciprocal of the overall objective function is used as the fitness function of the genetic algorithm iteration for selecting excellent individuals in the parent generation to enter the offspring:
[0117]
[0118] 4. Genetic algorithm solution
[0119] For the problem of tobacco raw material stacking position allocation, the genetic algorithm is used to solve the optimal allocation scheme of the incoming warehouse. The specific operation process is as follows Figure 1As shown, it includes: generating an initial population, selection operation, crossover operation with correction strategy and mutation operation to produce a new population.
[0120] In the genetic algorithm solving process, the generation of the initial population can be determined according to historical data and actual demand to ensure the diversity and rationality of the population, at the same time, the space mapping coding is used to improve the readability of the algorithm and avoid invalid results. The selection operation adopts roulette selection, tournament selection and other methods to ensure the reservation and transmission of excellent individuals of each generation. The crossover operation adopts two-point crossover and introduces a correction strategy (such as Figure 2 As shown), avoid generating infeasible solutions, increase population diversity. The mutation operation adopts interval reverse sequence mutation method (such as Figure 3 As shown), increase the diversity and explorability of individuals, and the ability to expand the search range of the neighborhood. Through the above selection, crossover and mutation operations, a new population is generated to replace the last generation population. In the new population, individuals with higher fitness have a greater probability of being retained in the next generation, and individuals with lower fitness are eliminated.
[0121] The pallet allocation discussed in the application belongs to the 0-1 assignment problem. Due to the uncertainty of the subtask division granularity k, the pallet coding obtained by the space model cannot be directly applied to the chromosome coding of the genetic algorithm, and a third compatibility mapping needs to be made according to the subtask granularity k, dividing the n stacks into m sub-stacks, and coding the sub-stacks as 1-m:
[0122] m=(n×400) / k
[0123] Suppose that the capacity of the divided subtask set T sub is n, and the initial population size is m, then the initial solution set is an m*n matrix:
[0124] X=(g1,g2,g3,...,g m ) T
[0125] Wherein, each row vector g represents a chromosome, and each chromosome contains n elements, and the element value is the pallet number obtained by space mapping coding:
[0126] g i =(a i1 ,a i2 ,,a i3 ,...a in )
[0127] The chromosome crossing mode in the application is a double-point crossing with a correction strategy, that is, two crossing points are randomly selected on the chromosome to form a crossing interval, and the chromosome fragments in the crossing interval are exchanged. Due to the particularity of the warehouse location allocation model, the same stack location cannot have two batches of goods, so a certain correction strategy is needed to prevent the occurrence of illegal offspring. The correction strategy of the application is to traverse each element of the non-crossing interval of the parent chromosome, and perform a containing test with the crossing interval element set of the other chromosome and the element set of itself. If the element appears repeatedly, a random number is selected in the coding range until the element does not coincide with any element of the new chromosome. Since new elements other than the initial population are not generated in the population iteration process, it is easy to fall into local optimum. Therefore, compared with the strategy of directly discarding illegal solutions, the introduction of the crossing with the correction strategy can bring new elements to the population, expand the optimization range and enhance the ability of the algorithm to find the global optimal solution. The schematic diagram of the crossing operation in the genetic algorithm is shown in Figure 2 , and the flow chart is shown in Figure 3 .
[0128] The mutation strategy adopted in the application is to randomly select two mutation points to form a mutation interval, and to process the elements in the mutation interval in reverse order and reinsert them into the chromosome. The schematic diagram of the mutation operation is shown in Figure 4 .
[0129] A specific application example is as follows:
[0130] For a tobacco raw material warehouse in Zhejiang, the warehouse parameters are appropriately simplified and abstracted, and the basic parameters and floor parameters are as follows.
[0131] Basic parameters
[0132] Stack length 14m Stack width 7m Stack capacity 400 boxes Sub-task granularity 200 boxes Number of floors 8 Standard alcoholization value 1.8 X-direction speed 0.8 m / s Y-direction speed 1.0 m / s Z-direction speed 0.2 m / s Total number of sub-stacks 384
[0133] Floor parameters
[0134] Floor 1 2 3 4 5 6 7 8 Alcoholization coefficient 0.14 0.18 0.22 0.26 0.3 0.34 0.38 0.42
[0135] The raw materials entering the warehouse are divided into temporary storage tobacco with high turnover rate and no need for aging, and new tobacco with low turnover rate and a long aging period. According to the actual situation, the aging speed and use period of the temporary storage tobacco are both set to 0, and the turnover rate of the new tobacco is uniformly set to 0.02. The warehouse information is as follows:
[0136] Warehouse order information
[0137] Order number Number of raw materials Turnover rate Raw material type Alcoholization speed Use cycle 1 1500 0.02 1 0.25 24 2 180 0.3 2 0 0 3 150 0.6 3 0 0 4 1180 0.02 4 0.2 18 5 200 0.4 5 0 0 6 130 0.5 6 0 0 7 1100 0.02 7 0.4 24 8 150 0.7 8 0 0 9 180 0.8 9 0 0 10 1160 0.02 10 0.4 12 11 2000 0.02 11 0.7 12
[0138] The genetic algorithm parameters are selected as follows: the population size is 1000, the maximum number of iterations is 500, the crossover probability is 0.8, the mutation probability is 0.2, and the population convergence curve is as shown inFigure 5 The objective function value converges from 1.71 to 0.34 after 500 iterations, achieving more than 80% optimization effect. The allocation results are as follows:
[0139]
[0140]
[0141] It can be seen that the calculated warehouse allocation strategy has the following characteristics: 1. In terms of turnover rate, raw materials with high turnover rate are stored closer to the warehouse exit. 2. In terms of dispersion, the same kind of raw materials are placed more concentratedly. 3. In terms of aging quality, raw materials with fast aging speed and long use cycle are stored in lower floors to slow down aging, and raw materials with slow aging speed and short use cycle are stored in higher floors to speed up aging. 4. In terms of warehouse capacity utilization, since the sub-task granularity is 200 boxes, each stack is divided into two sub-stacks, and the optimized results greatly follow the principle of filling the used stack first to leave more free stack for subsequent incoming materials.
Claims
1. A tobacco leaf raw material storage allocation method based on spatial mapping genetic algorithm, characterized in that: The steps include: (1) Establishing a spatial model: Perform spatial mapping and encoding on each stack in the tobacco raw material warehouse to establish a spatial model; after actual spatial position mapping and key-value pair mapping, the actual spatial position of each stack is mapped to a unique code corresponding to the spatial coordinates; specifically including: (1.1) Mark each stack position with three-dimensional coordinates (f, r, c), where f is the number of floors, r is the number of rows of a single-story warehouse stack position, and c is the number of columns of a single-story warehouse stack position. (1.2) Based on the top view of the warehouse single-layer space layout, the lower left corner of the top view is defined as the stacking position 1 of the layer; similarly, the coordinates (f, r, c) are mapped to (f, m s ); where f is the number of floors, m s It is the unique number of the stack in a single-layer warehouse; (1.3) Based on the actual spatial position of each stack, (f, m s ) is mapped to key-value pairs (m u ,v); where m u is the unique number of the stack position in the entire warehouse; v is the spatial coordinates (x, y, z) of the center point of the stack position with the first-floor warehouse entrance as the origin, where x is the distance from the center of the stack position to the entrance in the x direction, y is the distance from the center of the stack position to the entrance in the y direction, and z is the distance from the center of the stack position to the entrance in the z direction; Calculate the unique number m of the stack position according to the following formula u : ; Where F is the total number of floors, and M is the total number of stacking spaces in a single-story warehouse; (2) Establishing a task model: According to the warehousing plan, the tobacco leaf raw material warehousing tasks are counted to form a batch warehousing task set. Then, according to actual usage needs, it is further divided into a set consisting of multiple subtasks. The task model for tobacco leaf raw material warehousing allocation is established in the following way: (2.1) Collect statistics on the warehousing tasks of tobacco leaf raw materials and establish the initial task set T for batch warehousing: ; Among them, S i is the i-th task in the initial task set, corresponding to the incoming order for the i-th batch of tobacco leaves; n is the set capacity; (2.2) Take k boxes of tobacco leaves as the basic unit and use it as the subtask granularity k; split the initial task set T into a subtask set T consisting of multiple subtasks si : ; Among them, task S ij The tobacco leaf attributes (R, K, C, P) and the parent task S i If they are consistent, the number of raw material boxes will be updated accordingly to the result after redivision; (2.3) Subtask set T si The capacity n si , Subtask S ij Number of raw material boxes N ij The calculation rules and constraints are shown in the following formulas: ; ; ; ; In the above formulas: is the stack capacity; mod is the modulus operator; N i Mother Mission S i Number of boxes of raw materials, is the number of remaining boxes after redivision, k is the subtask granularity, is the jth task in the i-th subtask set; is the number of raw material boxes for the jth task in the i-th subtask set; n si The number of subtasks divided from the i-th parent task; T sub is the total task set after redivision; (3) Establishing an optimization model: Based on the characteristics of tobacco leaf storage and maintenance, an optimization model was constructed to calculate the efficiency of storage and outgoing, the degree of dispersion of tobacco leaves of the same type, the aging quality and the storage capacity utilization rate. The tobacco leaf aging quality evaluation function is determined specifically according to the following method: The evaluation function of tobacco aging quality of each batch of tobacco leaves is expressed as: ; The overall alcoholization quality evaluation function is expressed as: ; In the above formulas, for ; is the aging coefficient of each floor, ranging from [0,1]; A i is the degree of aging of the i-th batch of tobacco leaves; A std is the standard alcoholization value; The total number of tasks after task division; i=1 means counting from the first batch; (4) Genetic algorithm solution The data sets of the spatial model, task model and optimization model are used as input and solved using genetic algorithm to obtain the optimal storage allocation plan.
2. The method according to claim 1, characterized in that In step (3), the total storage and outgoing time of tobacco leaf raw materials is calculated according to the following formula: ; In the above formula, v x 、v y 、v z They are the in-and-out speeds in the x, y, and z directions respectively; i 、y i 、z i are the distances between the stack location of the i-th batch of raw materials and the entrance and exit in the x, y, and z directions respectively; R i is the turnover rate of the i-th batch of raw materials; n t The total number of tasks after task division; i=1 means counting from the first batch.
3. The method according to claim 1, characterized in that In step (3), the degree of dispersion of the same type of tobacco raw materials during storage is calculated according to the following formula: The center coordinates are defined as follows: ; The overall dispersion is expressed as: ; In the above formulas, To set the environmental coefficient according to the degree of environmental difference between horizontal and vertical positions, the value range is [1,5]; is the total number of tasks for the kth raw material; x ki 、y ki 、z ki are the distances from the stack location of the i-th batch of the k-th raw material to the entrance and exit in the x, y, and z directions; i=1 means counting from the first batch; k n is the total number of raw material types; x kc 、y kc 、z kc are the distances between the center coordinates of the kth raw material and the entrance and exit in the x, y, and z directions respectively.
4. The method according to claim 1, wherein In step (3), the storage capacity utilization evaluation function is determined according to the following formula: ; In the above formula, is the quantity of tobacco leaf raw materials on the stack numbered i; is the total capacity of the stack; The total number of tasks after task division; i=1 means counting from the first batch.
5. The method according to claim 1, wherein In step (4), the genetic algorithm solution process includes: using the stack task granularity code to randomly initialize the population, calculate the individual fitness F of the population; then based on selection, crossover with correction strategy, mutation to generate a new population; after the maximum number of iterations is reached, decoding to obtain the optimal storage allocation plan; The optimal storage allocation plan is in array form, and the array size is the total number of tasks n t , the array subscript is the task number, and the array value is the globally unique number of stacks corresponding to the calculated placement location of this batch of raw materials; the effectiveness of the final warehousing plan is judged by evaluating its warehousing efficiency, the dispersion of similar raw materials, the alcoholization quality, and the storage capacity utilization rate.