Borrar filtros
Borrar filtros

extrapolation!!

4 visualizaciones (últimos 30 días)
alexis
alexis el 21 de Sept. de 2011
Hi everyone! I've got a big problem here...
I have some x and y values:
x=[14.57261875 14.72416687 14.85546972 14.96644958 15.09755813 15.23869218 15.33941339 15.4501601 15.58088007 15.67126492 15.75150771 15.79153196 15.8315562 15.89159258 ]
y=[9159.164387 9388.584929 9602.741855 9832.286745 10123.07262 10459.80477 10735.35812 11056.85775 11500.90152 11853.1149 12205.35936 12419.79607 12634.23278 12955.88784]
I use cftool to make a polynomial fit (3rd order). As you see the lower limit of x values is ~14.5. I want to extrapolate to x=9 but it's necessery to put some conditions for that. To explain if i use the fittedmodel(from cftooll) the required values is not what i want because ,since the equation is a third degree, the curvature changes.
If i know that curvature changes about x=7 how can i require from matlab not change the tilt-curvature?
Excuse me for my english...
Thanks a lot

Respuesta aceptada

John D'Errico
John D'Errico el 21 de Sept. de 2011
Shiver. You have data that lies between 14.5 and 15.9, and you wish to extrapolate down to x = 9???????????? Have you learned too little from the works of Mark Twain?
“In the space of one hundred and seventy six years the Lower Mississippi has shortened itself two hundred and forty-two miles. That is an average of a trifle over a mile and a third per year. Therefore, any calm person, who is not blind or idiotic, can see that in the Old Oölitic Silurian Period, just a million years ago next November, the Lower Mississippi was upwards of one million three hundred thousand miles long, and stuck out over the Gulf of Mexico like a fishing-pole. And by the same token any person can see that seven hundred and forty-two years from now the Lower Mississippi will be only a mile and three-quarters long, and Cairo [Illinois] and New Orleans will have joined their streets together and be plodding comfortably along under a single mayor and a mutual board of aldermen. There is something fascinating about science. One gets such wholesale returns of conjecture out of such a trifling investment of fact.” "Life on the Mississippi", Mark Twain, 1884
Ok. if you insist on doing this extrapolation down to an arbitrarily virtually random value at x = 9, then use a tool that can do it in style, and will have the properties you desire for that curve. My SLM tools will do exactly what you need.
slm = slmengine(x,y,'plot','on','knots', ...
[9 14.5 15 15.5 16],'increasing','on','concaveup','on');
Find SLM on the file exchange:
  2 comentarios
John D'Errico
John D'Errico el 21 de Sept. de 2011
Gotta figure out how to insert a figure one day. Maybe tomorrow. Maybe not.
alexis
alexis el 21 de Sept. de 2011
:) Thanks for this!!!
I have to apology.. I'm not so stupid to believe that such a process would give me realistic results! I'm naval architect and marine engineer. x is vessel speed and y=output power(bhp). As we know theoretically, Power=k*speed^(n), where n is between 2.5 and 4 depending on type of ship. I want only the trendline.... We cannot take a closed form type to describe the relation between speed-bhp. actually the curve has no constant slope.. but is a monotonic growing function, passing from (0,0).. somethin between f(x)=x^2 an f(x)=x^3.
Really thank you!

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Get Started with Curve Fitting Toolbox en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by