필터 지우기
필터 지우기

turn matrix into function ?

조회 수: 7 (최근 30일)
best16 programmer
best16 programmer 2017년 3월 27일
답변: John BG 2017년 3월 27일
i have two colomns a and b, i want to turn them into a function such as b=f(a),is that possible thank you

채택된 답변

Guillaume
Guillaume 2017년 3월 27일
There is an infinite number of functions that would fit the brief. Perhaps you're looking for a polynomial fit, a spline fit, or something else. It's hard to know with so little information.
f = @(x) b(a == x);
would be a function that fits the brief (and errors for any input that is not in a). I doubt it is what you want.
  댓글 수: 2
best16 programmer
best16 programmer 2017년 3월 27일
what i want is te determine the point of intersection between a curve and X axis.
Walter Roberson
Walter Roberson 2017년 3월 27일
What relationship does that have to a and b ?
For example do a and b together create a piecewise cubic spline?

댓글을 달려면 로그인하십시오.

추가 답변 (1개)

John BG
John BG 2017년 3월 27일
Hi Best Programmer
the problem you want to solve, the capture of intersections between curves that DO NOT have defined the exact points of interesection is already solved in the MATLAB exchange.
I have used Mr Schwarz's function intersections.m repeatedly and it always hits the points the right points:
at least 2 points per curve. Try it, it works.
if you find these lines useful would you please mark my answer as Accepted Answer?
To any other reader, if you find this answer of any help please click on the thumbs-up vote link,
thanks in advance for time and attention
John BG

카테고리

Help CenterFile Exchange에서 Spline Postprocessing에 대해 자세히 알아보기

제품

Community Treasure Hunt

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

Start Hunting!

Translated by