How To Solve An Optimization Problem Using Genetic Algorithm (GA) Solver In Matlab

Поделиться
HTML-код
  • Опубликовано: 27 янв 2025

Комментарии • 126

  • @chandrasekhar681
    @chandrasekhar681 3 года назад +1

    Thank you very much sir for ur video and also can u make a video on Fuzzy logic controller optimization. I’m trying since many days but not getting perfect video related to Fuzzy optimization.

  • @nathanngumi8467
    @nathanngumi8467 3 года назад

    Very informative, thanks!

  • @samsondavid8880
    @samsondavid8880 3 года назад +1

    Thanks sir, it is a good one, but you need to be talking as you are taking step so that it can help us sir as some of us do not laptop to be seing it clearly sir.

  • @adminos15
    @adminos15 4 года назад

    Thanks bro!
    lifesaver!

  • @NasirUddin-im2zb
    @NasirUddin-im2zb 4 года назад

    Great work sir ..need more your support

  • @danielgonzalorodriguez4090
    @danielgonzalorodriguez4090 2 года назад

    Great video,
    Anyone knows if the code’d run in the latest versions of Matlab where optimtool has been removed?
    Thanks

  • @jacobvk237
    @jacobvk237 2 года назад

    Hai sir well explained Thankyou so much. will you please make a video based on antenna array optimization via thinning by genetic algorithm

  • @hendazorganiagrebi8176
    @hendazorganiagrebi8176 4 года назад

    thank you for the explication, my questions are:
    1/what are the criteria we are based on to be able to change parameters appearing in the optimization tool window
    2/how can we verify the correct result that give the simulation, especially we have different results by changing parameters

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад +1

      1. For selecting the best parameters, I often use Taguchi experimental design method; 2. I don't know, maybe, check it manually

    • @hendazorganiagrebi8176
      @hendazorganiagrebi8176 4 года назад

      @@SolvingOptimizationProblems for more questions can you give me your Email? I'm a PHD student and i need more information

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад +1

      My email is on my blog in the description! Thanks for watching!

  • @HarpreetSingh-qe4oc
    @HarpreetSingh-qe4oc 2 года назад

    is there some commercial online solver available for matlab GA function?

  • @NasirUddin-im2zb
    @NasirUddin-im2zb 4 года назад +1

    how to write the objective function for GA if I have 7 input variable ?

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      Hi, just add x3, x4, x5, x6, and x7 in the same procedure as shown in the matlab code. Is that clear? If still any problems, just let me know. I will explain it in more details

  • @quicknaturalbeauty
    @quicknaturalbeauty 7 месяцев назад

    Nice explained

  • @vasundharavsvnit4209
    @vasundharavsvnit4209 3 года назад

    IS ROUTING AND WAVELENGTH ASSIGNMENT IN ELASTIC OPTICAL NETWORK CAN BE DONE USING GA IN MATLAB?

  • @jamesomirambe9586
    @jamesomirambe9586 4 года назад

    i want to optimise the kuz ram fragmentation model how could the coding be like? can i use the GA solver still or .

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      Hi, we need to see the problem formulation before deciding whether the GA solver can be used or not? If your problem has many constraints, GA solver should not be used.

  • @pooriaghasemi
    @pooriaghasemi 2 года назад

    How can use ANN as objective function in GA optimization, I wanna minimize ANN value

  • @anggacahyaputra
    @anggacahyaputra 3 года назад

    Thank you sir for this video. Honestly, I need your help for my thesis. Could you please help me?

  • @carlgauss6383
    @carlgauss6383 3 месяца назад

    can we use integration in the place of summation
    i just want to find optimal control for my Mathematical model
    how should i do it matlab
    can u help??

  • @kamalpreetsingh6810
    @kamalpreetsingh6810 4 года назад

    Thank you Sir for this perfect video, who to resolve this error
    Optimization terminated: average change in the spread of Pareto solutions less than options.FunctionTolerance.

  • @aatifameer6914
    @aatifameer6914 4 года назад

    Thank you sir, It's really helpful. I have a project on optimization of leaf spring using a genetic algorithm. Can you please let me how to solve this problem.

  • @MohammedIbrahim-px7cc
    @MohammedIbrahim-px7cc 5 лет назад +1

    How can I use this in distribution system restoration??

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  5 лет назад

      hi, we need the objective function and constraints of the distribution system restoration

    • @MohammedIbrahim-px7cc
      @MohammedIbrahim-px7cc 5 лет назад

      Solving Optimization Problems the constraints could be tested by load flow but but how to determine the objective function

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  5 лет назад +1

      @@MohammedIbrahim-px7cc objective function is what you want to maximize or minimize. for example, minimize the total cost, or maximize the utilization, etc

  • @dothis1945
    @dothis1945 4 года назад +1

    Can I solve the problem which having more than 2 variable?

  • @syuhadasaridi9282
    @syuhadasaridi9282 4 года назад

    hi sir can I apply this code to appliance scheduling problem?

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      Hi, no, this solver is often used for continuous optimization. Scheduling is often discrete optimization. We need other methods. Please check other videos on this channel.

    • @syuhadasaridi9282
      @syuhadasaridi9282 4 года назад

      @@SolvingOptimizationProblems i see, because I use greedy method for my appliance sched and i dont know how to convert to Matlab, can you help me sir :/ I just want to get low cost for bill

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      Hi, you can design a genetic algorithm for scheduling optimization.

  • @yaraali4493
    @yaraali4493 4 года назад

    Thanks..
    Can I solve problems that have maximization objective function using this solvar??and how?

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад +1

      Yes, but we need a small modification in the objective function

    • @yaraali4493
      @yaraali4493 4 года назад

      @@SolvingOptimizationProblems
      Ok thanks, i send to you on messenger the problem can you check it please.. thanks a lot..

  • @amianifineug1353
    @amianifineug1353 3 года назад

    Thank you for sharing the video! Please I want to use my structure using Silvaco and I use GA with matlab
    how I use AG matlab is an interface ( matlab and silvaco) Thank you

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  3 года назад

      Hello, I've never tried to connect silvaco with Matlab. You should Google on how to make that connection! Good luck!

  • @godsgracegirlg3761
    @godsgracegirlg3761 3 года назад

    hi,thanks for such a good video.
    however while running the function through optimization tool & through the generated code ,why i am getting different fval.

  • @jufanglue
    @jufanglue 5 лет назад

    I did not found out GA solver in the APPs, wondering to know does it a toolbox we need to purchase ?

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  5 лет назад

      You may try to type "gatool" on the Matlab commend window or consult the Matlab customer service directly

  • @Mr1kkkkk
    @Mr1kkkkk 4 года назад

    Hello sir...i am searching matlab code for linear antenna array optimization using genetic algorithm....please help

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      To solve linear programming problems, there are several free LP solvers in Python and Matlab. Have a look at my channel for details of how to use them.

  • @mohanraj3904
    @mohanraj3904 2 года назад

    Hi , cloud please help me , how to optimise pipe climbers problems

  • @tamojit1992
    @tamojit1992 4 года назад

    Sir, I am dealing with a genetic algorithm problem where I cannot define my variables to the objective function. My variables generate a result in another simulation software. That result will be given in the objective function. With every simulation run result will be stored to the objective function. How to write the GA code to get optimized values of variables? NB- simulation platform is connected to Matlab and can be controlled by Matlab

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      It depends on complexity of your probem. Maybe you can use GA solver in Matlab or develop your GA from beginning. Have a look at some of my videos and then you should be able to decide to use GA solver or develop your own GA. Maybe you can customize my GA codes on my videos to solve your problems

  • @temesegenabuhay9408
    @temesegenabuhay9408 3 года назад

    how to use Optimization problem using Genetic algorithm in matlab for locating new fire station. i need your help me ???

  • @beautyisinmind2163
    @beautyisinmind2163 4 года назад

    when I put generations number = 200 and run the code, it stops after 160 generations and gives the solution, does it mean I stuck in local minima??

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      Maybe and maybe not. It depends on a lot of things. Set the tolerance to 0 and try different sets of parameters.

  • @alsaidalmetwally5671
    @alsaidalmetwally5671 4 года назад

    Please can yo let me know How can I implement multiobjective optimization using matlab . Number of variables are 3 and number of responses are 3

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      Hi, that video has been made on my channel. Please have a look at a video with title: "How to solve triple objective optimization problems using Matlab". Thanks

  • @sharbanipurkayastha2707
    @sharbanipurkayastha2707 4 года назад

    Sir i want to minimise the distance between points. The number of points are huge (3000). How can i model it using GA?

  • @melika4601
    @melika4601 4 года назад

    hi sir. i have a project which is to find the min value of the given fx (fx should be single-variable and can be whatever the user wants) by using genetic algorithm. for example the user enters f(x)=x^2-1 as an input and program should give us the min value for this function by using GA algorithm.
    i don know how to implement it . it should be in python. plz help me

  • @yuganshjain2519
    @yuganshjain2519 4 года назад

    Dear sir,
    I want to implement GA in stock market prediction and want the Sharpe ratio as an objective function. If you could help it will be very helpful.
    Thank you very much in advance.

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      Hi, how can I help?

    • @yuganshjain2519
      @yuganshjain2519 4 года назад

      @@SolvingOptimizationProblems I am not getting how to initialize population for trading strategies.
      If you can help I will be very thankful.

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      @@yuganshjain2519 Initial population is a set of random feasible solutions. Based on your constraints, use random functions in matlab or python to generate the solutions. Sometime repair process is required to ensure the solutions are feasible.

    • @yuganshjain2519
      @yuganshjain2519 4 года назад

      @@SolvingOptimizationProblems can you share you email id ?

    • @yuganshjain2519
      @yuganshjain2519 4 года назад

      @@SolvingOptimizationProblems I can explain more clearly to you .

  • @amianifineug1353
    @amianifineug1353 3 года назад

    thank you lot
    please where I save the file matlab? because
    when I declare the function @name of function. I received the following message """ the file does not exixst))""" Thank you

  • @nihith323
    @nihith323 4 года назад

    hello sir but when i run i get
    Error running optimization.
    Too many output arguments.
    what should i do? what am i doing wrong??
    if anyone knows pls help

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      Hi, that's because your objective function is not correct. Try to understand my objective function and customize it to solve your problems

  • @Aavaj_Marathi
    @Aavaj_Marathi 4 года назад

    Sir,can you make a video on duel level genetic algorithm..

  • @BarathTirumuruhan
    @BarathTirumuruhan 4 года назад

    Each time I run the solver I get a different prediction. So how do I conclude that the obtained prediction is the best one?
    Thanks in advance :)

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      That is the weakness of all search based optimization algorithms like GA, PSO, SA, etc. To overcome this issue, we should run the algorithm a number of times, say 30 times, and then select the best solution.

    • @BarathTirumuruhan
      @BarathTirumuruhan 4 года назад

      @@SolvingOptimizationProblems Thanks a lot

    • @BarathTirumuruhan
      @BarathTirumuruhan 4 года назад

      what is the reason for clearing the results each time?

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад +1

      @@BarathTirumuruhan There is no reason. It is just my habit.

    • @BarathTirumuruhan
      @BarathTirumuruhan 4 года назад

      Oh.. thanks again

  • @deviroseobligado3159
    @deviroseobligado3159 4 года назад

    Hello sir! Can you make a video optimizing a yagi-uda antenna by maximizing it's gain using GA.

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      Hi, I don't have that background. But you can update the objective function and constraints, and use GA solver as shown in this video to solve problems in your fields.

    • @deviroseobligado3159
      @deviroseobligado3159 4 года назад

      How to write 10 log base 10 in matlab?

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      @@deviroseobligado3159 Just use this syntax: y = log10(x)

  • @eusandre95
    @eusandre95 4 года назад

    Hi, can I ask you to which Matlab GA parameters correspond the parameters used in this scientific paper? "Analysis and dimensional synthesis of the DELTA
    robot for a prescribed workspace" - M.A. Laribi, L. Romdhane, S. Zeghloul
    I'm trying to make the dimensioning of a delta robot using this approach but the results of my optimization are not as good as the one obtained in this paper. The name of their parameters are different from the one in Matlab so I can't run the algorithm like them, and I think this is the problem.
    Could you suggest me how should I tune them? Thank you
    I leave here the parameters table with names in case you can't open the paper due to copyrights.
    The population size Nind: 70
    The maximal generation number MaxGen: 100
    The variable number Nvar: 4
    The generation gap Ggap: 0.85
    The mutation rate F1: 0.64
    The shrinking mutation factor F2: 0.615
    The recombination rate Opt1: 0.623
    The shrinking recombination factor Opt2: 0.553

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      As far as I known, the most systemmatic method for parameter tuning is Taguchi experimental design. I used this method a lot in my research papers. For tuning parameters of GA solver, I recommend you to google: maximizing performance of Genetic Algorithm solver in matlab, to look at the first paper appears. Let's me know if you have any questions. Good luck.

  • @taruntej7556
    @taruntej7556 5 лет назад

    hello sir,can u provide me the matlab code for optimal sizing of Hybrid power systems??

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  5 лет назад

      Hello, I don't know hybird power system but I have several genetic algorithm codes to solve several optimization problems. Have a look at my channel and let me know which code you want - I will send it to you

  • @PARTHAPRATHIMDAS
    @PARTHAPRATHIMDAS 2 года назад

    Sir, why you use music instead of your voice?
    If you use voice, it'll be more effective I think.

  • @jonynababan2499
    @jonynababan2499 4 года назад

    Hello Sir, i want to do optimization to fuzzy logic by using genetic algorithm.
    how can i do that? please help me

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      Can you be more specific?

    • @jonynababan2499
      @jonynababan2499 4 года назад

      @@SolvingOptimizationProblems
      So i want to do optimization Fuzzy Inference System Uses Genetic Algorithm to determine scholarship recipients from students.
      I have data in the form of numbers like GPA from students and parents' salaries. I have done fuzzy and I want to do again optimization with genetic algotirhm but i still cant find it. Any source code or video or refrences would very helpful
      Can you help me?

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      @@jonynababan2499 Hi, first, formulate the problem (equations of objective function and constraints) and then use optimization algorithm to find the optimal solution. There are various matlab and python codes of GA, PSO, and SA algorithms in my youtube channel which you can customize it to solve your problems.

    • @jonynababan2499
      @jonynababan2499 4 года назад

      @@SolvingOptimizationProblems
      To be more specific I want to optimize the membership function of fuzzy logic with genetic algorithms.
      Can you show me a refrences like video, code or anything?
      or if i'm wrong please correct

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      Hi, I don't have any GA code to solve optimization problems related to fuzzy logic. Only thing I can do for you now is to advise you to customize my GA codes to solve your problems. You can download various codes from my blog: learnwithpanda.com

  • @meriemmdioud9249
    @meriemmdioud9249 4 года назад

    thank you for this perfect video, I have just question about how can I insert my own initial population which is well defined, for example, my objective function is to calculate the sum of each gene of the chromosome that I know the exact value of each chromosome of the initial population. how can i do this please.

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      Yes you can! Go to the "Options" -> "Population" -> "Initial Population"

    • @meriemmdioud9249
      @meriemmdioud9249 4 года назад

      ​@@SolvingOptimizationProblemsI tried this proposition, but the result is not equal to the sum of the chromosome. I need your help, can you please send me an email to my address email: meriemmdioud@gmail.com

    • @SolvingOptimizationProblems
      @SolvingOptimizationProblems  4 года назад

      Doesn't matter, we can just use only 1 sead initial solution. Let's have it a try

  • @parimalakopalle7639
    @parimalakopalle7639 3 года назад

    Sir.. could you please explain how to use ANN model as a fitness function for ga. Optimization tool has been removed in the 2021 version, could you please help me out. Please share your email.

  • @sanazghobadi9391
    @sanazghobadi9391 5 лет назад

    I want to smooth a time series of future investment in a water network, I have a limitation that is the annual budget, I want to minimize the total investment based on an annual budget and cut all the investment that is above the budget line which is our constraint, I would appreciate it if you could help me towards my problem.
    thank you in advance

  • @LifeisEnjy
    @LifeisEnjy 5 лет назад

    i am facing problems on an optimization problem. Can i get your email so that i can mail my doubts and ask about it.. Plz reply
    My problem is based on optimal water allocation to crops, having various linear, nonlinear and equality constraints.

  • @worldamazingvideos3500
    @worldamazingvideos3500 3 года назад

    sir please share the .m file also