# Optimal Crop Selection Using Gravitational Search Algorithm

Authors: Sikander Singh Cheema; Amardeep Singh; Hassène Gritli
Journal: Mathematical Problems in Engineering
 (2021)

---

## Abstract

For the economic growth of the crop, the optimal utilization of soil is found to be an open area of research. An efficient utilization includes various advantages such as watershed insurance, expanded biodiversity, and reduction of provincial destitution. Generally, soils present synthetic confinements for crop improvement. Therefore, in this paper, a novel diversified crop model is proposed to predict the suitable soil for good production of the crop. The proposed model utilizes a quantum value-based gravitational search algorithm (GSA) to optimize the best solution. Various features of soil are required to be investigated before crop selection. These features are refined further by applying quantum optimization. The crop selection based upon the soil requirement does not require any additional fertilizers which will reduce the production cost. Thus, the proposed model can select the optimal crop according to the soil components using the gravitational search algorithm. Therefore, the gravitational search algorithm is applied to the quantum values obtained from the crop and soil dataset. Extensive experiments show that the proposed model achieves an optimal selection of crops.


---

## Body

## 1. Introduction

For the better production of crops, an appropriate soil is required that can accomplish the required nutrients for that particular crop [1]. For this purpose, a crop-soil database is essential and an appropriate model should be established, the model through which one can select a particular crop based upon the given soil inputs. In total, there are nine parameters for the properties of soil. Based on these parameters, soils can be distinguished. Some physical properties of soil may include clay, silt, and sand. Some chemical properties of soil may include its pH value and salinity class. Marco elements like potash, nitrogen, and phosphate are also important for the growth of plants. The main aim of this study is to build a crop diversification model for Indian Punjab’s farmers. Therefore that, they can be skillful in the automatic selection of crops depending on the given soil data using the gravitational search algorithm (GSA) [2, 3].The relation between soil and crop is very stronger. Whenever farmers plan to grow any crop, then firstly, they will see the relation between crop and the soil components. Once the values have been checked, they are put into the system. Afterward, the system will help them by providing suggestions about the suitable order of crops for that particular soil [4, 5]. In such a manner, the crops require less input for production and give more yield. Through this process, farmers can save a lot of money. And different types of crops will be grown by farmers in different types of soil. Thus, in such a manner, a crop diversification mechanism can be attained [6, 7].In common circumstances for crop improvement, soils present chemical limitations. Chemical soil tests are taken into consideration to provide data related to acidity and supplement levels of each land section [8, 9]. pH value describes the presence of acidity and alkalinity in soil [10]. pH levels of soil range between 0 and 14. When the pH value is 7, the soil shows natural behavior, above 7 the soil shows alkaline behavior and below 7 the soil is acidic. For most of the plants, the pH value must range between 5.5 and 7.0.The regular updates on soil chemical attributes demand a dynamic change in the supplements and groundwater archives. Therefore, the general condition should be checked according to the requirements of crop [11, 12]. Thus, deciding which crop will best fit concerning chemical attributes is defined as an ill-posed problem [13]. Then, agriculturists again want to develop crops to obtain the most ideal return and the least monetary hazard [14].In short, the farmer has to be very selective in choosing the best soil with minimum fertilizers and other chemicals for one crop. In this way, they will be able to get a good income with less investment [15, 16]. The perfect utilization of soil is the foundation of all forms of maintainable land. There are several benefits of an ideal utilization of soils like watershed assurance, feasible agrarian generation, a decline of rustic neediness, expanded biodiversity, and security [17, 18].The rest of the paper is organized as follows. Section2 illustrates the related work. Techniques used for optimization are discussed in section 3. The proposed technique and the related dataset are presented in section 4. The performance analysis and scope are given in section 5. The concluding remarks are present in section 6.


## 2. Related Works

In this section, the literature review is done for crop-soil relations using GSA. Some existing works of various authors are discussed and compared with the proposed work.Han et al. [19] presented a new method known as feature subset selection in machine learning, FSS-MGSA. It is one of the widely accepted search algorithms, which is founded on the law of gravity and mass interactions between the two agents. When domain knowledge is not available, this can be used for better results. This approach can be used over ID3, Naive Bayes, K-Nearest Neighbor, and SVM to evaluate the best solution.Jiang et al. [4] revealed that the gravitational search algorithm is good for resolving numerous problems of optimization. However, GSA suffers from premature merging when resolving difficult problems. In this paper, an improved gravitational search algorithm (IGSA) was first employed through an operator and then considers memory policies for overcoming the problem.Sun et al. [2] noted that GSA is one of the prevalent evolutionary computation methods, which has been broadly active in data management. However, the basic GSA demonstrates a good exploration search but weak exploitation search. To promote the exploitation capability of GSA, the authors in [2] have introduced a modified GSA with crossover. In their search process, CROGSA executes the crossover-based search scheme to update the position of each solution.Rashedi et al. [20] represented that the gravitational search algorithm has been positively functional to several scientific and engineering tenders in the last years. For the GSA and most of its deviations, every agent learns from the agents stored in the same elite group, namely, Kbest. Such type of learning policy is in nature a fully informed learning strategy, where each agent has the closed the same global neighborhood topology structure.Some other works of Prof. Kumar and his coworkers using the gravitational search algorithm and for different applications can be found, for example, in [21–24].


### 2.1. The Decision Support System for Agrotechnology Transfer Model

In numerous nations of the world, farming is an essential monetary action. Incredible quantities of individuals rely upon farming for their occupation. There is a constant strain to improve agricultural development because of stunning increments in the human populace. Farming is especially affected by the predominant climate and atmosphere. This requires an efficient evaluation of climatic and soil assets to rework a strong land usage proposal. More than ever, agriculturalists over the world need access to alternatives, for example, management choices of new commercial crops. Regularly, the objective is to get more significant returns from the crops and the possibility of growing a crop for a particular soil. Parallel to this, rotation of crops should be the main target to avoid the degradation of soil. Likewise, while sustaining the yield levels, they want to(a)
Substantially improves the income(b)
Reduce soil degradation(c)
Exploit local market opportunitiesTo fulfill the abovementioned points of poor farmers in the tropics and subtropics, a group having named IBSNAT (International Benchmark Sites Network for Agrotechnology Transfer) started work in this direction in 1982. The purposes defined for the IBSNAT project by its technical advisory committee were to(1)
Comprehend ecosystem procedures and components;(2)
Incorporate from a comprehension of procedures and instruments, and ability to foresee results;(3)
Empower IBSNAT customers to put on the prescient ability to control results. In this regard, IBSNAT was a project on systems analysis and simulation as a way to provide users with options for change. In this project, many research institutions, universities, and researchers spent an enormous amount of time and resources and focused on:(a)
Creation of a “decision support system” capable of simulating the risks and outcomes of elective decisions, through multiinstitute and multidisciplinary approaches(b)
Definition of the minimum amount of data required for running simulations and assessing outcomes(c)
Testing and application of the product to global agricultural problems require site-specific yield simulationsThe significant result of IBSNAT was a decision support system for agrotechnology transfer (DSSAT) [25]. This recommended system is utilized as a research and educating tool. DSSAT is a group of autonomous programs that operate together, and crop simulation models are at its center [25].DSSAT [25] has been being used throughout the previous 15 years by scientists. Figure 1 shows that the DSSAT package includes models of 16 different crops with software that encourages the assessment and use of the crop models for various purposes. During the most recent couple of years, it has gotten progressively hard to maintain the DSSAT crop models, partly because of the actuality that there were different sets of computer code for various crops with little attention to software design at the level of crop models themselves. Complete explanation of the DSSAT cropping system model is presented in Figure 2 [25].Figure 1
Illustration of databases, applications, and support software components of the DSSAT model.Figure 2
Outline of the components and modular structure of the DSSAT-CSM.


#### 2.1.1. The Agricultural Production System Simulator

This model is developed to provide an accurate prediction of crop production by observing climate, soil, and management factors. One of the most active areas of this model is related to soil, in which soil water, soil nitrogen, soil phosphorus, soil pH, and erosion modules are involved. In the APSIM model, with the help of the soil’s pH module, one can represent the acidification of soil and the value of pH changes randomly [26].


### 2.2. InfoCrop Model

InfoCrop model is a powerful recreation model for the evaluation of crop yield disasters of insects and the ecological effect of agro-biological systems in tropical situations. The issues of agribusiness in numerous tropical nations are getting progressively extreme step by step because of expanding food requests driven by populace development, stagnation in ranch profitability, and mounting yield misfortunes because of different irritations, expanding defenselessness to worldwide natural changes, and the need to diminish the emanation of ozone-depleting substances. Instruments and procedures are expected to help with creating systems that can prompt higher food creation, forestall crop creation misfortunes, and guarantee insignificant ozone harming substance emanations while keeping up soil ripeness. InfoCrop, a conventional powerful crop model, has been created to fulfill the particular necessity [27]. It gives an incorporated evaluation of the impact of climate, assortment, nuisances, soil, and management’s practices on crop development and yield, such as on soil nitrogen and natural carbon elements in high-impact just anaerobic conditions and ozone-depleting substance discharges.The Soi Texture Mater module contains detailed information about various attributes of the soil. The values of various attributes of soil are needed to put layerwise in the model. Soil attributes of every layer contain different values. This module gives information to the farmers about all available nutrients of the soil at different layers. This information will be useful for a farmer to plant his/her crop at the proper depth. In this way, a farmer will get a high yield of a crop by sowing at the proper required depth.


### 2.3. Cropping System Simulation Model (CropSyst)

CropSyst (cropping system simulation model) is a user-friendly, conceptually simple but sound multiyear, multicrop, everyday time stage cropping system simulation model created to fill in as an investigative device to examine the impact of atmosphere and soil on cropping system efficiency [28]. The CropSyst recreates the soil water and nitrogen spending plants, crop development and advancement, crop yield, residue production and disintegration, soil disintegration by water, and saltiness. The improvement of the CropSyst began in the mid-1990s, developing to a set-up of projects including a cropping framework test system, a climate generator, the GIS-CropSyst cooperator program, a watershed model, and a few various utility projects. One key component of the CropSyst is the usage of a conventional crop system that empowers the recreation of both annual and multiannual crops and crop rotation utilizing a solitary arrangement of parameters. The reenactments can last a small amount of a year to several years. The model has been assessed in various areas by contrasting model evaluations with information gathered in field tests. The CropSyst has been applied to perform chance and monetary investigations of situations including diverse cropping frameworks, executive’s alternatives, and soil and climatic conditions. The CropSyst is a user-friendly model written in C++.


#### 2.3.1. Functionality of CropSyst

A menu strip is available in this model for various operations. Menu and submenu choices might be chosen with the mouse. Extra capacities shown in the status line at the base of the screen are regularly accessible by squeezing the particular capacity key or key grouping or by determination with the mouse. A few menu choices can be actuated straightforwardly from the console. The menu alternative will show that a key arrangement can be squeezed to enact the choice [29]. Extra tasks that can be initiated from the console might be shown in the status line. The main menu gives the following options: (a) File, (b) Window, (c) Control, (d) Management, (e) Soil, (f) Crop, and (g) Location.


#### 2.3.2. Soil Module

The CropSyst simulation model requires only minimal initialization parameters to provide initial soil water, nitrogen, and organic matter profiles. Soil module parameter window is shown in Figure3.Figure 3
Soil module parameter window.


#### 2.3.3. Simulation Control

This module handles the simulation documents that contain data, permitting the client to fabricate simulation conditions from an existing area’s database, soil yield, and supervision records. The simulation documents likewise contain data concerning the time of simulation and initial values for model factors that require initialization. The simulation documents are made and altered utilizing the recreation control parameter supervisor. This editor permits the client to join segment parameter records to fabricate the recreation run and to alter the introduction constraints. The essential components to construct a reproduction control record comprise the time of recreation and particulars of soil area and crop diversification strategies. The part records are chosen by squeezing the filename button and utilizing the file requestor to pick the particular files. The Edit button close to the filename button will permit the as of now the chosen record to be altered. The simulation control parameter window is shown in Figure4.Figure 4
Simulation control parameter window.The agricultural district can be considered as an assortment of individual fields that shift in ecological conditions and management practices. A daily increment in population request induces an increase in agricultural creation with accessible assets. Proficient administration of accessible assets to variable climate conditions is fundamental to expand the profitability of farming. Likewise, the focal point of agrarian creation is changing from an amount towards quality and supportability. Arrangement of these new difficulties requires the thought of how various segments cooperate to impact plant development. These changes power ranchers and agrarian counselors to manage to expand the greater part of data. They have to break down immense and inconsistently found data assets. The data collection process is lumbering and at times questionable. Frequently, the task to choose, consolidate, and break down the data is demanding. As information technology has opened up new challenges to computerize information and investigation, computer programs that reproduce the crop development or yield of crops under various management systems assist ranchers with settling on specialized choices to deal with their crops better. These models are broadly applied to gauge the effect of the atmosphere, soil, and agricultural managements on yield, water and nitrogen balance, dry spell adjustment, and other cropping system issues in various areas.


## 2.1. The Decision Support System for Agrotechnology Transfer Model

In numerous nations of the world, farming is an essential monetary action. Incredible quantities of individuals rely upon farming for their occupation. There is a constant strain to improve agricultural development because of stunning increments in the human populace. Farming is especially affected by the predominant climate and atmosphere. This requires an efficient evaluation of climatic and soil assets to rework a strong land usage proposal. More than ever, agriculturalists over the world need access to alternatives, for example, management choices of new commercial crops. Regularly, the objective is to get more significant returns from the crops and the possibility of growing a crop for a particular soil. Parallel to this, rotation of crops should be the main target to avoid the degradation of soil. Likewise, while sustaining the yield levels, they want to(a)
Substantially improves the income(b)
Reduce soil degradation(c)
Exploit local market opportunitiesTo fulfill the abovementioned points of poor farmers in the tropics and subtropics, a group having named IBSNAT (International Benchmark Sites Network for Agrotechnology Transfer) started work in this direction in 1982. The purposes defined for the IBSNAT project by its technical advisory committee were to(1)
Comprehend ecosystem procedures and components;(2)
Incorporate from a comprehension of procedures and instruments, and ability to foresee results;(3)
Empower IBSNAT customers to put on the prescient ability to control results. In this regard, IBSNAT was a project on systems analysis and simulation as a way to provide users with options for change. In this project, many research institutions, universities, and researchers spent an enormous amount of time and resources and focused on:(a)
Creation of a “decision support system” capable of simulating the risks and outcomes of elective decisions, through multiinstitute and multidisciplinary approaches(b)
Definition of the minimum amount of data required for running simulations and assessing outcomes(c)
Testing and application of the product to global agricultural problems require site-specific yield simulationsThe significant result of IBSNAT was a decision support system for agrotechnology transfer (DSSAT) [25]. This recommended system is utilized as a research and educating tool. DSSAT is a group of autonomous programs that operate together, and crop simulation models are at its center [25].DSSAT [25] has been being used throughout the previous 15 years by scientists. Figure 1 shows that the DSSAT package includes models of 16 different crops with software that encourages the assessment and use of the crop models for various purposes. During the most recent couple of years, it has gotten progressively hard to maintain the DSSAT crop models, partly because of the actuality that there were different sets of computer code for various crops with little attention to software design at the level of crop models themselves. Complete explanation of the DSSAT cropping system model is presented in Figure 2 [25].Figure 1
Illustration of databases, applications, and support software components of the DSSAT model.Figure 2
Outline of the components and modular structure of the DSSAT-CSM.


### 2.1.1. The Agricultural Production System Simulator

This model is developed to provide an accurate prediction of crop production by observing climate, soil, and management factors. One of the most active areas of this model is related to soil, in which soil water, soil nitrogen, soil phosphorus, soil pH, and erosion modules are involved. In the APSIM model, with the help of the soil’s pH module, one can represent the acidification of soil and the value of pH changes randomly [26].


## 2.1.1. The Agricultural Production System Simulator

This model is developed to provide an accurate prediction of crop production by observing climate, soil, and management factors. One of the most active areas of this model is related to soil, in which soil water, soil nitrogen, soil phosphorus, soil pH, and erosion modules are involved. In the APSIM model, with the help of the soil’s pH module, one can represent the acidification of soil and the value of pH changes randomly [26].


## 2.2. InfoCrop Model

InfoCrop model is a powerful recreation model for the evaluation of crop yield disasters of insects and the ecological effect of agro-biological systems in tropical situations. The issues of agribusiness in numerous tropical nations are getting progressively extreme step by step because of expanding food requests driven by populace development, stagnation in ranch profitability, and mounting yield misfortunes because of different irritations, expanding defenselessness to worldwide natural changes, and the need to diminish the emanation of ozone-depleting substances. Instruments and procedures are expected to help with creating systems that can prompt higher food creation, forestall crop creation misfortunes, and guarantee insignificant ozone harming substance emanations while keeping up soil ripeness. InfoCrop, a conventional powerful crop model, has been created to fulfill the particular necessity [27]. It gives an incorporated evaluation of the impact of climate, assortment, nuisances, soil, and management’s practices on crop development and yield, such as on soil nitrogen and natural carbon elements in high-impact just anaerobic conditions and ozone-depleting substance discharges.The Soi Texture Mater module contains detailed information about various attributes of the soil. The values of various attributes of soil are needed to put layerwise in the model. Soil attributes of every layer contain different values. This module gives information to the farmers about all available nutrients of the soil at different layers. This information will be useful for a farmer to plant his/her crop at the proper depth. In this way, a farmer will get a high yield of a crop by sowing at the proper required depth.


## 2.3. Cropping System Simulation Model (CropSyst)

CropSyst (cropping system simulation model) is a user-friendly, conceptually simple but sound multiyear, multicrop, everyday time stage cropping system simulation model created to fill in as an investigative device to examine the impact of atmosphere and soil on cropping system efficiency [28]. The CropSyst recreates the soil water and nitrogen spending plants, crop development and advancement, crop yield, residue production and disintegration, soil disintegration by water, and saltiness. The improvement of the CropSyst began in the mid-1990s, developing to a set-up of projects including a cropping framework test system, a climate generator, the GIS-CropSyst cooperator program, a watershed model, and a few various utility projects. One key component of the CropSyst is the usage of a conventional crop system that empowers the recreation of both annual and multiannual crops and crop rotation utilizing a solitary arrangement of parameters. The reenactments can last a small amount of a year to several years. The model has been assessed in various areas by contrasting model evaluations with information gathered in field tests. The CropSyst has been applied to perform chance and monetary investigations of situations including diverse cropping frameworks, executive’s alternatives, and soil and climatic conditions. The CropSyst is a user-friendly model written in C++.


### 2.3.1. Functionality of CropSyst

A menu strip is available in this model for various operations. Menu and submenu choices might be chosen with the mouse. Extra capacities shown in the status line at the base of the screen are regularly accessible by squeezing the particular capacity key or key grouping or by determination with the mouse. A few menu choices can be actuated straightforwardly from the console. The menu alternative will show that a key arrangement can be squeezed to enact the choice [29]. Extra tasks that can be initiated from the console might be shown in the status line. The main menu gives the following options: (a) File, (b) Window, (c) Control, (d) Management, (e) Soil, (f) Crop, and (g) Location.


### 2.3.2. Soil Module

The CropSyst simulation model requires only minimal initialization parameters to provide initial soil water, nitrogen, and organic matter profiles. Soil module parameter window is shown in Figure3.Figure 3
Soil module parameter window.


### 2.3.3. Simulation Control

This module handles the simulation documents that contain data, permitting the client to fabricate simulation conditions from an existing area’s database, soil yield, and supervision records. The simulation documents likewise contain data concerning the time of simulation and initial values for model factors that require initialization. The simulation documents are made and altered utilizing the recreation control parameter supervisor. This editor permits the client to join segment parameter records to fabricate the recreation run and to alter the introduction constraints. The essential components to construct a reproduction control record comprise the time of recreation and particulars of soil area and crop diversification strategies. The part records are chosen by squeezing the filename button and utilizing the file requestor to pick the particular files. The Edit button close to the filename button will permit the as of now the chosen record to be altered. The simulation control parameter window is shown in Figure4.Figure 4
Simulation control parameter window.The agricultural district can be considered as an assortment of individual fields that shift in ecological conditions and management practices. A daily increment in population request induces an increase in agricultural creation with accessible assets. Proficient administration of accessible assets to variable climate conditions is fundamental to expand the profitability of farming. Likewise, the focal point of agrarian creation is changing from an amount towards quality and supportability. Arrangement of these new difficulties requires the thought of how various segments cooperate to impact plant development. These changes power ranchers and agrarian counselors to manage to expand the greater part of data. They have to break down immense and inconsistently found data assets. The data collection process is lumbering and at times questionable. Frequently, the task to choose, consolidate, and break down the data is demanding. As information technology has opened up new challenges to computerize information and investigation, computer programs that reproduce the crop development or yield of crops under various management systems assist ranchers with settling on specialized choices to deal with their crops better. These models are broadly applied to gauge the effect of the atmosphere, soil, and agricultural managements on yield, water and nitrogen balance, dry spell adjustment, and other cropping system issues in various areas.


## 2.3.1. Functionality of CropSyst

A menu strip is available in this model for various operations. Menu and submenu choices might be chosen with the mouse. Extra capacities shown in the status line at the base of the screen are regularly accessible by squeezing the particular capacity key or key grouping or by determination with the mouse. A few menu choices can be actuated straightforwardly from the console. The menu alternative will show that a key arrangement can be squeezed to enact the choice [29]. Extra tasks that can be initiated from the console might be shown in the status line. The main menu gives the following options: (a) File, (b) Window, (c) Control, (d) Management, (e) Soil, (f) Crop, and (g) Location.


## 2.3.2. Soil Module

The CropSyst simulation model requires only minimal initialization parameters to provide initial soil water, nitrogen, and organic matter profiles. Soil module parameter window is shown in Figure3.Figure 3
Soil module parameter window.


## 2.3.3. Simulation Control

This module handles the simulation documents that contain data, permitting the client to fabricate simulation conditions from an existing area’s database, soil yield, and supervision records. The simulation documents likewise contain data concerning the time of simulation and initial values for model factors that require initialization. The simulation documents are made and altered utilizing the recreation control parameter supervisor. This editor permits the client to join segment parameter records to fabricate the recreation run and to alter the introduction constraints. The essential components to construct a reproduction control record comprise the time of recreation and particulars of soil area and crop diversification strategies. The part records are chosen by squeezing the filename button and utilizing the file requestor to pick the particular files. The Edit button close to the filename button will permit the as of now the chosen record to be altered. The simulation control parameter window is shown in Figure4.Figure 4
Simulation control parameter window.The agricultural district can be considered as an assortment of individual fields that shift in ecological conditions and management practices. A daily increment in population request induces an increase in agricultural creation with accessible assets. Proficient administration of accessible assets to variable climate conditions is fundamental to expand the profitability of farming. Likewise, the focal point of agrarian creation is changing from an amount towards quality and supportability. Arrangement of these new difficulties requires the thought of how various segments cooperate to impact plant development. These changes power ranchers and agrarian counselors to manage to expand the greater part of data. They have to break down immense and inconsistently found data assets. The data collection process is lumbering and at times questionable. Frequently, the task to choose, consolidate, and break down the data is demanding. As information technology has opened up new challenges to computerize information and investigation, computer programs that reproduce the crop development or yield of crops under various management systems assist ranchers with settling on specialized choices to deal with their crops better. These models are broadly applied to gauge the effect of the atmosphere, soil, and agricultural managements on yield, water and nitrogen balance, dry spell adjustment, and other cropping system issues in various areas.


## 3. Proposed Optimization Technique

The optimization techniques have the ability to compute complex relationships among soil and plants for better crop diversification. It helps in controlling the maximum beneficial crop design [30]. For simulating the soil-plant systems, a computer-based model with various new mathematical optimization techniques is required. The effective tool for facilitating crop diversification is planners for making sound decisions before each crop season. The main goal of crop diversification is to get numerous crops instead of only one or two [31]. Thereafter, a crop is selected in such a way so that it gives maximum production with minimum investment [32].Optimization techniques are used for taking attention towards the complex issues in asset portion, transportation and coordination’s venture choice, arranging, and scheduling. These problems are extensively utilized in manufacturing and business sectors [33]. However, there exist similar optimization problems in agricultural systems such as crop selection [7], country-wide crop planning [34], irrigation planning [35], vegetable production [36], and sugarcane transportation [20]. The optimization problems are defined as mathematical programming models to optimize a predefined engineering problem [37]. These models range from single to multiobjective and from direct to nonstraight forms. The optimization methods [29] used in the study range from conventional methods to computational intelligence (CI) techniques such as genetic/evolutionary algorithms [38, 39].In this paper, we have proposed GSA for optimal crop selection for the particular type of soil. Due to the inherent parallelism, self-organization, adaptation, and self-learning features of the EAs, they have been applied successfully to solve many problems where the classical approaches are either unavailable or generally lead to unsatisfactory results. The reason behind choosing GSA is that it has succeeded to solve many optimization problems in recent years [19, 32].


### 3.1. Gravitational Search Algorithm

#### 3.1.1. Brief Description

Galileo was the one who founded the concept of gravitation and further Newton and Albert Einstein also researched a lot in this area [40]. In general, mass is the volume of matter in a given object. There are three types of masses which are inertial mass, gravitational mass, and passive gravitational mass. Newton was the one who directed that every particle attracts other particles with some amount of force. These particles are directly proportional to the product of the active mass of that particle and inversely proportional to the square of the distance between both particles. When the force is applied to an object, the resulting acceleration depends on both force and the inertial mass of the object. For the motivation of GSA, gravity and mass concepts are to be used [41, 42].Rashedi was the one who firstly worked for making the gravitational search algorithm (GSA) [20]. In GSA, the agents who perform search work are considered objects with a specific mass where every object in the system relates to other objects by some gravitational force. The agent’s position helps in presenting the candidate solution for the problem whereas the mass of the agent is given during an objective function. The movement of all objects is done with the help of the gravitational force in achieving the suboptimal solution [20]. The main idea of GSA is explained in the following steps:(a)
It is created by the law of mass and gravity relations.(b)
The agents in GSA are the solution [20], and these agents work together with each other through the gravity force.(c)
The mass helps in determining the performance of each agent.(d)
Agents in the population are called to be objects, and these objects always attract each other. The object with a heavier mass will attract others because of the gravity force.(e)
The agents who have low mass will move slowly as compared with agents having greater weight.(f)
The agent with a heavier mass helps in providing the best solution.


#### 3.1.2. Gravitational Search Algorithm Flow Chart

Figure5 shows the flowchart of GSA. Firstly, a random population is generated. Afterward, evaluate the fitness of the population. Update the best and worst among the populations. Then, calculate M and A for each agent that has been selected. Update the agent’s position and velocity. Lastly, if the agent is meeting all requirements, then turn up with the best solution; otherwise, again restart from evaluating the fitness value step. Algorithm 1 demonstrates the working of GSA.Figure 5
Flowchart of GSA.Algorithm 1:Gravitational search algorithm.
parameters initializationset the initial values of gravitational constant Go,Set the initial iterationt=oInitial populationFori=1;<=NdoGenerate in initial populationXi randomly, whereEnd forRepeatsolution and evaluationEvaluate the fitness functionfXit for each in the population XitAssign the best worst agent in the populationXitSolutions updateUpdate the gravitational constant GFori=1;Ndo Calculate the force acting on agent i from agent jEnd forCompute the total forces that acts on agenti,Compute the inertial massMi.Compute the acceleration of agentIUpdate the velocity of the agentiUpdate the position of agentIEnd forSett=t+1until termination criteria are satisfiedproduce the best solutionReturn the best solution


## 3.1. Gravitational Search Algorithm

### 3.1.1. Brief Description

Galileo was the one who founded the concept of gravitation and further Newton and Albert Einstein also researched a lot in this area [40]. In general, mass is the volume of matter in a given object. There are three types of masses which are inertial mass, gravitational mass, and passive gravitational mass. Newton was the one who directed that every particle attracts other particles with some amount of force. These particles are directly proportional to the product of the active mass of that particle and inversely proportional to the square of the distance between both particles. When the force is applied to an object, the resulting acceleration depends on both force and the inertial mass of the object. For the motivation of GSA, gravity and mass concepts are to be used [41, 42].Rashedi was the one who firstly worked for making the gravitational search algorithm (GSA) [20]. In GSA, the agents who perform search work are considered objects with a specific mass where every object in the system relates to other objects by some gravitational force. The agent’s position helps in presenting the candidate solution for the problem whereas the mass of the agent is given during an objective function. The movement of all objects is done with the help of the gravitational force in achieving the suboptimal solution [20]. The main idea of GSA is explained in the following steps:(a)
It is created by the law of mass and gravity relations.(b)
The agents in GSA are the solution [20], and these agents work together with each other through the gravity force.(c)
The mass helps in determining the performance of each agent.(d)
Agents in the population are called to be objects, and these objects always attract each other. The object with a heavier mass will attract others because of the gravity force.(e)
The agents who have low mass will move slowly as compared with agents having greater weight.(f)
The agent with a heavier mass helps in providing the best solution.


### 3.1.2. Gravitational Search Algorithm Flow Chart

Figure5 shows the flowchart of GSA. Firstly, a random population is generated. Afterward, evaluate the fitness of the population. Update the best and worst among the populations. Then, calculate M and A for each agent that has been selected. Update the agent’s position and velocity. Lastly, if the agent is meeting all requirements, then turn up with the best solution; otherwise, again restart from evaluating the fitness value step. Algorithm 1 demonstrates the working of GSA.Figure 5
Flowchart of GSA.Algorithm 1:Gravitational search algorithm.
parameters initializationset the initial values of gravitational constant Go,Set the initial iterationt=oInitial populationFori=1;<=NdoGenerate in initial populationXi randomly, whereEnd forRepeatsolution and evaluationEvaluate the fitness functionfXit for each in the population XitAssign the best worst agent in the populationXitSolutions updateUpdate the gravitational constant GFori=1;Ndo Calculate the force acting on agent i from agent jEnd forCompute the total forces that acts on agenti,Compute the inertial massMi.Compute the acceleration of agentIUpdate the velocity of the agentiUpdate the position of agentIEnd forSett=t+1until termination criteria are satisfiedproduce the best solutionReturn the best solution


## 3.1.1. Brief Description

Galileo was the one who founded the concept of gravitation and further Newton and Albert Einstein also researched a lot in this area [40]. In general, mass is the volume of matter in a given object. There are three types of masses which are inertial mass, gravitational mass, and passive gravitational mass. Newton was the one who directed that every particle attracts other particles with some amount of force. These particles are directly proportional to the product of the active mass of that particle and inversely proportional to the square of the distance between both particles. When the force is applied to an object, the resulting acceleration depends on both force and the inertial mass of the object. For the motivation of GSA, gravity and mass concepts are to be used [41, 42].Rashedi was the one who firstly worked for making the gravitational search algorithm (GSA) [20]. In GSA, the agents who perform search work are considered objects with a specific mass where every object in the system relates to other objects by some gravitational force. The agent’s position helps in presenting the candidate solution for the problem whereas the mass of the agent is given during an objective function. The movement of all objects is done with the help of the gravitational force in achieving the suboptimal solution [20]. The main idea of GSA is explained in the following steps:(a)
It is created by the law of mass and gravity relations.(b)
The agents in GSA are the solution [20], and these agents work together with each other through the gravity force.(c)
The mass helps in determining the performance of each agent.(d)
Agents in the population are called to be objects, and these objects always attract each other. The object with a heavier mass will attract others because of the gravity force.(e)
The agents who have low mass will move slowly as compared with agents having greater weight.(f)
The agent with a heavier mass helps in providing the best solution.


## 3.1.2. Gravitational Search Algorithm Flow Chart

Figure5 shows the flowchart of GSA. Firstly, a random population is generated. Afterward, evaluate the fitness of the population. Update the best and worst among the populations. Then, calculate M and A for each agent that has been selected. Update the agent’s position and velocity. Lastly, if the agent is meeting all requirements, then turn up with the best solution; otherwise, again restart from evaluating the fitness value step. Algorithm 1 demonstrates the working of GSA.Figure 5
Flowchart of GSA.Algorithm 1:Gravitational search algorithm.
parameters initializationset the initial values of gravitational constant Go,Set the initial iterationt=oInitial populationFori=1;<=NdoGenerate in initial populationXi randomly, whereEnd forRepeatsolution and evaluationEvaluate the fitness functionfXit for each in the population XitAssign the best worst agent in the populationXitSolutions updateUpdate the gravitational constant GFori=1;Ndo Calculate the force acting on agent i from agent jEnd forCompute the total forces that acts on agenti,Compute the inertial massMi.Compute the acceleration of agentIUpdate the velocity of the agentiUpdate the position of agentIEnd forSett=t+1until termination criteria are satisfiedproduce the best solutionReturn the best solution


## 4. Performance Analysis

The soil’s attribute values are used to determine a suitable crop for a particular field. The values of all required soil attributes can be obtained by testing the soil in the soil testing laboratory. After getting the values of the soil’s attributes, one will give an input of these soil’s attributes to the proposed decision support system for crop diversification (DSSCD) model. Based on the input values, a list of crops in a particular order according to the crop preferences for soil properties will be displayed as shown in the graph (see Figure6). A farmer can select the best suitable crop from the list for his/her field. In this way, a farmer can go for a crop with the best suitability of soil and which will take less chemical fertilizer. If a farmer belongs to an area where groundwater, as well as canal water, is less than the requirement, then he/she can choose a crop that consumes less water. In this way, crop diversification can be achieved by using this model, which is the need of the hour.Figure 6
Crop soil relationship.In Figure6, a relationship between crop and soil’s attributes has been shown. The soil’s attributes help in finding out a list of crops for a particular type of soil. If the soil is suited for a crop, then definitely less input of chemical fertilizer will be required. On the other hand, if the soil is not well suited for the cultivation of a crop, then definitely more inputs of chemical fertilizers and more efforts will be required to get the best results. As a result, in this case, the cost of production would be higher. The proposed technique used in the DSSCD model helps to detect a list of crops suitable for a particular type of soil to get high production.


### 4.1. Verification and Validation

Verification is a process of checking the syntax and semantics errors in the final product. At this stage, developers have to make sure that the model is bug-free and should execute properly. It is a static process. The researcher has checked that the proposed decision support system for crop diversification (DSSCD) model is properly framed and bug-free and found very useful for end-users.Validation is a dynamic process. This process is used to check whether the proposed model is fulfilling the requirements of the customer. Validation is used to authenticate the output of a system. The proposed DSSCD model is validated and meets the final customers’ expectations. For the authentication of the proposed DSSCD model, various samples of the soil have been taken from different regions of Indian Punjab as shown in Table1. Values of the different attributes of soil are entered as input to the proposed model, and the output from this model shows that it meets the final customers’ expectations and requirements. Therefore, the output of this system is tested in various ways to get the optimal results. For various inputs as shown in Table 1, it is validated that this system gives a list of suitable crops for a given particular type of soil according to crop-soil dataset. Note that in Table 1, S.N.∗ stands for Sample Number, N∗ stands for Nitrogen, P∗ refers to Phosphorus, and K∗ stands for Potassium. Moreover, the unit of nitrogen, phosphorus, and potassium is kilogram/hectare.Table 1
Soil samples of Indian Punjab.
S.N.∗pHECSCSandSiltClayTextureN∗P∗K∗16.716112.33354.6172608626.68612516.458.4776367536.3811015.36.278.4741322445.7511363.910.325.7555722755.076212.33354.6959583965.038029.828.241.8480446776.415045.54410.4482669685.411034.31451.5498688296.171027622.71.244079100106.9910140.614.744.52653458115.065136.25.658.12389077125.580144.930.324.76705048136.195243.933.222.76392629145.612034.231.434.24896220156.998037.125.437.33667989165.428132.626.640.63578736176.15435.71777.19862179185.631123.31858.69945959195.35107712.310.67322647206.360140.428.730.85718558216.5711224.147.328.51318797225.850010.232.756.99788252235.795133.629.536.83882221245.250334.820.1453655728256.689222.346.6311447875266.578218.136.844.91543183275.561358.438.62.97769564285.020324.33837.52938191295.3111253.830.315.87807347305.658027.216.456.29735086316.44413.465.131.41776686326.298212.758.129.11776491336.631144.416.838.72487053346.998352.742.24.94497730355.579123.429.646.89894329Data given in Table2 of soil sample 1 are used as input to the proposed model to get a list of suitable crops according to the given values of soil’s attributes.Table 2
Soil sample 1.
S.N.∗ pHECSCSandSiltClayTextureN∗P∗K∗16.716112.33354.61726086In Figure7, the result is showing the preference of wheat, paddy, and cotton crops compared with other crops for a selected set of properties of soil. On the other hand, corn and peanuts have less possibility to grow in such kinds of soil.Figure 7
GUI of the proposed DSSCD model for crop identifier for sample 1.Values for soil sample 1 of various soil’s attributes are given as input to the proposed model and are shown in Figure8.Figure 8
Soil parameters for sample 1.The best fitness of the proposed model of the detected crop is wheat, and the fitness value is approx. 7 as 10 is the highest for the best fit crop. Figure9 shows the crops suggested by the DSSCD model for sample 1.Figure 9
Crops suggested by the DSSCD model for sample 1.Table3 shows the values of soil sample 2. The result is showing the preference of sunflower, cotton, and sugarcane crops compared with the other crops for the selected set of properties of soil. On the other hand, wheat, paddy, and rose have less possibility to grow in such a kind of soil.Table 3
Soil sample 2.
S.N.∗ pHECSCSandSiltClayTextureN∗P∗K∗26.68612516.458.45763675Values for soil Sample 2 of various soil attributes are given as input to the model and are shown in Figure10.Figure 10
GUI of the proposed DSSCD model for crop identifier for Sample 2.The best fit detected crop is sunflower, and its fitness value is approximately 6 as 10 and is the highest for the best fit crop.Subsequent section demonstrates the proposed method in detail. The gravitational search algorithm is applied to the quantum values obtained from the crop and soil dataset.


### 4.2. Crop and Soil Dataset

For developing a model, the record of numerous crops and different soil data should be stored. The crops are categorized into two main groups, i.e., Kharif and Rabi. To prepare the dataset for crops, the physical properties of soil need to be observed.Table4 shows the essentials of soil for a particular type of crop. By giving weights to the various parameters of the soil, we will be able to discover the sequence of the crops to be selected for the field. It will further improve its production. For showing in the number system, salinity classes are defined in Table 5.Table 4
Crop soil mapping dataset [34].
Sr.CropspHECSalinity classSand %:silt %:clay %1Wheat5.5–6.54–8Slightly saline32:38:302Cotton5.5–6.52–4Very slightly saline50:20:303Paddy5.5–6.54–8Slightly saline10:20:704Corn5.5–6.52–4Very slightly saline60:30:105Barley5.5–6.58–16Moderately saline60:30:106Peanuts5.5–6.52–4Very slightly saline50:20:307Sugarcane5.5–6.52–8Very slightly saline50:20:308Beans5.5–6.50–2Nonsaline50:20:309Tomato5.5–6.52–4Very slightly saline35:50:1510Potato5.5–6.50–2Nonsaline50:20:30Table 5
Salinity class values.
Sr.SalineValue1Slightly saline12Very slightly saline23Moderately saline34Nonsaline4


#### 4.2.1. Variable Cost and Market Price of Various Crops

The market price and variable cost are the other most important parameters which need to be considered. The cost directly or indirectly depends on the type of soil. If the soil is suitable for the crop, then definitely variable cost will be low. Thus, by comparing the market value of all crops and types of soil, one can predict the suitable optimal crop by applying the proposed algorithm.Average yield (q/acre) (AY), total variable cost (TVC), gross returns (GR), and returns over variable cost (ROVC) of different crops are given in Tables6 and 7 according to the Kharif and Rabi seasons, respectively. By applying the proposed algorithm on this dataset, one can suggest an appropriate crop for a specific field to the farmer. The sequence order of the different crops can be shown as an output according to the maximum returns over the variable cost.Table 6
Comparative enterprise budget of Kharif crops [38].
CropsAYGRTVCROVCPaddy29420501673325317Basmati14295751796811607Maize20285001524913251Bt cotton10430252610316922Desi cotton9403201808922231Sugarcane planted3341037805612047660Sugarcane ratoon250786502985148799Groundnut10413001846622834Bajra1521825121389687Moong4.7235951187311722Mash3.617650115776073Arhar5.8300751278317292Soybean719400127586642Sesame2.71369095684122Table 7
Enterprise budgets of Rabi crops [36].
CropsAYGRTVCROVCWheat20365001380722693Barley1622600954113059Winter maize32466002009626504Spring maize29426251909623529Gram7257601461811142Lentil518260109177343Field pea7.521375125948781Summer moong4.5226651157111094Summer mash4.2520856123888468GobhiSarson7241501257911571Toria517000114355565Sunflower7.9300201396716053Linseed4.716345137822563Mentha50500002459325407Celery5.5264001523011170Fennel4.5247501024614504Coriander2.7515125112003925


#### 4.2.2. Fitness Function

To discover the three finest crops from the manufacturing point of view, a fitness function needs to be evaluated using the GSA (see Algorithm1). The fitness function is constructed using the following parameters:(1)fit,bestcrop1,bestcrop2,bestcrop3=Crop_selection_GSAF1,F2,F3,F4,F5,F6,where f1…f6 are parameters of the soil. These parameters can be more or less depending upon the farmer’s requirement. In the proposed method, six parameters of the soil are considered. The features of a crop for output growth are selected as the objective function, i.e.,(2)objfnccropj=∑i=110ti,where ti is the feature attribute of a crop. t1,t2,t3,…,ti are described for each crop as follows:(3)ti=1−fi−lowboundcropjlowboundcropj,iffi<lowboundcropj1−fi−highboundcropjhighboundcropj,iffi>highboundcropj1,iflowboundcropj<fi<highboundcropj1−fi−fixboundcropjfixboundcropj,otherwise,where lowerboundcropj and upperboundcropj differ from crop to crop and cropj is jth crop designated for reference. The main objective of this research is to enhance fitness. By using this, one can select those crops from their locations that have a maximum value of the objective function. The number of crops depends on the farmers and locality. In this work, 10 crops for soil-crop relation management are taken.


#### 4.2.3. Solution for Crop Planning Framework Based on Crop Dataset

In Punjab, there are more than 30 crops that can be grown. According to the categories, crops are divided into two categories which are Kharif and Rabi. Therefore, according to the season, crops are to be cultivated. According to the given algorithm, the crop selection depends on returns over variable costs. Furthermore, the variable cost depends directly or indirectly on the soil properties. To check the appropriate crop for the field, the first thing is to check the properties of the soil of the given field. This can be possible by checking the soil in the laboratory. Once a farmer will get the soil report, then all those soil parameters will be input into the algorithm. After processing the values of all those given soils’ parameters, one will get the crops in a particular sequence according to the production of the crops for the given soil. Then, that list will be input to the next step. In this step, the returns over variable costs will be calculated according to the previous years’ variable cost and the current market price of the crop. Whatever, the list of crops was in the first step that will be compared with the output of the second step. Now, in the third step, one will be able to get the list of crops which will be according to the soils’ properties and returns over the variable costs. Now, the output of the third step will be the list of crops for those soils which are suitable for good production and will give a maximum return according to the given market price and returns over the variable costs. In this way, farmers can easily determine the suitable crop for their fields of production as well as the price point of view by taking help from this GUI based model.


## 4.1. Verification and Validation

Verification is a process of checking the syntax and semantics errors in the final product. At this stage, developers have to make sure that the model is bug-free and should execute properly. It is a static process. The researcher has checked that the proposed decision support system for crop diversification (DSSCD) model is properly framed and bug-free and found very useful for end-users.Validation is a dynamic process. This process is used to check whether the proposed model is fulfilling the requirements of the customer. Validation is used to authenticate the output of a system. The proposed DSSCD model is validated and meets the final customers’ expectations. For the authentication of the proposed DSSCD model, various samples of the soil have been taken from different regions of Indian Punjab as shown in Table1. Values of the different attributes of soil are entered as input to the proposed model, and the output from this model shows that it meets the final customers’ expectations and requirements. Therefore, the output of this system is tested in various ways to get the optimal results. For various inputs as shown in Table 1, it is validated that this system gives a list of suitable crops for a given particular type of soil according to crop-soil dataset. Note that in Table 1, S.N.∗ stands for Sample Number, N∗ stands for Nitrogen, P∗ refers to Phosphorus, and K∗ stands for Potassium. Moreover, the unit of nitrogen, phosphorus, and potassium is kilogram/hectare.Table 1
Soil samples of Indian Punjab.
S.N.∗pHECSCSandSiltClayTextureN∗P∗K∗16.716112.33354.6172608626.68612516.458.4776367536.3811015.36.278.4741322445.7511363.910.325.7555722755.076212.33354.6959583965.038029.828.241.8480446776.415045.54410.4482669685.411034.31451.5498688296.171027622.71.244079100106.9910140.614.744.52653458115.065136.25.658.12389077125.580144.930.324.76705048136.195243.933.222.76392629145.612034.231.434.24896220156.998037.125.437.33667989165.428132.626.640.63578736176.15435.71777.19862179185.631123.31858.69945959195.35107712.310.67322647206.360140.428.730.85718558216.5711224.147.328.51318797225.850010.232.756.99788252235.795133.629.536.83882221245.250334.820.1453655728256.689222.346.6311447875266.578218.136.844.91543183275.561358.438.62.97769564285.020324.33837.52938191295.3111253.830.315.87807347305.658027.216.456.29735086316.44413.465.131.41776686326.298212.758.129.11776491336.631144.416.838.72487053346.998352.742.24.94497730355.579123.429.646.89894329Data given in Table2 of soil sample 1 are used as input to the proposed model to get a list of suitable crops according to the given values of soil’s attributes.Table 2
Soil sample 1.
S.N.∗ pHECSCSandSiltClayTextureN∗P∗K∗16.716112.33354.61726086In Figure7, the result is showing the preference of wheat, paddy, and cotton crops compared with other crops for a selected set of properties of soil. On the other hand, corn and peanuts have less possibility to grow in such kinds of soil.Figure 7
GUI of the proposed DSSCD model for crop identifier for sample 1.Values for soil sample 1 of various soil’s attributes are given as input to the proposed model and are shown in Figure8.Figure 8
Soil parameters for sample 1.The best fitness of the proposed model of the detected crop is wheat, and the fitness value is approx. 7 as 10 is the highest for the best fit crop. Figure9 shows the crops suggested by the DSSCD model for sample 1.Figure 9
Crops suggested by the DSSCD model for sample 1.Table3 shows the values of soil sample 2. The result is showing the preference of sunflower, cotton, and sugarcane crops compared with the other crops for the selected set of properties of soil. On the other hand, wheat, paddy, and rose have less possibility to grow in such a kind of soil.Table 3
Soil sample 2.
S.N.∗ pHECSCSandSiltClayTextureN∗P∗K∗26.68612516.458.45763675Values for soil Sample 2 of various soil attributes are given as input to the model and are shown in Figure10.Figure 10
GUI of the proposed DSSCD model for crop identifier for Sample 2.The best fit detected crop is sunflower, and its fitness value is approximately 6 as 10 and is the highest for the best fit crop.Subsequent section demonstrates the proposed method in detail. The gravitational search algorithm is applied to the quantum values obtained from the crop and soil dataset.


## 4.2. Crop and Soil Dataset

For developing a model, the record of numerous crops and different soil data should be stored. The crops are categorized into two main groups, i.e., Kharif and Rabi. To prepare the dataset for crops, the physical properties of soil need to be observed.Table4 shows the essentials of soil for a particular type of crop. By giving weights to the various parameters of the soil, we will be able to discover the sequence of the crops to be selected for the field. It will further improve its production. For showing in the number system, salinity classes are defined in Table 5.Table 4
Crop soil mapping dataset [34].
Sr.CropspHECSalinity classSand %:silt %:clay %1Wheat5.5–6.54–8Slightly saline32:38:302Cotton5.5–6.52–4Very slightly saline50:20:303Paddy5.5–6.54–8Slightly saline10:20:704Corn5.5–6.52–4Very slightly saline60:30:105Barley5.5–6.58–16Moderately saline60:30:106Peanuts5.5–6.52–4Very slightly saline50:20:307Sugarcane5.5–6.52–8Very slightly saline50:20:308Beans5.5–6.50–2Nonsaline50:20:309Tomato5.5–6.52–4Very slightly saline35:50:1510Potato5.5–6.50–2Nonsaline50:20:30Table 5
Salinity class values.
Sr.SalineValue1Slightly saline12Very slightly saline23Moderately saline34Nonsaline4


### 4.2.1. Variable Cost and Market Price of Various Crops

The market price and variable cost are the other most important parameters which need to be considered. The cost directly or indirectly depends on the type of soil. If the soil is suitable for the crop, then definitely variable cost will be low. Thus, by comparing the market value of all crops and types of soil, one can predict the suitable optimal crop by applying the proposed algorithm.Average yield (q/acre) (AY), total variable cost (TVC), gross returns (GR), and returns over variable cost (ROVC) of different crops are given in Tables6 and 7 according to the Kharif and Rabi seasons, respectively. By applying the proposed algorithm on this dataset, one can suggest an appropriate crop for a specific field to the farmer. The sequence order of the different crops can be shown as an output according to the maximum returns over the variable cost.Table 6
Comparative enterprise budget of Kharif crops [38].
CropsAYGRTVCROVCPaddy29420501673325317Basmati14295751796811607Maize20285001524913251Bt cotton10430252610316922Desi cotton9403201808922231Sugarcane planted3341037805612047660Sugarcane ratoon250786502985148799Groundnut10413001846622834Bajra1521825121389687Moong4.7235951187311722Mash3.617650115776073Arhar5.8300751278317292Soybean719400127586642Sesame2.71369095684122Table 7
Enterprise budgets of Rabi crops [36].
CropsAYGRTVCROVCWheat20365001380722693Barley1622600954113059Winter maize32466002009626504Spring maize29426251909623529Gram7257601461811142Lentil518260109177343Field pea7.521375125948781Summer moong4.5226651157111094Summer mash4.2520856123888468GobhiSarson7241501257911571Toria517000114355565Sunflower7.9300201396716053Linseed4.716345137822563Mentha50500002459325407Celery5.5264001523011170Fennel4.5247501024614504Coriander2.7515125112003925


### 4.2.2. Fitness Function

To discover the three finest crops from the manufacturing point of view, a fitness function needs to be evaluated using the GSA (see Algorithm1). The fitness function is constructed using the following parameters:(1)fit,bestcrop1,bestcrop2,bestcrop3=Crop_selection_GSAF1,F2,F3,F4,F5,F6,where f1…f6 are parameters of the soil. These parameters can be more or less depending upon the farmer’s requirement. In the proposed method, six parameters of the soil are considered. The features of a crop for output growth are selected as the objective function, i.e.,(2)objfnccropj=∑i=110ti,where ti is the feature attribute of a crop. t1,t2,t3,…,ti are described for each crop as follows:(3)ti=1−fi−lowboundcropjlowboundcropj,iffi<lowboundcropj1−fi−highboundcropjhighboundcropj,iffi>highboundcropj1,iflowboundcropj<fi<highboundcropj1−fi−fixboundcropjfixboundcropj,otherwise,where lowerboundcropj and upperboundcropj differ from crop to crop and cropj is jth crop designated for reference. The main objective of this research is to enhance fitness. By using this, one can select those crops from their locations that have a maximum value of the objective function. The number of crops depends on the farmers and locality. In this work, 10 crops for soil-crop relation management are taken.


### 4.2.3. Solution for Crop Planning Framework Based on Crop Dataset

In Punjab, there are more than 30 crops that can be grown. According to the categories, crops are divided into two categories which are Kharif and Rabi. Therefore, according to the season, crops are to be cultivated. According to the given algorithm, the crop selection depends on returns over variable costs. Furthermore, the variable cost depends directly or indirectly on the soil properties. To check the appropriate crop for the field, the first thing is to check the properties of the soil of the given field. This can be possible by checking the soil in the laboratory. Once a farmer will get the soil report, then all those soil parameters will be input into the algorithm. After processing the values of all those given soils’ parameters, one will get the crops in a particular sequence according to the production of the crops for the given soil. Then, that list will be input to the next step. In this step, the returns over variable costs will be calculated according to the previous years’ variable cost and the current market price of the crop. Whatever, the list of crops was in the first step that will be compared with the output of the second step. Now, in the third step, one will be able to get the list of crops which will be according to the soils’ properties and returns over the variable costs. Now, the output of the third step will be the list of crops for those soils which are suitable for good production and will give a maximum return according to the given market price and returns over the variable costs. In this way, farmers can easily determine the suitable crop for their fields of production as well as the price point of view by taking help from this GUI based model.


## 4.2.1. Variable Cost and Market Price of Various Crops

The market price and variable cost are the other most important parameters which need to be considered. The cost directly or indirectly depends on the type of soil. If the soil is suitable for the crop, then definitely variable cost will be low. Thus, by comparing the market value of all crops and types of soil, one can predict the suitable optimal crop by applying the proposed algorithm.Average yield (q/acre) (AY), total variable cost (TVC), gross returns (GR), and returns over variable cost (ROVC) of different crops are given in Tables6 and 7 according to the Kharif and Rabi seasons, respectively. By applying the proposed algorithm on this dataset, one can suggest an appropriate crop for a specific field to the farmer. The sequence order of the different crops can be shown as an output according to the maximum returns over the variable cost.Table 6
Comparative enterprise budget of Kharif crops [38].
CropsAYGRTVCROVCPaddy29420501673325317Basmati14295751796811607Maize20285001524913251Bt cotton10430252610316922Desi cotton9403201808922231Sugarcane planted3341037805612047660Sugarcane ratoon250786502985148799Groundnut10413001846622834Bajra1521825121389687Moong4.7235951187311722Mash3.617650115776073Arhar5.8300751278317292Soybean719400127586642Sesame2.71369095684122Table 7
Enterprise budgets of Rabi crops [36].
CropsAYGRTVCROVCWheat20365001380722693Barley1622600954113059Winter maize32466002009626504Spring maize29426251909623529Gram7257601461811142Lentil518260109177343Field pea7.521375125948781Summer moong4.5226651157111094Summer mash4.2520856123888468GobhiSarson7241501257911571Toria517000114355565Sunflower7.9300201396716053Linseed4.716345137822563Mentha50500002459325407Celery5.5264001523011170Fennel4.5247501024614504Coriander2.7515125112003925


## 4.2.2. Fitness Function

To discover the three finest crops from the manufacturing point of view, a fitness function needs to be evaluated using the GSA (see Algorithm1). The fitness function is constructed using the following parameters:(1)fit,bestcrop1,bestcrop2,bestcrop3=Crop_selection_GSAF1,F2,F3,F4,F5,F6,where f1…f6 are parameters of the soil. These parameters can be more or less depending upon the farmer’s requirement. In the proposed method, six parameters of the soil are considered. The features of a crop for output growth are selected as the objective function, i.e.,(2)objfnccropj=∑i=110ti,where ti is the feature attribute of a crop. t1,t2,t3,…,ti are described for each crop as follows:(3)ti=1−fi−lowboundcropjlowboundcropj,iffi<lowboundcropj1−fi−highboundcropjhighboundcropj,iffi>highboundcropj1,iflowboundcropj<fi<highboundcropj1−fi−fixboundcropjfixboundcropj,otherwise,where lowerboundcropj and upperboundcropj differ from crop to crop and cropj is jth crop designated for reference. The main objective of this research is to enhance fitness. By using this, one can select those crops from their locations that have a maximum value of the objective function. The number of crops depends on the farmers and locality. In this work, 10 crops for soil-crop relation management are taken.


## 4.2.3. Solution for Crop Planning Framework Based on Crop Dataset

In Punjab, there are more than 30 crops that can be grown. According to the categories, crops are divided into two categories which are Kharif and Rabi. Therefore, according to the season, crops are to be cultivated. According to the given algorithm, the crop selection depends on returns over variable costs. Furthermore, the variable cost depends directly or indirectly on the soil properties. To check the appropriate crop for the field, the first thing is to check the properties of the soil of the given field. This can be possible by checking the soil in the laboratory. Once a farmer will get the soil report, then all those soil parameters will be input into the algorithm. After processing the values of all those given soils’ parameters, one will get the crops in a particular sequence according to the production of the crops for the given soil. Then, that list will be input to the next step. In this step, the returns over variable costs will be calculated according to the previous years’ variable cost and the current market price of the crop. Whatever, the list of crops was in the first step that will be compared with the output of the second step. Now, in the third step, one will be able to get the list of crops which will be according to the soils’ properties and returns over the variable costs. Now, the output of the third step will be the list of crops for those soils which are suitable for good production and will give a maximum return according to the given market price and returns over the variable costs. In this way, farmers can easily determine the suitable crop for their fields of production as well as the price point of view by taking help from this GUI based model.


## 5. Performance Analysis

The soil parameter values are used to determine a suitable crop. Find the values of all required soil parameters by testing the soil in the laboratory. After getting the values of the soil’s parameters, one will give input to the proposed method for comparison. Based on the values, a list of crops in descending order according to the production will be displayed as shown in the graph (see Figure11). A farmer will select any crop from the first three crops from the list. In this way, a farmer can go for the crop with the best suitability of soil and which will take less water. If a farmer belongs to an area where groundwater, as well as canal water, is less, then he can choose the crop according to that. Crop diversification can be achieved by using this method, which is the need of an hour.Figure 11
Crop soil relationship.In Figure11, the relationship between crop and soil parameters is represented. The parameters help in finding out the best suitable soil for that particular crop. If the soil is suited for the crop, then definitely, we will have to pay less. Whereas the soil is not suited for the cultivation of crop, then definitely lots of effort and work is to be done for getting the best results. Therefore, in this case, much cost will be needed. Our proposed work helps in presenting the model which will help in detecting the soil which will be best suited for the cultivation of the particular crop.


### 5.1. Scope

Crop diversification is one of the widely used phenomena. Crop diversification helps in potential risk management with uncertainty, income and employment generation opportunities, ability to reduce diseases, weed and insect build-up, the possibility to increase soil fertility, and among others. In this case, when a farmer is having a choice for selecting the appropriate crop for a specific soil, then the farmer can get the benefits of using such a model. In this way, Punjab’s farmers can save groundwater by growing other alternative crops instead of paddy, and other options he can get by using the above mentioned method. Using optimization techniques, one can implement and can provide a good GUI to the final user.


## 5.1. Scope

Crop diversification is one of the widely used phenomena. Crop diversification helps in potential risk management with uncertainty, income and employment generation opportunities, ability to reduce diseases, weed and insect build-up, the possibility to increase soil fertility, and among others. In this case, when a farmer is having a choice for selecting the appropriate crop for a specific soil, then the farmer can get the benefits of using such a model. In this way, Punjab’s farmers can save groundwater by growing other alternative crops instead of paddy, and other options he can get by using the above mentioned method. Using optimization techniques, one can implement and can provide a good GUI to the final user.


## 6. Conclusion

Crop diversification helps farmers for optimal crop selection for a specific soil. It helps farmers to save groundwater by growing alternative crops instead of paddy. The selection of optimal crops can be achieved using various machine learning models. However, the existing crop selection techniques suffer from overfitting and hyperparameter tuning issues. Therefore, in this paper, a novel gravitational search algorithm-based optimal crop selection model has been developed. Extensive experiments have been performed to evaluate the effectiveness of the proposed technique. A comparative analysis reveals that the proposed technique is able to achieve remarkable results. Therefore, the proposed technique can be used for real-time optimal crop selection systems.



---

*Source: 5549992-2021-04-20.xml*