Wednesday 26 November 2014

Burning chips!



No - not that sort of chips! Integrated circuit PIC microprocessor chips!



"Look - I've done it! I've burned the Pic programs onto the 12F675!" says Mrs G

Yes, yes Mrs G - well done! But you are just copying our programs onto our hardware systems! We are the ones that did all the clever stuff!  :)


not so bright...

Our red LEDs use about 2V and about 20mA so use about 0.04W (we should measure this really) and for a red led the brightness is about 70 lm/W so a total luminous flux of about 3 lm if it is 100% efficient. A typical efficiency for Red LEDs . It emits most of its light forwards so illuminates, say 1m2 at a distance of 1m (to make the numbers easy!) this corresponds to about 3 cd or 3 lx (they are the same value at a measurement distance of 1m!)

These are very rough numbers, but in a dark room, Luxmeter app on the iphone measured the LED brightness as 1 lx and a candle as 2 lx too so our LED seems to be similar to a candle (although I'm not convinced how dark the room was or the accuracy of Luxmeter at these light levels) 

We would need to measure things more precisely to get absolute light intensity, but we can measure our light source brightness relative to our standard LED for now. 

How can we make it dimmer? One easy way is to switch it off for half the time, and then it will emit only half the light! If we switch it on and off really quickly, quicker than the persistence of vision it will be perceived as just a dimmer source. In practice, this means more than about 60 times per second (60Hz) in bright light or about 10 times per second in dim light (10Hz) due to the difference in integration time between cones cells (10-15ms) and rods (100ms). 

We can do this by programming a microchip PIC 12F675 chip to control the LED. We can use JAL a simple programming language to write a program and then compile it and load it onto the chip, so that when we supply power to the chip it flashes the LED. 

Here is an example program that we can modify to make our LEDs flash!



Actually, the only bits we need to modify are the delay statements (giving delays in microseconds) and the instructions to set the LED pin high (LED on ) or low (LED off) - easy! ...and here's the hardware circuit!


(much easier circuit than our flashy LEDs because we did all the work programming the chip and don't need lots of different components!)

To start with, we will just make them flash slowly to make sure everything works, and to flash our name in morse code (because we can!)

Bright lights!

We know we see very faint lights in black and white rather than colour (stars all look white apart from Betelgeuse and Aldebaran) and that really faint things can be seen better out of the corner of our eye - our theory is that this is because the cones cells in the eye see colour and rod cells in the eye cannot differentiate colour but are more sensitive to low light. 

We can test these ideas in our field of vision test box! We have started to test the angular field of view (results later) but if instead of just using standard LEDs as the light source at different angles, we control the colour and brightness we can investigate how faint a light we can see and when we stop being able to see colours at different angles...

To do this we have two problems:
1 - How bright is a light? how do we measure brightness?
2 - How can we make a faint light and make lights of know brightness (or at known relative brightness)

First (we'll deal with the second issue in another post) what do we mean by brightness? Bright enough to see by? Bright enough to read by? An obvious (to a physicist!) definition would be a measure of how much light energy a light gave out, but that is complicated because different colour photons have different energies (ultra-violet photons have much more energy than red photons for example, but we cannot see in ultra-violet so energy by itself is not very useful for measuring brightness). We could count the photons themselves, which would be better, but would not help us define a bright light because again, we do not see all photons equally - the cone and rod cells have different ranges of sensitivity (and again do not respond to ultra-violet or infra-red photons...). What we want to measure is how many visible photons come from a given source or area and weight this by how sensitive our eye is to them. 

In fact this makes it easier - we just need a standard light and compare all other lights to that!

Scientists wanted to do this a long time ago so they picked the most obvious standard light for the time - the Standard Candle and this remains (more or less) the official unit for luminous intensity (brightness) or amount of light emitted per unit solid angle.

There are some other units that are important when quantifying how bright something is...

The further away the candle is, the fainter it appears because the light is spread out - we are actually more interested in how much light is arriving in our eye than how much is given out by the light. We define the Candela (cd) in terms of a rather precise type of light source now, but a standard candle emits light with an intensity of about 1cd and this is a measure of the energy of visible light per unit solid angle - this is the luminous intensity of the light. 

We measure the total amount of light given out by a light source, the luminous flux (measured in Lumens, lm), by the luminous intensity (measured in Candela, cd) multiplied by the solid angle over which it is emitted. Finally, we measure the amount of light arriving at a surface (measured in Lux, lx) in lumens per unit area (!) All of this has to be defined in terms of a frequency of visible light and related to the sensitivity of the eye! It's complicated!

So if you are comparing light bulbs to buy, you are interested in how many lumens they give out, if you are interested in whether you can see a faint light you are interested in how many lux it gives at your eye.

We tested this initially last week and used a iPhone Luxmeter app to measure the brightness of a candle (standardish!) in Lux and compare to one of our LEDs but I lost the results! Oops - we'll have to repeat it...

UPDATE!
Some of us remembered the LED and the candle both gave readings of about 1 lx at a distance of 1m (reassuringly the candle gives out 1 cd!)

As memory is not very infallible, I repeated it it in the darkest room at home and got 1-2lx for the candle and 1 lx for the LED - the candle gave 4lx ish at 0.5m (it should be 4 times more lux at half the distance) so it looks like our LEDs are similar to standard candles given the uncertainties associated with Luxmeter at low light conditions and the problems of background light and reflections....)


Wednesday 5 November 2014

Triangles in the Blind-spot Box

Our new blind-spot measurer allows us to read off how far the eye is from the test card when the spot is in the blind spot, but what is the angle? It would be inconvenient to have to get a protractor out each time and measure the angle directly!

Fortunately, there is a simple relationship between the lengths of the sides of triangles ad the corresponding angles! This has been studied since ancient times (pyramids, timings of sacrifices etc…) and is now known as trigonometry. 

If you look at right-angled triangles with the small angle on the left...

If you put together 4 small triangles you make one big triangle that has all the same angles, and the sides are exactly twice as long. This means that for the big triangle the ratios of the sides are the same as for the little triangles. We can add more little triangles to make bigger and bigger triangles and the ratio of the upright side length to the bottom side length will stay the same. In fact it is the same for any triangle with these angles. So if we know the angles of a right-angled triangle, we know what the ratio of its sides will be (so long as we have measured that ratio on any similar triangle). Likewise, if we know the ratio of the edges, that will determine the angle.

This is just what we want! We know that the separation of the dot and cross is 7.4cm, and we measure the distance from the eye to the cross (it is marked on the box and add 1cm for the distance of the eye behind the window) so we can calculate the ratio. 


All we need is for a list of the ratio of these sides for every possible angle!








Fortunately (again) someone has done this for us! Islamic mathematicians invented the field of trigonometry in about the 9th century, and made tables of the ratios of triangle sides for all possible angles. These are SINE COSINE and TANGENT functions and you learn it in GCSE maths because it comes in useful in lots of areas of science. (Islamic mathematicians invented lots of the basic concepts of mathematics and lots of the words used are derived from Arabic).

Here’s the table we need:



Now all we need is 300 volunteers to measure!

Friday 24 October 2014

Big Fish - Little Fish -

We've been building the experimental equipment...



Easy test equipment for the rest of the school to measure their blind spot angle - they look through the hole and slide the test card back and forth until they find the point at which their blind spot hides the dot - then we read off the distance and make a look table to find which angle that corresponds to! Quick and easy! We'll bribe them with a thinky so they do the experiment for us!

(Here's thinky the monocular-illusion-dragon! (look at him with one eye closed... ) 

We made lots of him and everyone except those with an over-intelligent visual cortex thought he was very cool/wierd)





Field-of-vision test box - we look through the hole in the middle and we will position LEDs poking into the box that we can light up and see if we see them whilst we look straight ahead. We will be able to measure field of view and sensitivity to how bright they are and sensitivity for different colours :)

Fair enough!

We need to be sure that our random flash LED light really is random or else sneaky brained visual cortexes will keep checking over where the light flashes most often, and we need to know if we are going to use it as an electronic dice for gambling of course! (Not encouraged by the 'Out of Sight' Blog or the Royal Society of course).
Lots of us did a tally count test of lots of blinks...
I've put the results in a spreadsheet to make it easier to see :)

Is that what we expect? It is difficult to say exactly - you could just be very lucky and keep rolling sixes even if it is uniformly random, but there is a test you can do which tells you the probability that you would get results this different from the ideal equal proportions of each number - the Chi-squared test. You can see that there is a bigger than 10% chance that our results would be at least this uneven for most individuals and for the combined total - student 6 looks to be a bit odd though... 99.5% probability that data like theirs isn't generated by a fair circuit! Maybe the capacitor was big so their LEDs flashed slowly, and then if they were testing quickly the LEDs selections would not be independent (or maybe they didn't like 5s and cheated?)

Wednesday 22 October 2014

Production line

The MASH toys were fun but for our visual field test equipment we need to place the LEDs where we want them so they need long leads...

We went into production line mode exploiting the readily available child labour!




Result!


For our Visual Field Test equipment, we also want the lights to be out most of the time and only come on when we press the button - this is kind of the opposite of the MASH circuit which shows the light most of the time and cycles round when we press the switch. It needs a bit of logic changing! 

The MASH circuit holds the ENABLE pin 13 of the 4017 counter high most of the time by connecting it to +5V by a 100k resistor which means the counter is stopped and only one LED is lit and stays lit. When we poke the yellow wire to earth, that pulls the ENABLE pin to earth (0V) which lets the counter go again and the lights start to flash round. Instead, we want the ENABLE pin to normally be connected to earth (by a little resistor) and pull it high (ie stop) when we press the switch to connect it directly to 5V. That's an easy rewiring.

Finally, we also want the LEDs to be off whilst the 4017 counter cycles round and round, and only the randomly selected LED to be lit when we press the switch. This is trickier, but if we just think about the logic levels, we want the LED anodes to NOT be earthed most of the time and only connect to earth when we press the switch. We could easily connect them all to the switch instead of earth, but the switch for the INHIBIT pin is normally earthed and goes high when we press it which is the exact opposite to what we want! The answer is to put an invertor in between which changes 5V to 0V and 0V to 5V. We could do this with a chip but there isn't much space and the easier way is to use a Transistor Resistor Logic (TRL) inverter circuit - shown below. It works for us with a 2N3904 transistor and Rbas 100k and Rcol 10k.
Finally (really finally!) we can use all the outputs of the 4017 instead of just 6 of them by changing the reset pin to connect to pin 11 instead of pin 5.

Wednesday 8 October 2014

Making a difference

Science can only make a difference if we tell people what we are doing - in university we have to publish our work so other scientists can find out what we are doing and come up with even better ideas! We did a poster about our club to show next year's pupils what we do and what they might get involved with next year - nice!
(by the way - it's not strictly true that we all have a blind spot... those of us that are octopuses don't)

Angular analysis...

Here are our data from our blind spot measurements

We can look at these in a Histogram - we sort the angles into size ranges and plot how many are in each range. If we make a sensible choice for the size ranges we can see where most of the measurements lie and how spread out they are (too many small size ranges and we just see the individual measurements like in the list: too few and they all end up in the same range and it doesn't illuminate our data...)

This looks like there is a typical value in the 15-20 degree group and some spread about that value. This is quite normal for many properties measured in nature where values are 'randomly' spread around a central value. The spread can be due to natural variation (like for example peoples height) and also due to measurement error.
We can fit a Normal distribution - a mathematical characterisation of the variation - which gives a mean and a standard deviation parameter. The mean is the average value and the value we would Expect to find if we measure someone new. The standard deviation is a measure of how spread out the measurements are. Most (about 95%) values are within two times the standard deviation of the mean value. In the next figure you can see the red curve which is the fitted distribution showing the relative Likelihood of a given value being measured.

Of course, the more measurements we make, the more Confident we can be about these values. In fact we have quite a small Sample (only 9 of you recorded measurements) and so the mean value is uncertain. We can estimate how uncertain the estimate of the mean is (!), and the green curve shows the likelihood of the true mean angle taking different values.



The mean angle of our blind spot is therefore found (with 95% confidence) to lie between 16.2 and 21.5 degrees horizontally from the line of central fixation.

This is bigger than Wikipedia tells us (if you look up blind spot on Wikipedia it gives 12-15 degrees. Why are our numbers different?)

If you look closely, the wikipedia entry comes from a US military spec document for the design of optical displays and equipment that needs to be viewed so is a rather specific source for the angle. Another reference (http://www.ncbi.nlm.nih.gov/books/NBK220/ - also US) gives 12-17 degrees.

Possible reasons why our number is different include...
1) Errors (did we measure it badly?)
2) Bias due to not considering how big the blind spot is (ie did we always measure the outer limit of the blind spot which is about 5 degrees wide?)
3) Random discrepancy due to our small sample size (we just happened to measure eyes with big angles to the blind spot...)
4) Wikipedia's source reference is wrong or untypical?
5) We are both right but UK children's eyes have a bigger angle that US soldiers eyes (they are changing as we grow? or US soldiers exclude people who can't see perfectly so form a biased sample? or US soldiers are mostly men whereas we are fairly equally boys and girls? or ...)

We could test some of these ideas by measuring a bigger sample of eyes, perhaps improving our techniques, sampling boys and girls separately, and also recording how old the eye is that we measure...


Wednesday 1 October 2014

Chemical codes

To see our photos you need to go to this link




and log in with a google account. In case you haven't got one I made one for you!
It is corbetscience@gmail.com 

Oh and you need a password! It is 8 92 t - 8 9 - 14 g 1 t except of course it isn't (I've coded it to be safe and secure - it is all lower case and there are no spaces but the hyphens are real. You know when you've cracked the code!)

You can also use this account to edit and add stuff to the blog (be sensible!)

M.A.S.H.

To measure the field of view we need to make our own visual field test equipment - in particular, we need to make one to test peripheral vision that we can also use to investigate rod and cone cell sensitivity in our peripheral vision...

I call it M.A.S.H. - "Multi-light Automated System to measure Human field of view"

I think we can adapt a system from card, sticky-back plastic and an electronic dice project...
Here is a electronic dice design we could use to control LEDs

...and here is a simplified version we can make on our proto-board kit using the 555 Timer in astable mode to send a stream of counts to a 4017 Counter chip with a reset after 6 counts. If the counts from the 555 Timer are fast, it will be random and allow us to light a random LED whilst our subject looks at a central point.


Anamorphic illusions

One of us found these photographic optical illusions - very cool! :)
click to watch!
And this is a nice optical illusion project...

Tuesday 30 September 2014

Filling in the gaps

As the kit might not have arrived, here's another bit of the vision project we should try an investigate... When we dissected the eyes, we saw where the optic nerve comes in - thats going to take up a bit of the retina kind of near the middle, but we don't see a hole in our view where the retina doesn't have space for photo-receptor cells. This is the 'blind spot', but it doesn't seem like we are blind there... We know that our brain does quite a lot of processing from the optical illusions we looked at at the start, and our brain helps here by filling in the missing part of the picture! How good is the brain?

Here is a simple test to measure where our blind spot is...




If you follow the link there are a series of additional test cards that show how good our brain is at making up missing data! We can make our own tests and see what our brain can fill in!

Sunday 28 September 2014

data

We need to record the data - that's what is real!
I hope everyone made notes, at the time, about what they saw with their eyes, as that is what was there!
Here is what your teachers gave you to describe a human eye...

Is that the same as you saw dissecting the pig's eye?






Here are a couple of the records of what we saw - there are more on our google+ photo site


 ...and... (!)

Wednesday 24 September 2014

I eye


Ishihara

We are going to investigate colour vision so a first experiment is to give ourselves a colour blindness test. The standard test is the Ishihara Test with 38 cards. If we are lucky, we will have a colour blind person in the group and can compare their responses with other peoples!
Here is a link to an online test so you can test yourself (note that this is not a reliable diagnostic approach as screen display of colours can vary, but it should identify if you are completely colour blind!)

Can you see the coloured number?


Ha ha! That one is in black and white so as not to be unfair to colour blind people :)

We tried the real test and here are our results:

Hmm... what does it all mean? There are some indications that student 5 may have colour deficiency, and that possibly student 2 has discalculia (!) and that most of us weren't sure how to describe the test cards that had sxquiggly lines on... We can do some analysis on the spreadsheet but probably more interesting just to go back to those that had anomalous answers and check what they see!


Friday 12 September 2014

A working hypothesis

The Feynman lectures on physics are an interesting read. It is for undergraduates really so it is quite a hard read in many places, but the chapter on colour vision is an interesting not-too-technical overview of how the eye works. 

You can read it online here!


I think this would constitute a good working hypothesis for some work to characterise and uantify our colour vision?

Thursday 11 September 2014

It's all in your mind...

To start things off, thinking about how good our sense of sight is as a scientific data collection instrument, we explored how accurate our powers of observation are and some ways in which we can get false observations (did you realise that was what you were doing?)
First we tested how selective our observations were. In this video...

...no one got the number of white player passes exactly right but everyone was close (a range of recorded passes of between 12 and 16 with the exact result being 15 so an error of up to 20% on just counting to 15!) and half the group did not record the additional interesting observation! It just shows how difficult it can be to make detailed observations particularly where the data do not fit our hypotheses – our mind filters the information and applies an interpretation to what we see before it gets into our conscious mind - let alone being able to keep it accurately in our memory.

Here are some some quite alarming illustrations of how selective our observations can be!
So if our brain is applying some data processing to the data sent from our eyes – how easy is it to exploit that processing to trick our brain into seeing more than is really there?

We started making 3d selfies – the pictures are just flat, but we can arrange for our eyes to each see slightly different things by using colour filters. The left eye gets a view that emphasises a photo taken from one position that is made redder by having a red filter in our ‘3D glasses’. The right eye has a blue (cyan actually which is green and blue) filter which cuts down the red light and dims the first photo whilst allowing green and blue light from a bluey photo taken from four inches to the right. It preferentially sees the right hand photo. Thus each eye is presented with a view mostly made up of the same image that it would get if it was looking at a real three dimensional person. Of course there is a bit of the photo still getting through to the wrong eye, and the colours are all a bit wrong, but our brain knows what it expects and can tidy up the signal that it is getting down the optic nerve: we ‘see’ normal colours and our brain decides that it is looking at a three dimensional person – neat! It is just a flat pattern of colours, but by giving the brain something that it is used to seeing, the brain tidies up any minor inconsistencies and sees what it wants to! Very cool for making arty pictures but a bit worrying for being accurate when doing experiments if what we ‘see’ is what we expect and our brain tries to get rid of anything unusual or interesting (like a gorilla perhaps!).
Here’s one of our 3D anaglyph selfies!


and another...
left


right


3D


And a link to the program that overlays the two photos.
Oh, and a dragon :)




Next week we will try and find more ways to use what we know the brain will do to make interesting pictures (optical illusions!) and also make auto-stereograms – a different way to trick the brain into thinking it is looking at a 3D object (and also to hide a message!)

Here are our photos

You've got to be good!

We are planning to do measurements on ourselves and to do some potentially dangerous things too. Before starting to do these sorts of experiments it is important to consider carefully the effect our research might have on:
1) Ourselves! (we want to survive this club!);
2) Other people – we must not hurt or upset anyone else;
3) Animals – they have (some) rights too;
4) The environment – we have to keep coming to school after the club ends so we’d better not mess it up! (and Mrs Gerrard would be upset if we made a mess of the school – see (2) above).
This is an ethics review. We have to do a review of these issues, every time, before we do any research at University or at the Corbet. We watched this video:

to remind ourselves that different people might be upset by things we thing are not a problem and we thought about everything that we might be doing. I think it’s all OK but before we go further we have written to parents so they are informed and can give consent on our behalf for everything we might do to each other (now Dr Herbert can start experimenting on everyone! - mwahh-ha-haa!).

Here is our ethic review.

Out of sight!

We have been given a grant by the Royal Society to do some science and to buy lots of cool equipment to help us do the science and (I hope!) have fun.


This picture works because close up our vision can interpret the high frequency features in the picture (the lines defining the wrinkles and messy hair and moustache of Einstein), but when we are further away we only see the low frequency (blurry) aspects (that define the curves and smooth hair shapes of Marilyn).