




Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Community
Ask the community for help and clear up your study doubts
Discover the best universities in your country according to Docsity users
Free resources
Download our free guides on studying techniques, anxiety management strategies, and thesis advice from Docsity tutors
Abstract— The complexity of energy plans can pose a challenging dilemma for a significant number of consumers, given the various service hours and accompanying terms, including potential charges for cancellation. This project focuses on optimizing energy plan selection using a genetic algorithm approach. The objective is to identify the most cost-effective energy plan from a set of ten predefined options based on hourly energy usage data spanning from 2002 to 2022. The algorithm seeks to minimize cost, maximize renewable energy utilization, and consider cancellation fees as significant factors in the decision- making process. The genetic algorithm operates by evaluating plan parameters, including cost and cancellation fee, and adjusting them iteratively to ascertain the most optimal energy plan. The fitness function normalizes these parameters based on hypothetical minimum and maximum values, assigning weighted importance to each criterion.
Typology: Study Guides, Projects, Research
1 / 8
This page cannot be seen from the preview
Don't miss anything!
Abstract — The complexity of energy plans can pose a challenging dilemma for a significant number of consumers, given the various service hours and accompanying terms, including potential charges for cancellation. This project focuses on optimizing energy plan selection using a genetic algorithm approach. The objective is to identify the most cost-effective energy plan from a set of ten predefined options based on hourly energy usage data spanning from 2002 to 2022. The algorithm seeks to minimize cost, maximize renewable energy utilization, and consider cancellation fees as significant factors in the decision- making process. The genetic algorithm operates by evaluating plan parameters, including cost and cancellation fee, and adjusting them iteratively to ascertain the most optimal energy plan. The fitness function normalizes these parameters based on hypothetical minimum and maximum values, assigning weighted importance to each criterion. Through this iterative process, the algorithm identifies the plan that best satisfies the weighted combination of cost, cancellation fee, and renewable energy objectives. This approach provides a robust methodology for optimizing energy plan selection based on historical energy usage data and predefined plan parameters. The abstracted results and evaluations demonstrate the effectiveness of the genetic algorithm in determining the most suitable energy plan from the provided options. This method considers both the temporal consumption trends and financial limitations within the energy market in Texas. Index Terms — Genetic Algorithms, Energy Plan Optimization, Cost-Effective Plan Selection, Renewable Energy Utilization, Cancellation Fees, Decision-Making Factors, Data-Backed Approach. I. INTRODUCTION enetic Algorithms (GAs) are used in optimization to address complex problems like those in modern power systems. This technique provides global optimization for various functions by using a search procedure through a parameter space incorporating stochasticity to guide the search. GAs mimic natural selection and Darwin’s theory of evolution in that they produce the best points in each generation toward the best solution. The algorithm functions by generating an initial population, creating other generations, plotting their This paragraph of the first footnote will contain the date on which you submitted your paper for review, which is populated by IEEE. It is IEEE style to display support information, including sponsor and financial support acknowledgment, here and not in an acknowledgment section at the end of the article. For example, “This work was supported in part by the U.S. Department of Commerce under Grant 123456.” The name of the corresponding author appears after the financial information, e.g. (Corresponding author: Second B. Author). Here you may also indicate if authors contributed equally or if there are co-first authors. Al-Mustasin Hossain is currently a PhD student in the Mechanical Engineering Department at the University of Texas at Dallas, Dallas, TX 75235 USA. He completed his master’s in mechanical engineering at Washington progress, and determining stopping conditions. The next population relies on computations involving random number generators which encourages a more exploratory search. This technique is the best choice for the optimization of power systems as they have a frequent change and GAs are stable in application although they are slow. Typically, the design challenges pertaining to power distribution systems are addressed by the application of classical optimization techniques. In this context, the fundamental problem at hand often revolves around the minimization of an objective function. The objective function often represents the overall expenses associated with the expansion of the global power system, including addressing sizing and location issues within the distribution system. Genetic Algorithms are commonly recognized as efficient optimizers and have successfully addressed industrial optimization challenges in recent times, yielding favorable outcomes. Genetic Algorithms (GAs) have been utilized in the design of street lighting networks through the utilization of binary codification. However, this approach has encountered difficulties in incorporating some elements of mathematical models. The utilization of binary codification has been employed in the context of a genetic algorithm in order to identify optimal solutions for the construction of distribution networks [1]. In modern power systems, the main goal of distribution companies is to minimize operation and maintenance costs. These companies also aim to manage the uncertainties from Distributed Generation resources. GAs offers a solution to the fluctuating energy output from DG resources that poses challenges for balancing production and consumption, leading to outages [2]. One approach to solving this issue is placing DG resources alongside sensitive loads to reduce the risk of inadequate supply. Leveraging load response programs and consumer participation through network intelligence can decrease peak loads avoiding the pollution from energy production. This approach aligns with the goals of distribution companies to optimize system efficiency and reliability in the evolving competitive electricity market [3]. State University Vancouver and undergraduate studies at Mechanical Engineering at Bangladesh University of Engineering and Technology (BUET), and joined the PhD program. Email: Al-Mustasin.Hossain@UTDallas.edu. Shanae Edwards is a PhD student in the Mechanical Engineering Department at the University of Texas at Dallas, Dallas, TX 75235 USA. She earned her bachelor's degree from [XX], XX, and has been pursuing her doctoral studies since []. Email: shanae.edwards@utdallas.edu. Musa Ibne Mannan is a PhD student in the Mechanical Engineering Department at the University of Texas at Dallas, Dallas, TX 75235 USA. Musa completed his master’s in mechanical and manufacturing at Texas State University, San Marcos, Texas 78666, and began his PhD journey in 2023. Email: musa 314 @utdallas.edu.
Genetic algorithms (GA) are frequently employed as a means to address intricate optimization issues that are challenging to resolve through conventional methodologies. Within the realm of energy management, Genetic Algorithms (GAs) provide the capability to effectively optimize the dimensions and functioning of hybrid renewable energy systems (HRESs). Hybrid renewable energy systems (HRESs) encompass the integration of several renewable energy sources, including solar and wind power, alongside energy storage technologies. This integration aims to establish a dependable and environmentally sustainable electricity supply. The utilization of Genetic Algorithms (GAs) in optimizing Hybrid Renewable Energy Systems (HRES) has the potential to enhance the system's overall efficiency and cost-effectiveness [4]. Arabali et al described a GA-based optimization approach for HRESs that uses historical hourly wind speed, solar irradiance, and load data to stochastically model the uncertainty of wind and PV generation and load. This approach is based on the concept of probabilistic constraints, which allow the GA to consider the probability of violating constraints when making optimization decisions. The authors also propose a two-point estimation (2PE) method to estimate the expected value and standard deviation of the output variables. This study has the assumption that the output variables can be approximated by a linear function of the input variables. A substantial population size is chosen to enhance the likelihood of converging towards the global minimum, but at the expense of a notable increase in computing workload. To preserve favorable outcomes, a pair of exceptional offspring are selected and preserved in each successive generation. The implementation of the Genetic Algorithm (GA) utilizes a double vector form instead of a binary representation in order to ensure coherence in the process of mutation. The optimal balance between crossover and mutation offspring is maintained by fine-tuning the crossover rate to approximately 78%. To guarantee the fulfillment of constraints, a solution that violates a constraint is allocated a substantial penalty factor. The authors evaluate their approach using a case study of a HRES in Nevada. They find that their approach can significantly improve the performance of the HRES compared to a traditional optimization approach that does not consider the uncertainty of the input variables [4]. In their publication titled "Cost-effective allocation of watershed management practices using a genetic algorithm," Arabi et al. introduce an innovative optimization approach to develop comprehensive sediment and nutrient control strategies at the watershed level. This methodology effectively integrates several objectives, which frequently exhibit contradictory characteristics. The approach integrates the utilization of a watershed model known as SWAT, the incorporation of best management practices (BMPs), an economic element, and a spatial search strategy based on a genetic algorithm [3]. The optimization model utilized in this research comprises the SWAT model, which is employed for modeling pollution loads, a tool for representing Best Management Practices (BMPs), an economic component, and a geographic optimization technique based on Genetic Algorithms (GAs). A MATLAB computer program was created to establish the connection between different components of the model. The study involved the evaluation of the model's effectiveness in optimizing the placement of field boundaries, parallel terraces, grassed rivers, and grade stabilization structures within the Dreisbach and Smith Fry watersheds. The results of the study indicate that the optimization methodology is capable of identifying cost- effective BMP placement strategies that achieve multiple objectives. For example, in the Dreisbach watershed, the optimization model identified a plan that reduced sediment loads by 50% and phosphorus loads by 40%, while reducing costs by 20% compared to a non-optimized plan. The GA was able to efficiently search a large number of potential solutions and identify near-optimal solutions. [3] Multiobjective Genetic Algorithms (MOGAs) represent a modified version of the classical Genetic Algorithm (GA), primarily distinguished by their approach to fitness function assignment. While the procedural steps remain similar to GAs, MOGAs aim to generate an optimal Pareto Front in the objective space, ensuring that further enhancement in any fitness function does not occur without considering the impact on other fitness functions [5]. The central goals of MOGAs encompass convergence, diversity, and coverage. Pareto-based MOGAs originated with the introduction of the concept of Pareto dominance by Fonseca and Fleming[6], marking the genesis of the first MOGA. Early approaches, such as the niched Pareto genetic algorithm (NPGA) by Horn et al. [7] and the non-dominated sorting genetic algorithm (NSGA) by Srinivas and Deb [8] addressed multimodal problems. NSGA suffered from issues like lack of elitism and high computation complexity, prompting the development of NSGA-II by Deb et al. [9]. However, challenges persisted, leading to adaptations like the introduction of dynamic crowding distance by Luo et al.[10]. Coello and Pulido [11] proposed a multiobjective micro GA, using an archive to store non-dominated solutions, though its performance was observed to decline in many-objective problems [12]. Decomposition-based MOGAs take a different approach by decomposing a problem into multiple subproblems, solving them simultaneously, and exchanging solutions among neighboring subproblems [12]. Ishibuchi and Murata [13] introduced a multiobjective genetic local search (MOGLS) employing random weights for parent selection and local search for offspring. Jaszkiewicz [14] modified MOGLS with different selection mechanisms for parents. Murata and Gen [15] extended MOGA with a cellular structure, termed C- MOGA, where the selection operator operated on the neighboring cells. Alves and Almeida [16] developed a multi- objective Tchebycheffs-based genetic algorithm (MOTGA) ensuring convergence and diversity. Patel et al. [17] introduced decomposition-based MOGA (D-MOGA) with opposition- based learning for weight vector generation, successfully balancing solution diversity and search space exploration. Based on the previous literatures, multi-objective optimization algorithm was chosen to solve our provided problem. It aims to optimize the selection of energy plans by considering multiple objectives simultaneously, including minimizing cost, maximizing renewable energy utilization, and accounting for cancellation fees. Our work aligns with the category of Multiobjective Genetic Algorithms (MOGAs), specifically
consumption for each time interval were computed. These statistics provide insights into the variability and central tendencies of energy consumption across the given time. Mean consumption denotes the arithmetic mean of energy consumption values within the dataset. It offers a comprehensive overview of the average levels of consumption. The mean consumption numbers in this scenario vary between about 31,000 and 37,000, with each value amplified by a factor of 10,000. The median consumption, representing the central value in the dataset when organized in either ascending or descending order, provides valuable information about the consumption level at the midpoint. The median consumption estimates, which have been scaled by a factor of 10,000, range from around 29,000 to 35,000 and are lower than the mean consumption. The standard deviation (SD) quantifies the level of variability or dispersion within a dataset. A higher standard deviation (SD) indicates a larger range of values in energy use, indicating greater variability. The standard deviation (SD) values range from around 7,000 to 8,000 (scaled by a factor of 10,000), reflecting the extent to which data points deviate from the mean. Variance, which is the result of squaring the standard deviation, serves as an additional metric for quantifying the extent of dispersion. It quantifies the average amount by which each value in a set deviate from the mean, squared. The maximum and minimum consumption data in the dataset correspond to the highest and lowest levels of consumption, respectively. They provide an indication of the extent to which the majority of the observations are distributed. The minimum consumption varies between 210,000 and 270,000 (multiplied by a factor of 10,000), while the maximum consumption ranges from around 500,000 to 570,000 (scaled by a factor of 10,000). Correlation analysis was also conducted to assess the relationships between energy consumption at various time periods. The correlation matrix in this instance exhibits an extremely strong positive correlation between the different time intervals. Every individual cell within the matrix denotes the correlation coefficient between two distinct intervals, with values spanning from - 1 to 1. A correlation value of 1 represents a complete positive linear relationship, whereas - 1 signifies a complete negative linear association. Values approaching 0 indicate the absence of a linear correlation. It is evident in this matrix that the majority of values are in close proximity to 1, especially along the diagonal spanning from the upper left corner to the lower right corner. The diagonal line in the graph depicts the correlation between each period and itself, which is consistently 1, showing a perfect connection. The significant correlation coefficients observed in the matrix indicate a robust linear association between the time periods, indicating that variations in one interval tend to consistently correspond with variations in another interval, either positively or negatively. The correlation heatmap of energy consumption was presented in Fig 1.
3. 1 .2 Visualization of the Data Heatmap The illustration displays a correlation heatmap that showcases the connections between different time intervals associated with energy use. The heatmap displays the correlation coefficient between two distinct intervals in each cell, with values ranging from - 1 to 1. A value approaching 1 suggests a robust positive linear correlation, whereas a value approaching - 1 indicates a strong negative linear correlation. The diagonal line represents a perfect correlation (1.0) between each period and itself. Fig 3 Correlation Heatmap of Energy Consumption Intervals The heatmap displays mostly high correlation coefficients throughout the matrix, indicating a substantial degree of linear relationship between various time intervals. The symmetrical form of the heatmap suggests that the correlation between two intervals, A and B, is equivalent to the correlation between B and A. Boxplots Fig 4 Boxplot of Energy Consumption The boxplot displays the distribution of energy use over several time intervals throughout a day. Each box in the plot depicts the interquartile range (IQR) of energy consumption, which indicates the range of values that includes the center 50% of the data. The line within the box represents the median consumption, while the whiskers extend to illustrate the range
of readings, omitting any possible outliers. This representation facilitates the comparison of energy usage trends at different time intervals, enables the identification of central tendencies, and aids in the detection of potential deviations or outliers in consumption patterns. Histogram Fig 5 Histograms of Energy Consumption Histograms depicting the probability distribution of energy usage at specific time intervals are presented. Each histogram depicts the frequency of energy consumption values within distinct intervals, providing a comprehensive analysis of consumption trends during various periods of the day. By visually representing the form and distribution of each histogram, it becomes simpler to comprehend the fluctuations, average values, and possible anomalies in energy consumption over the course of the day. Examining these histograms facilitates the identification of periods with the highest levels of consumption, the evaluation of fluctuations in usage intensity, and the comprehension of the general distribution of energy consumption across different time intervals.
clc clear all time = { (see more in the code file) }; data = [ (see more in the code file) ] % Transposing the data for table compatibility data = data.'; usageData = array2table(data, 'VariableNames', time); planNames = {'Plan A', 'Plan B', 'Plan C', 'Plan D', 'Plan E', 'Plan F', 'Plan G', 'Plan H', 'Plan I', 'Plan J'}; % Defining the plan data planData = [ 13.4, 1427.00, 150.00, 26, 2008, 115000, 2.2; % Plan A 13.4, 1430.00, 150.00, 100, 2019, 0, 0; % Plan B 13.5, 1438.00, 150.00, 100, 2001, 223000, 1.3; % Plan C 13.6, 1452.00, 150.00, 6, 2019, 3000, 0; % Plan D 13.6, 1454.00, 300.00, 15, 2021, 0, 5.9; % Plan E 13.7, 1461.00, 240.00, 29, 2022, 0, 2.2; % Plan F 13.8, 1477.00, 150.00, 25, 2020, 0, 0; % Plan G 13.9, 1482.00, 240.00, 100, 2022, 0, 2.2; % Plan H 13.9, 1484.00, 99.00, 26, 2005, 34000, 2; % Plan I 13.9, 1484.00, 199.00, 26, 2005, 34000, 2 % Plan J ]; options = gaoptimset('PopulationSize', 200, 'Generations', 300, 'StallGenLimit', 100, 'CrossoverFraction', 0.8, 'MutationFcn', {@mutationuniform, 0.05}); fun = @(x) objectiveFunction(x, data); [x, fval, exitFlag, output] = ga(fun, size(planData, 1), [], [], [], [], [], [], [], options); if isfield(output, 'fval') disp('Field name "fval" found in the output structure.'); fitnessValues = output.fval; for gen = 1:length(fitnessValues) fprintf('Generation %d - Best Fitness: %f\n', gen, fitnessValues(gen)); end else disp('Field name "fval" not found in the output structure.'); end % Statistical measures for each time interval (column-wise) mean_consumption = mean(data); % Mean consumption median_consumption = median(data); % Median consumption std_consumption = std(data); % Standard deviation of consumption max_consumption = max(data); % Maximum consumption min_consumption = min(data); % Minimum consumption % Displaying the calculated statistical measures disp('Statistical Measures of Energy Consumption:'); disp(['Mean Consumption: ', num2str(mean_consumption)]); disp(['Median Consumption: ', num2str(median_consumption)]); disp(['Standard Deviation of Consumption: ', num2str(std_consumption)]); disp(['Maximum Consumption: ', num2str(max_consumption)]); disp(['Minimum Consumption: ', num2str(min_consumption)]); % Performing correlation analysis correlation_matrix = corrcoef(data); % Compute correlation coefficients % Displaying the correlation matrix disp('Correlation Matrix:'); disp(correlation_matrix); % Visualizing the correlation matrix as a heatmap figure; imagesc(correlation_matrix); colorbar; % Show colorbar indicating the scale title('Correlation Heatmap of Energy Consumption'); xlabel('Time Intervals'); ylabel('Time Intervals'); % Boxplot for Energy Consumption figure; boxplot(data, 'Labels', time); title('Boxplot of Energy Consumption'); xlabel('Time Intervals'); ylabel('Energy Consumption'); % Histograms for Energy Consumption figure; for i = 1:size(data, 2) subplot(5, 5, i); % Adjust subplot layout as needed histogram(data(:, i), 'Normalization', 'probability'); title(['Histogram - ' time{i}]); xlabel('Energy Consumption');
ylabel('Probability'); end [bestFitness, bestPlanIndex] = min(fval); bestPlanName = planNames{bestPlanIndex}; disp('Best Plan Parameters:'); disp(x(bestPlanIndex, :)); % Display the parameters of the best plan disp(['Best Plan Name: ' bestPlanName]); disp(['Fitness (Lower is better): ' num2str(bestFitness)]); disp(output); fieldNames = fieldnames(output); disp('Field names in the output structure:'); disp(fieldNames); fitnessField = ''; for i = 1:numel(fieldNames) if isnumeric(output.(fieldNames{i})) fitnessField = fieldNames{i}; break; end end if ~isempty(fitnessField) fitnessValues = output.(fitnessField); figure; plot(fitnessValues, 'LineWidth', 1.5); hold on; if exitFlag == 1 plot(length(fitnessValues), bestFitness, 'ro', 'MarkerSize', 10); else plot(length(fitnessValues), bestFitness, 'bx', 'MarkerSize', 10); end title('Convergence Plot'); xlabel('Generation'); ylabel('Fitness Value'); grid on; hold off; else disp('No fitness-related numeric field found in the output structure.'); end function fitness = objectiveFunction(planParams, data) cost = planParams(:, 3); cancelFee = planParams(:, 4); % Normalizing cost maxCost = max(cost); minCost = min(cost); if maxCost ~= minCost normalizedCost = (maxCost - cost) / (maxCost - minCost); else normalizedCost = zeros(size(cost)); % Handle division by zero end % Normalizing cancellation fee maxCancelFee = max(cancelFee); minCancelFee = min(cancelFee); if maxCancelFee ~= minCancelFee normalizedCancelFee = (maxCancelFee - cancelFee) / (maxCancelFee - minCancelFee); else normalizedCancelFee = zeros(size(cancelFee)); % Handle division by zero end % Calculating total renewable energy used for each plan totalRenewable = sum(planParams(:, 7:end), 2); maxRenewable = max(totalRenewable); minRenewable = min(totalRenewable); if maxRenewable ~= minRenewable normalizedRenewable = (totalRenewable - minRenewable) / (maxRenewable - minRenewable); else normalizedRenewable = zeros(size(totalRenewable)); % Handle division by zero end % Adjusting the weights for objectives weightCost = 0.3; weightRenewable = 0.4; weightCancelFee = 0.3; % Introducing constraints for cancellation fee and cost % (neeeds adjustment) penalty = 10000; % Penalty for not meeting the constraints % Applying constraints % Ensuring the cancellation fee is within an acceptable range cancelFeeConstraint = cancelFee <= maxCancelFee & cancelFee >= minCancelFee; % Ensuring the cost is within an acceptable range costConstraint = cost <= maxCost & cost >= minCost; % Applying penalty if constraints are violated cancelFeePenalty = penalty * ~cancelFeeConstraint; costPenalty = penalty * ~costConstraint; % Combining penalties for violated constraints totalPenalty = cancelFeePenalty + costPenalty; fitness = weightCost * normalizedCost + weightRenewable * normalizedRenewable + weightCancelFee * normalizedCancelFee + totalPenalty; end