# Schmitt trigger with 741 op-amp not behaving as in simulation

I am implementing a Schmitt trigger using the circuit shown below. This circuit consists of one LM741 op-amp, which acts as an asymmetrical Schmitt trigger with a single power supply. According to this calculator, choosing a 5 V supply and 1 k-ohm resistors for R1, R2, and RFB should result in a lower threshold of 1.66 V and an upper threshold of 3.33 V.

I first simulated this Schmitt trigger in LTspice with an ideal op-amp (universal op-amp 2). A circuit diagram is shown below.

This resulted in the ideal behavior in which the output saturates to positive or negative rail (ground) when the input falls below the lower threshold or rises above the upper threshold, respectively:

I next replaced the ideal op-amp with an LM741 (what I am using in practice) and re-ran the simulation. I got the LTspice model for the 741 from TI's website. The circuit diagram is shown below:

Upon running the simulation, I find that the op-amp is not able to saturate all the way up to the positive rail or down to the negative rail:

I next built the device on a breadboard and measured the output voltage when input was either grounded (0 V) or tied to the +5 V supply. A figure showing my circuit is shown below. The green wire on the left is tied to ground, the green wire on the right is tied to +5 V, the red wire is the input, and the blue wire is the output.

When I measure the output voltage with an oscilloscope, I find that when the input is grounded, the output is +4.5 V and when the input is tied to +5 V, the output is 2 V.

Questions:

1. Where does the non-ideality in the 741 op amp come from? What causes both the second simulation and the real circuit to deviate from the ideal op-amp in the first simulation?
2. Is it possible to make the 741 behave more like an ideal op-amp? Or are there other op-amps I could consider using that have similar specifications for output current that behave more like the ideal op-amp (part numbers would be great)?
3. Why doesn't the simulated result for the 741 match the experimental result?

Edit: Upon seeing @Felthry's comment, I simulated the same circuit but with an LM358 instead of LM741 using the model found here. My circuit and result are shown below:

• 741 won't work with a 5v supply. You need an absolute minimum of 10v, 15v would be better. Use a low voltage rail 2 rail amp if you want to work at 5v. – Neil_UK Jul 15 '18 at 20:17
• To answer your second question, the best solution is to just get a modern op-amp instead of using a design from the sixties. Try the LM358. Questions 1 and 3 require more explanation than I have time for right now, sorry. – Hearth Jul 15 '18 at 20:17
• A search here on EE stack for 741 will answer your question. – Marla Jul 15 '18 at 20:25
• That ^^ and more precisely why you should not use a 741 opamp and especially expect it to work on 5 V. The 741 is designed (and used) in the days when having a +/- 12 V or +/- 15 V was the norm. Use an MCP601 or such which is designed to work on 5 V. I long for the days when beginners stop using the 741. – Bimpelrekkie Jul 15 '18 at 20:49
• I hope the 741 sticks around. It has pretty much every possible wart that an opamp might have. Absolutely nothing is ideal about the 741. How better to learn?? If you can make a 741 jump through hoops and get the job done, then you'll definitely be able to handle anything a modern opamp might throw at you. – jonk Jul 15 '18 at 21:34

The National (now TI) LM741 really is not well characterized to run off of a single $5\:\text{V}$ supply rail. The LM741 datasheet suggests that with your loading, you are guaranteed to get within about $3\:\text{V}$ of each rail. The typical is better; within about $1\:\text{V}$ of each rail. But that's not the guarantee over their range of operation. So, a good argument can be made that the LM741 cannot be assured to work on a $5\:\text{V}$ rail.

That said, it's likely that you can make it work here.

To do so, though, I need to consider a way to make sure that a small excursion of the LM741 opamp's output is sufficient to drive something all the way to the rails. You may be able to get the output near $1\:\text{V}$, but I'd rather be conservative and figure no better than $2\:\text{V}$ above ground. You may also be able to get the output near $4\:\text{V}$, but I'd rather be conservative and figure no better than $3\:\text{V}$ above ground. Keep it as conservative as possible and work from there.

(Since you don't have a mid-point voltage to use, I had to construct one using the $R_6$ and $R_7$ voltage divider.)