Thanks .... Warning message and glass definition

Hi Arvinder,

It's funny you should write this morning, as I just realized that I made a mistake (two, actually) in my formula for the normal reflectance of a simple glazing, and I was just about to post a correction.

There are actually two files in the ray/src/cal/cal directory that should be helpful, which I forgot were there: - the exact solution for transmissivity based on normal transmittance and index of refraction - an approximate solution for the index of refraction and transmissivity based on normal reflectance and transmittance

If you run "calc" in the ray/src/cal/cal directory and enter:

  Tn = 0.85
  Rn = 0.05

Typing in "n" and "tn" will give you these results:


Checking this against the file, to which I've added the corrected formula for Rn:

  % calc
  Rn = rn + rn*sq((1-rn)*tn)/(1-sq(tn*rn));

  n = 1.4
  Tn = 0.85


We can see there's just a slight error in the approximations made in Playing around with these values in, I was able to get closer to the correct parameters for your glass type:

  n = 1.405

Actually, the first approximate result is probably good enough, but anyway, the correct glass specification should be:

  void glass class_lglass
  4 0.900 0.900 0.900 1.405

Sorry for the screw-up. The advantage of programming is that you can fix your errors (usually) before they do irreperable harm.



From: Arvinder Dang <>
Date: Wed Oct 8, 2003 9:50:41 AM US/Pacific

Thanks a lot Greg for responding to my questions and actually calculating the transmittivity for me .Your explanation of the same would definitely help to calculate it myself in the future. My results in comparison to Superlite seem reasonable unlike intially when there was a difference of about 25%.
I 'm sure there will be lots more coming your way :slight_smile:
Thanks Again