From: jl@glen--canyon.com   
      
   On Fri, 13 Feb 2026 13:00:55 -0500, bitrex wrote:   
      
   >On 2/13/2026 11:34 AM, john larkin wrote:   
   >> On Fri, 13 Feb 2026 06:40:05 -0900, Christopher Howard   
   >> wrote:   
   >>   
   >>> piglet writes:   
   >>>   
   >>>> If high precision is not needed and only LF response is enough then I   
   >>>> have used PWM techniques:   
   >>>>   
   >>>> Circuit A is the basic squaring concept, relies on modern open-drain   
   >>>> output comparators being pretty good switches to ground. Assumes you   
   >>>> already have a source of sawtooth or triangle waves with defined zero   
   >>>> and peak values in the system.   
   >>>>   
   >>>   
   >>> Could you please explain better how the PWM squarer circuit works? It   
   >>> look like it would be easy to build, but I don't grasp what is going on.   
   >>   
   >> A fairly simple single-opamp or comparator circuit can convert input V   
   >> to a duty cycle n. A transistor or analog switch or even a diode can   
   >> multiply V * n. Lowpass filter that and you have V^2.   
   >>   
   >>   
   >> John Larkin   
   >> Highland Tech Glen Canyon Design Center   
   >> Lunatic Fringe Electronics   
   >   
   >It has the advantage that the analog switch and passive low pass filter   
   >don't affect the DC performance, so long as you can afford the settling   
   >time of the filter.   
   >   
   >The hassle of trying to kludge cheap parts into decent multipliers,   
   >particularly ones with decent DC performance, and keep the signal path   
   >totally analog is that every cheap op amp and resistor you add to try to   
   >correct for the deficiency of all the other cheap parts tends to add   
   >noise and offset and soon enough you lose more than you gain.   
      
   The PWM thing I suggested should be pretty good. But we don't have   
   firm requirements for range, accuracy, or speed.   
      
   Cheap opamps can have sub-millivolt offsets, and 1% resistors cost   
   less than a penny nowadays. We don't even buy 5% resistors.   
      
   My PWM circuit doesn't much care about resistor tolerances.   
      
      
   John Larkin   
   Highland Tech Glen Canyon Design Center   
   Lunatic Fringe Electronics   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   
|