# Calculating average power

#1

when i calculate reflectance, i get different reflectance for different wavelength. so i wanted to calculate the average reflectance in a range of wavelength. Is it possible to calculate average reflectance in a certain range of wavelength? if it is possible then what is the procedure. any help will be appreciated. thank you.

#2

you can use the integrate function :out = integrate(A, n, x1);
Integrates A over the nth dimension in the matrix.
x1 is the corresponding position vector for that dimension.
eg:out1=abs(integrate(real(Power),1,c/f*1e9))/300;
wish you can solve it!
–wumincai Northwest University,China

#3

can you how can i put it manually? as i can’t do scripting, i am doing the whole thing manually, or by adding materials, simulation region etc. thank you.

#4

Hi, @mrinmoy !

In case you have not read yet, this is the relevant page on measuring reflectance: https://kb.lumerical.com/en/layout_analysis_measuring_reflection.html
I recommend to look through the script in the example, to get better at calculating quantities you need, in particular, what @wumincai recommend.