Using fminunc to find coefficients
Afficher commentaires plus anciens
I have a data table:
x: 0 1 2 3 4 5 6 7 8 9
y: -1 6 13 20 21 19 15 8 -2 -3
I have the functional form of the data to be : y = ax^2 + bx + c
My professor told us that we can use the matlab function fminunc to find the coefficients a, b and c but I can't seem to find any information on how to do this.
I know I can use the fittype and fit commands to do this, but I would like to know if it is possible to use fminunc, and if it is how would I go about it.
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Common Operations dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!