Search for question
Question

Programming Problem: Question 3: Design a genetic algorithm to solve the polynomial fitting problem that we did in Homework #1. You need to implement a genetic algorithm using BOTH mutation AND crossover operations. You need to decide a mutation rate and a crossover rate. Because the polynomial coefficients are numeric variables, consider using either numpy arrays or torch tensors to store their values. Plot the following in one figure: a) the original noisy data b) the polynomial you obtained in Homework #1 c) the polynomial obtained from this implementation Compare and discuss the difference in performance of the two polynomials obtained with two different methods. Note: if your solution for Homework #1 did not work correctly, remake it now using the Homework #1 method (numpy polyfit() function)

Fig: 1