-
Notifications
You must be signed in to change notification settings - Fork 432
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
Help me understand energy scaling #352
Comments
Hi @Kanafani80 , you are doing a pretty deep dive into the code! 🤿 This is an excellent question. As is, This term is necessary to match the scales of the image source model and the ray tracing, as explained in Dirk Schroeder's thesis, Section 5.4 (in particular, page 75, equation 5.54). It is not called |
Thanks for the reply! I had not read that far into the dissertation ;) The scale matching idea makes sense to me. However, it seems that your calculation is using the cumulative distance travelled by the ray up to this point: Thanks again! |
In my understanding, the quantity relates the total energy of the source, to the fraction that impacts the receiver. |
Hi there! Thank you for this great repo.
I am having trouble understanding the following energy scaling that I see in a couple of places, for example in room.cpp when scattered energy is computed:
double r_sq = double(travel_dist_at_mic) * travel_dist_at_mic;
auto p_hit = (1 - sqrt(1 - mic_radius_sq / std::max(mic_radius_sq, r_sq)));
Eigen::ArrayXf energy = scat_trans / (r_sq * p_hit) ;
This seems different from the lambert cosine formula (which is indeed applied earlier). In the code above, r_sq will generally be much larger than the mic radius squared, so it seems p_hit will be tiny, which will make energy blow up.
What is the physical explanation of this? I can’t find the equivalent formula in either the wayverb or Schroeder dissertation.
thanks!
The text was updated successfully, but these errors were encountered: