Spherical Harmonics

版本 1.0.0.0 (2.2 KB) 作者: Daniel Ennis
This function generates the Spherical Harmonics basis functions of degree L and order M.
11.4K 次下载
更新时间 2005/10/5

查看许可证

This function generates the Spherical Harmonics basis functions of degree L and order M.

SYNTAX: [Ymn,THETA,PHI,X,Y,Z]=spharm4(L,M,RES,PLOT_FLAG);

INPUTS:

L - Spherical harmonic degree, [1x1]
M - Spherical harmonic order, [1x1]
RES - Vector of # of points to use [#Theta x #Phi points],[1x2] or [2x1]
PLOT_FLAG - Binary flag to generates a figure of the spherical harmonic surfaces (DEFAULT=1)

OUTPUTS:

Ymn - Spherical harmonics coordinates, [RES(1) x RES(2)]
THETA - Circumferential coordinates, [RES(1) x RES(2)]
PHI - Latitudinal coordinates, [RES(1) x RES(2)]
X,Y,Z - Cartesian coordinates of magnitude, squared, spherical harmonic surface points, [RES(1) x RES(2)]

NOTE: It is very important to keep the various usages of THETA and PHI straight. For this function THETA is the Azimuthal/Longitude/Circumferential coordinate and is defined on the interval [0,2*pi], whereas PHI is the Altitude/Latitude/Elevation and is defined on the interval [0,pi]. Also note that the conversion to cartesian coordinates requires that PHI be offset by pi/2 so that the conversion is on the interval [-pi/2,pi/2].

引用格式

Daniel Ennis (2024). Spherical Harmonics (https://www.mathworks.com/matlabcentral/fileexchange/8638-spherical-harmonics), MATLAB Central File Exchange. 检索时间: .

MATLAB 版本兼容性
创建方式 R14
兼容任何版本
平台兼容性
Windows macOS Linux
类别
Help CenterMATLAB Answers 中查找有关 Sources 的更多信息

Community Treasure Hunt

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

Start Hunting!
版本 已发布 发行说明
1.0.0.0