How to fit a helix in 3D using cftool?

9 ビュー (過去 30 日間)
Dario Cortese
Dario Cortese 2019 年 7 月 31 日
回答済み: Navya Seelam 2019 年 8 月 5 日
I am trying to fit some helical data to a helical parametric equation, so as to find the pitch, radius and angle with respect to the z-axis.
If I use the cftool, this is what I am allowed to do in terms of customization (see pic below). There is no option for parametric equations, where the z data can be used as a time variable. Is there any way that this can be done? If not, what functions/tools/methods do you suggest?
sample.PNG

回答 (1 件)

Navya Seelam
Navya Seelam 2019 年 8 月 5 日
Hi,
Assuming the helical parametric equations to be
x=a*sin(z)
y=b*cos(z)
z=t
fittype” can be used to assign the model type to fit in order to obtain the parameters a & b.
myfittype=fittype('a*sin(x)');
ft1=fit(z,x,myfittype);
The same procedure can be used to obtain parameter b as well.

カテゴリ

Help Center および File ExchangeGet Started with Curve Fitting Toolbox についてさらに検索

製品


リリース

R2019a

Community Treasure Hunt

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

Start Hunting!

Translated by