# Pixel size = 5.45 um Gap size = 100 nm Spot size = 200 um Full well capacity = 10,500 electron how do i plot the COG of a spot imaged on a sensor with some photon noise

6 views (last 30 days)
daniel adegbeleji on 29 Jun 2020
Commented: Image Analyst on 30 Jun 2020
As a beginner in matlab programming how do I compute Pixel size = 6.45 um Gap size = 100 nm Spot size = 500 um Full well capacity = 10,300 electron to plot the COG of a spot imaged on a sensor with some photon noise

Image Analyst on 29 Jun 2020
I don't see how any of those numbers matter. If you have a digitized image, you can just call regionprops
[rows, columns, numberOfColorChannels] = size(grayImage);
if numberOfColorChannels == 3
grayImage = rgb2gray(grayImage);
end
xCentroid = props.WeightedCentroid(1);
yCentroid = props.WeightedCentroid(2);
That's the weighted centroid of the whole image. If you want the centroid of only a portion where the spot is brighter than some value, you can make a mask for that.

Show 1 older comment
Image Analyst on 30 Jun 2020
Then I guess it wants you to simulate what the electron counts on the sensor would be. But to know how many electrons are in a pixel well, you'd have to know the illumination level - the light exposure in lux, or photons per square micron per second, or something like that. Or we can just maybe assume uniform exposure in a circle centered at the center of the sensor and assume the wells in the circle have some percentage of the full well value of 10,300, like 90% or 50% or whatever. Obviously with a higher exposure you have more noise. Now, most novices will say "Wait - that can't be right. He's wrong about that.", but of course it is correct and I'm right. Higher exposure means more noise with a stochastic Poisson process. The signal to noise ratio is higher than a lower exposure, but so it the noise. But I'm sure you studied all that in your class so you know what I'm talking about.
daniel adegbeleji on 30 Jun 2020
Yes sir, you are right. How do I go about the simulation? I don't know the blocks to put together. The spot will be moved across the sensor i.e from left to right.
Image Analyst on 30 Jun 2020