You're getting the expected result. What you see is the normal behavior of diodes in series and it's completely normal to have one resistor and a string of LEDs connected after it.
What's basically happening is this: When they told you that the forward voltage is 2 V, they lied. It actually depends on the current going through the LED and you can consider the 2 V some sort of nominal value, but the exact drop should be read in the datasheet (if it's available).
In general case when you want to connect diodes in series, you use this formula for resistor:
$$ R= \frac {V_{supply}-NV_{f}}{I_{f}}$$
where the N is number of diodes you have.
This way it turns into simple Ohm's law. But in your case, you're approaching the border at which the above formula will not hold. You basically have a circuit with one branch only and the current going through that branch isn't going to much change with the number of LEDs if the voltage of the supply is high enough to be higher than LED forward voltage.
Take a look at this diagram from Wikipedia:
Notice the point marked \$ V_d\$. For this diode, once the voltage at the diode terminals reaches that point, the current will start quickly increasing with only a small change in voltage. That is why adding more LEDs doesn't immediately affect current. The voltage is high enough that all LEDs will conduct. Should you for example put 10 LEDs in series, the voltage will be too low and they will either show barely noticeable light levels or stay off.
Next, let's take a look at the different voltages you got at the LEDs. Again take a look at the curve for the diode from the Wikipedia. The \$V_d\$ point for each diode made is different and there are some tolerances here. So some diodes of same model number will at same current have a bit larger voltage drop and others will have a bit smaller voltage drop.
Next about LEDs in series. There is nothing wrong with that, but you're still not doing it right. Using the formula I provided, you should set the resistor so that the LEDs will be within their rated current. If you fulfill that condition, there's absolutely nothing wrong with having multiple LEDs connected in series, should you have voltage to spare.
And we know, that when we connect both diodes to GND (logic 0) , the current flows from Vcc to the two diodes as both are forward biased , and there will be no current passing through the output terminal because all of the current is flown through the diodes for the greater potential difference.
You are already confused. Specifically, "there will be no current passing through the output" is not necessarily true. For this kind of logic gate, and indeed most kinds of logic gates, we define the truth values by voltages, not by currents. For example, what about this?
simulate this circuit – Schematic created using CircuitLab
Here, we have your AND gate. Both inputs are connected to ground (low, false). The output is false, which means a low voltage. But we've connected the output to a pullup resistor (R2), and there's current flowing through the output, via the path indicated by the arrows.
Think about why the output is a low voltage. With the diodes connected to ground, current can flow through R1 or R2. What happens to a resistor has a current through it? There's a voltage across it, by Ohm's law:
$$ V = I R $$
How much current will flow? Exactly enough to make the voltage across the resistor equal to V1, less the voltage drop of the diodes.
In fact it doesn't matter what you connect to the output: current will flow until that output is at a low voltage (ground plus the voltage drop of the diode). If that's not true, then current will flow until it is, or you blow a fuse. Hopefully you are designing to not blow a fuse.
If however, neither of the diodes are connected to ground, then there's no path from the output to ground. Current will instead flow through R1. For the logic gate to work correctly, this needs to make the output voltage high, but here's where we run into a limitation of this kind of logic. Consider:
simulate this circuit
With the inputs high, the diodes aren't pulling the output to near 0V. Instead, there's a path for current shown by the arrows. But what's the output voltage? R1 and R2 form a voltage divider. The current through R1 and R2 is equal, and they are of equal resistance, also. Thus we can infer from Ohm's law that the voltage across them is equal, and since they are connected across V1, the total voltage drop across them must be 5V. So, the output voltage is 2.5V.
That's not exactly what you want in a logic gate. Ideally, the output is 5V no matter what you put on the output. For this logic gate, that's only true if we leave the output open, or replace R2 with a much bigger resistor. This is a pretty limiting constraint, which is why this isn't a popular topology for a logic gate.
here comes my question. When both of the input diodes are connected to GND, there is a flow of current through the two diodes but why not through the LED?
Here's a simpler case to illustrate that problem:
simulate this circuit
If it's not clear from that, try building it with just an LED, then just an ordinary silicon diode like 1N4148. What's the voltage across the diodes in these cases? Why is that?
Best Answer
Ok, let's take this step-by-step up Wittgenstein's ladder.
Step 1:
Given the circuit:
simulate this circuit – Schematic created using CircuitLab
For the current to get from point A to point B it's going to go straight down the simple wire rather than take the more difficult route through the LED. So no current flows through the LED, it just goes straight past.
Step 2:
Ok, but on the circuit above point A and point B are connected directly together, so they are in effect the same point. The circuit is basically the same as:
simulate this circuit
(imagine the little link bit isn't there - the editor won't let you do diagonal lines).
The current I that flows in must equal the current I that flows out of point A. So if all that's going in is going straight out, there's none left to go up to the LED.
Step 3:
No wire has absolute zero resistance. The same with breadboards. So the actual circuit is more like this:
simulate this circuit
Ok, so we have an fixed voltage \$V_{CC}\$. Let's say this is, for simplicity. 5V. The LED has a fixed forward voltage drop. Let's assume for the sake of argument that it's 2V.
Ok. Let's take the LED out of the circuit initially and just work out the voltages dropped across the resistors R1, R4 and R5.
The total resistance for that section will be 100.002Ω (simply add them together). So the current through them would be \$\frac{5}{100.002} = 49.999mA\$.
Therefore the voltage dropped across R4 would be \$0.049999 \times 0.001 = 49.999{\mu}V\$.
Now if you attach the LED across that resistor it's only going to be getting 49.999µV, which is considerably less than the required forward voltage needed to turn it on. So it won't be conducting as it's not on, so the current through the resistors R2 and R3 will be zero.
Now there are more potential steps in Wittgenstein's ladder, but from here we're getting into the realms of subatomic physics, and even quantum theory, so we'll leave it there for now.