Multivariate nonlinear equation generation

I have data for 5 water quality variables, 4 independent (x) and 1 dependent (y) (nitrite), data attached. I am needing help with developing code that will generate a non-linear equation, and the constants associated based on the data. Is this possible?
I tried using the curve fitting app with "custom equation" which is similar to what I am looking for, but it is only for one x variable and not multiple.
Any suggestions would be greatly appreciated!

Respuestas (1)

Walter Roberson
Walter Roberson el 23 de Jun. de 2021

0 votos

No, it is not possible in the form stated.
Given any finite number of points expressed in finite precision, then there are an uncountable infinity of equations that fit the data perfectly (to within round-off error.)
Because there is an uncountable infinity, the probability that any one equation will be the "right" equation, is zero. 1/infinity is 0.
Therefore, it is mathematically impossible to automatically generate equations in any meaningful way.
The situation changes if you have a finite list of models whose parameters are to be fitted. In theory in such a situation, you could look for the model out of the list that had the best fit. In practice, it is common for mathematical accidents to result in widely different models to come out as good to within any reasonable error bounds. In practice, if you create some synthetic data with even a little noise, and run it through automated fitting algorithms, it is common for a different model to fit a little better than the one matching the true model.

3 comentarios

Nicola Elardo
Nicola Elardo el 23 de Jun. de 2021
Do you know of any automatic fitting algorithms that would work here?
Walter Roberson
Walter Roberson el 23 de Jun. de 2021
Which models would you like to fit against?
Alex Sha
Alex Sha el 24 de Jun. de 2021
Is it correct that all values of dependent (y) (nitrite) are zero?

Iniciar sesión para comentar.

Categorías

Más información sobre Linear and Nonlinear Regression en Centro de ayuda y File Exchange.

Preguntada:

el 23 de Jun. de 2021

Comentada:

el 24 de Jun. de 2021

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by