ZernikeLegendreFit: Fast, precise, high-capacity fitting

Version 1.0.1 (3,22 KB) von Yiwen Fan
Rapid and accurate surface fitting via orthogonality and Legendre quadrature, supporting thousands of Zernike terms.
120 Downloads
Aktualisiert 16. Mai 2024

Lizenz anzeigen

Function for fitting a surface with Zernike polynomials
Author: Yiwen Fan (yfan22@ur.rochester.edu)
Institute of Optics, University of Rochester
Usage:
[amn, bmn, z_recon_map] = ZernikeLegendreFit(z_map, M, N, J, K, center_x, center_y)
Description:
This function fits a given surface to Zernike polynomials, supporting up to hundreds of terms. It returns the coefficients of the fit and the reconstructed map.
Inputs:
z_map - The sag table of the surface to be fitted.
M - The highest azimuthal fitting order.
N - The highest radial fitting order.
J - The sampling number in the azimuthal direction, default: 2*M+1
K - The sampling number in the radial direction, default: 2*(N+1)
center_x, center_y - The center of the surface. If not provided, it will be calculated by the FindCenter function.
Outputs:
amn, bmn - The coefficients of the fitted Zernike polynomials.
z_recon_map - The surface map reconstructed from the fitted coefficients.
Acknowledgments:
This work was inspired by the research of Greg Forbes and funded by the National Science Foundation I/UCRC Center for Freeform Optics (IIP-1822026, IIP-1822049).
Part of this work was contributed by Ilhan Kaya in 2010, who wrote the initial jacobiZernike function. This function was later revised by Yiwen Fan and renamed jacobiZernike_table.

Zitieren als

Yiwen Fan (2024). ZernikeLegendreFit: Fast, precise, high-capacity fitting (https://www.mathworks.com/matlabcentral/fileexchange/132713-zernikelegendrefit-fast-precise-high-capacity-fitting), MATLAB Central File Exchange. Abgerufen .

Fan, Yiwen, et al. “Fast Zernike Fitting of Freeform Surfaces Using the Gauss-Legendre Quadrature.” Optics Express, vol. 32, no. 11, Optica Publishing Group, May 2024, p. 20011, doi:10.1364/oe.523022.

Mehrere Stile anzeigen
Kompatibilität der MATLAB-Version
Erstellt mit R2023a
Kompatibel mit allen Versionen
Plattform-Kompatibilität
Windows macOS Linux

Community Treasure Hunt

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

Start Hunting!
Version Veröffentlicht Versionshinweise
1.0.1

Update "cite as" with the paper

1.0.0