Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

About theta and phi in directivity definition #37

Open
kirinf opened this issue Jul 19, 2023 · 0 comments
Open

About theta and phi in directivity definition #37

kirinf opened this issue Jul 19, 2023 · 0 comments

Comments

@kirinf
Copy link

kirinf commented Jul 19, 2023

Dear author,

https://github.com/GAMMA-UMD/pygsound/blob/8f41cb13da5dba9aa09cac3f42e668005ed5cf11/src/GSound/gsound/gsSoundDirectivity.cpp#L152C1-L179C160

In gsSoundDirectivity.cpp, According to the Macro definition of SPHERICAL( theta, phi ), it's

[0, 0, 1; 0, 1, 0; 1, 0, 0] * [ sin(theta) * cos(phi), sin(theta)*sin(phi), cos(theta) ]' =
[ cos(theta), sin(theta)*sin(phi), sin(theta) * cos(phi) ]'
,

which means x = cos(theta), y = sin(theta)*sin(phi), z = sin(theta) * cos(phi).

So I think theta represents angle between ray and X-axis; phi represents angle between ray's projection in YZ plane and Z-axis (as shown in the figure below).

Is my understanding correct?

9fd1d0a1a4cc2bd88b2ddb8e3db5770

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant