edmundsj / rcwa

Rigorous Coupled Wave Analysis for the calculation of Photonic Crystal R/T spectra
MIT License
93 stars 29 forks source link

Energy conservation failing on triangular example but all tests passing #34

Closed edmundsj closed 2 years ago

edmundsj commented 2 years ago

Last working commit on develop branch was 089e52bbcf0d50a13812e333863ab0a764341010.

Need to find out what caused it to break and why the integration tests didn't catch it. If I haven't yet added full integration tests for triangular photonic crystal, that needs to be done.

Bizarrely, manually resetting all of my main source files to that commit does not appear to fix the problem, but resetting everything in the repository does.

edmundsj commented 2 years ago

This is now fixed on the develop branch by reverting to a previous commit, and unit tests have been added for all examples to ensure it does not recur. 22383ff