Announcement

Collapse
No announcement yet.

MPP Sampling Integrator Simulation

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    Originally posted by waltr View Post
    There is NO "Gain" as a simple equation. This is an Integrator which changes the Cap through the input series resistor and the Cap is discharged through the feed-back resistor. The dominate components are the input series R and the feed-back Cap.

    Carl posted a explanation some years ago on how an integrator in PI circuits work. I can not find a copy but have the details.

    Assue:
    R1 = input series R
    R2 = Feed-back R
    C1 = feed-back C
    Vi = input Voltage
    t = sample time
    p = pulse period

    Then When sample switch is ON:
    R1 passes a current: i = Vi/R1
    This charges C1 as dv/dt = i/C1 (V/sec)

    When the sampling switch is OFF:
    C1 is discharged through R2. The discharge Tau = R2*C1
    The discharge time = pulse period - sample time
    The Vdrop per period = e^(-discharge time/discharge Tau)

    Also, the sampling Duty cycle = sample time/pulse period


    Now we calculate the integrator output Voltage per pulse period. We must do it this way since the Cap's discharge rate is dependent on Voltage stored.
    I used an integrator at work to get the integral of the input. Integrator TC=R in*C feedback. The output ramps a voltage equal to a step input in 1TC. R in=input resistor/% time on for a sampling integrator. Carl's gain formula calculates DC gain for the integrator or R feedback/R in. Including a simulation for a 1C integrator https://www.geotech1.com/forums/atta...962257(changed the input to a 1V step and stepped feedback resistor R3 1Meg and 1000 Meg, charted first amplifier output . 1V step input, 1Meg input resistance(10k/1% on time). 30n feedback capacitor. 30msec TC. Should ramp 1V in 30msec. With 1Meg feedback the output is the integral of the input for maybe the first 10msec? Any errors or additions?

    Carl's thread, https://www.geotech1.com/forums/show...686#post148686

    MPP integrator is next.
    Attached Files

    Comment


    • #17
      MPP integrator
      Used simulation https://www.geotech1.com/forums/atta...0&d=1574962451. Changed input to a -1V step. Stepped target sample times 30u and 60u, left simulation. Stepped R5 feedback resistor second amplifier 56k and 112k, sample time 30us, right simulation.

      Left simulation, sample time changed step response not gain.
      Right simulation, R5 changed gain and step response time. gain formula is (R3/R1)*((R5/(R4+R5))

      GEB works when the ground sample is gained to equal the target(ground, no target)sample and subtracted for a 1C or 2C integrator. Ground sample is gained by increasing ground sample time. Gain=Rfdbk/Rin*sample time*sample rate.

      Changing sample time doesn't change gain with a MPP integrator so I would be surprised if using a different target and ground sample time would ground balance. Maybe using the same sample times with a added gain amplifier for the ground signal would work?
      Attached Files

      Comment


      • #18
        I did go back and ran the integrator simulation in Excel and the 'finial' settled output value matches Carl's equation.

        As for trying to do GEB:
        The MPP is just a differential input integrator. To obtain GEB I think this can only be done with three or four samples like I do on my HH2.
        First sample is normal.
        Second sample is the opposite input and its time is varied with a pot and can be 1 to 8 times the first sample.
        The Third sample is done just before the next TX pulse and is same input as first sample with a time of GEB time - first sample time).

        Comment


        • #19
          Originally posted by waltr View Post
          I did go back and ran the integrator simulation in Excel and the 'finial' settled output value matches Carl's equation.

          As for trying to do GEB:
          The MPP is just a differential input integrator. To obtain GEB I think this can only be done with three or four samples like I do on my HH2.
          First sample is normal.
          Second sample is the opposite input and its time is varied with a pot and can be 1 to 8 times the first sample.
          The Third sample is done just before the next TX pulse and is same input as first sample with a time of GEB time - first sample time).
          The MPP is just a differential input integrator.
          Do you get gain to change with sample time with the MPP integrator?

          ]I did go back and ran the integrator simulation in Excel and the 'finial' settled output value matches Carl's equation
          Which simulation are you running?
          Last edited by green; 12-01-2019, 08:50 PM. Reason: added sentences

          Comment


          • #20
            Originally posted by green View Post
            The MPP is just a differential input integrator.
            Do you get gain to change with sample time with the MPP integrator?
            Yes. Longer sample or higher sampling Duty, increases the output Voltage thus gain

            Which simulation are you running?
            I am running a mathematical sample-by-sample calculation of C1's charge/discharge and output Voltage as I described in an above post using an MS Excel Spreadsheet.
            This agrees perfectly with LTSpice sims. I have done this to understand the math and exactly what whats from sample to sample.

            Comment


            • #21
              When looking to detect very weak signals that might be burried in noise, a Pulse Induction Metal Detector will offer some opportunities to use the lock-in amplifier theory because the sampling always occurs in the same place after the peak of the TX pulse and the RX signal is set in the delay time to receive. This sampling in the same place in each cycle is based on the theory of lock-in amplifiers. See this link: https://www.zhinst.com/applications/principles-of-lock-in-detection

              The amount of signals being integrated is based on:
              1. The size of the coil
              2. The TX pulse rate (PPS)
              3. The coil sweep speed and the amount of time the target signal is within the coil RX capability.

              Pulse induction metal detectors can utilize this lock-in amplifier theory by integrating many RX signals to detect target signals that would normally get lost in the noise.

              Joseph J. Rogowski

              Comment


              • #22
                Originally posted by waltr View Post
                Yes. Longer sample or higher sampling Duty, increases the output Voltage thus gain



                I am running a mathematical sample-by-sample calculation of C1's charge/discharge and output Voltage as I described in an above post using an MS Excel Spreadsheet.
                This agrees perfectly with LTSpice sims. I have done this to understand the math and exactly what whats from sample to sample.
                The MPP is just a differential input integrator.
                This agrees perfectly with LTSpice sims. Which LT Spice MPP simulation are you using? I don't see a gain change when changing sample time with the MPP simulation reply #17. Am I doing something wrong?

                Try Qiaozhi's simulation, first post. Edit simulation command(unclick start external DC voltages at zero and click skip initial operating point solution).
                Last edited by green; 12-02-2019, 04:20 AM. Reason: added sentence

                Comment


                • #23
                  The math I have done is with a simple integrator (as I stated) and is what Carl's gain equation is for.

                  I played with the MPP sim from Post #1 some more.

                  The gain of this circuit is NOT dependent on the sampling pulse times. This is due to the Feed-back going to the FET inputs instead of the FET outputs (op-amp inverting input).
                  It gets a bit complicated due to the two feed-backs. R3 feeds back an inverted signal whereas R6 feeds back a non-inverted signal.

                  This cancels the effect of sample pulse time.
                  Try setting the VIN to a DC level. VOUT will then be nearly zero and this is the purpose, to have a zero V output if No signal from the coil/pre-amp.
                  When the Voltage at VIN is different during Sample 1 verse sample 2 there is a non-zero signal at VOUT. The Voltage at VOUT is a ratio of the VIN Different from Sample 1 to sample 2.

                  The Gain of the Delta VIN seems to be 2.62. I came up with that by setting various delta VIN and taking the ratio of VOUT/ delta VIN. Examples:
                  VIN = 0 & -50mV, VOUT = 131mV, 131/50 = 2.62
                  VIN = -100mV & 100mV, VOUT = 525mV, 200/525 = 2.63.

                  Comment


                  • #24
                    Originally posted by waltr View Post
                    The math I have done is with a simple integrator (as I stated) and is what Carl's gain equation is for.

                    I played with the MPP sim from Post #1 some more.

                    The gain of this circuit is NOT dependent on the sampling pulse times. This is due to the Feed-back going to the FET inputs instead of the FET outputs (op-amp inverting input).
                    It gets a bit complicated due to the two feed-backs. R3 feeds back an inverted signal whereas R6 feeds back a non-inverted signal.

                    This cancels the effect of sample pulse time.
                    Try setting the VIN to a DC level. VOUT will then be nearly zero and this is the purpose, to have a zero V output if No signal from the coil/pre-amp.
                    When the Voltage at VIN is different during Sample 1 verse sample 2 there is a non-zero signal at VOUT. The Voltage at VOUT is a ratio of the VIN Different from Sample 1 to sample 2.

                    The Gain of the Delta VIN seems to be 2.62. I came up with that by setting various delta VIN and taking the ratio of VOUT/ delta VIN. Examples:
                    VIN = 0 & -50mV, VOUT = 131mV, 131/50 = 2.62
                    VIN = -100mV & 100mV, VOUT = 525mV, 200/525 = 2.63.
                    Thanks, we agree, sample time doesn't effect gain with the MPP integrator. Your gain calculation matches the gain formula (Rfdbk/Rin)first stage*((Rfdbk/(Rfdbk+Rin))second stage. (6800/2200)*((56k/(56k+10k))=2.62

                    Comment


                    • #25
                      I have never done a hand analysis of this circuit, but I suspect that "gain" does indeed depend on sample widths. I'd guess that the feedback introduces a 'zero' at DC which effects a high-pass filter function, therefore it always appears to have the same response to a fixed input regardless of pulse widths. But dynamic signals may paint another story. If I had time I'd do the analysis because it looks like fun. But, alice, I don't have time.

                      Comment


                      • #26
                        Originally posted by Carl-NC View Post
                        I have never done a hand analysis of this circuit, but I suspect that "gain" does indeed depend on sample widths. I'd guess that the feedback introduces a 'zero' at DC which effects a high-pass filter function, therefore it always appears to have the same response to a fixed input regardless of pulse widths. But dynamic signals may paint another story. If I had time I'd do the analysis because it looks like fun. But, alice, I don't have time.
                        Would it cancel EF if the two responses aren't the same?

                        Comment


                        • #27
                          Originally posted by Carl-NC View Post
                          I have never done a hand analysis of this circuit, but I suspect that "gain" does indeed depend on sample widths. I'd guess that the feedback introduces a 'zero' at DC which effects a high-pass filter function, therefore it always appears to have the same response to a fixed input regardless of pulse widths. But dynamic signals may paint another story. If I had time I'd do the analysis because it looks like fun. But, alice, I don't have time.
                          The question reply #26 was the first question I thought of without trying to answer myself. If trying to do GB the sample times including the EF samples would be the same so it should cancel EF? Trying to understand "gain". Your gain formula for a normal(1C or 2C)doesn't include capacitance so I assume you are calculating DC(non motion)gain. I think they are low pass where gain decreases as frequency increases. Qiaozhi's sim reply #6 shows DC(non motion)gain doesn't change with sample width and step response is similar to a normal integrator. What do you mean by high pass filter function?

                          Comment


                          • #28
                            Originally posted by green View Post
                            Thanks, we agree, sample time doesn't effect gain with the MPP integrator. Your gain calculation matches the gain formula (Rfdbk/Rin)first stage*((Rfdbk/(Rfdbk+Rin))second stage. (6800/2200)*((56k/(56k+10k))=2.62
                            green - Since the GB sample needs to occur after the main sample, the GB signal needs to be amplified, so that the main and GB signals become equal in amplitude and thus cancel. You can either do this by adjusting the gain of the GB channel, as shown in Figure 12-19 of ITMD, or by adjusting the sample pulse width. I'm fairly certain that the second method will not work with the switching integrator used by the MPP. As far as I can determine, the "standard" integrator output voltage droops over time once the samples have been taken, whereas the MPP integrator does not. This appears to be because the feedback resistors are switched out of circuit, allowing the feedback capacitor to more effectively hold its charge.

                            Comment


                            • #29
                              Originally posted by Qiaozhi View Post
                              green - Since the GB sample needs to occur after the main sample, the GB signal needs to be amplified, so that the main and GB signals become equal in amplitude and thus cancel. You can either do this by adjusting the gain of the GB channel, as shown in Figure 12-19 of ITMD, or by adjusting the sample pulse width. I'm fairly certain that the second method will not work with the switching integrator used by the MPP. As far as I can determine, the "standard" integrator output voltage droops over time once the samples have been taken, whereas the MPP integrator does not. This appears to be because the feedback resistors are switched out of circuit, allowing the feedback capacitor to more effectively hold its charge.
                              Thanks for the reply.
                              For a long time I thought increasing sample time to GB wouldn't work with the MPP. Members were posting they had success and I convinced myself I was wrong. from reply#4.
                              I think I remember. (1)posts suggesting GB could be done by using different target and ground sample times with thr MPP. (2) me suggesting it wouldn't work. (3)no one agreeing or disagreeing with my replies. (4) convincing myself I was wrong. Looking at it again in this thresd and thinking I was rght the first time. Reading Carls post this morning and wondering if he is suggesting GB could be done with different sample times. I think MPP, 1C, and 2C integrators are low pass filters. Did a simulation test this morning, MPP vs 1C. Changed target TC, adjusted ground sample time for a hole at 16usTC with the 1C integrator and charted Vout with GB off, GB on with target TC=8, 16 and 32us. Both have a hole at 16us. Both have the same DC gain with GB off. 1C reads alot higher at 8 and 32us TC's. Charted lower left of left simulation picture.

                              I apologize for beating some threads to death. Just trying to learn, the Manta discussion, some say it will GB some say no. This thread some replies stated gain did change with sample time some it dldn't. I get confused.


                              Attached Files
                              Last edited by green; 12-03-2019, 07:36 PM. Reason: added sentence

                              Comment


                              • #30
                                Trying to understand some of the differences between a MPP and normal(1C or 2C)integrator. Charted some data. Target(5us TC)sampled decay starting at 5us increasing sample time in 5us steps. Not exactly what I was expecting, does the data make sense?
                                Gain doesn't increase with sample time so output signal decreases as sample time is increased with the MPP. With the normal integrator example, output didn't decrease with an increase in sample time because gain increases? Both integrators, final stabilized output=DC gain*average sample volts. (MPP)increasing sample time decreases decayed output signal but might decrease noise. (1C or 2C)increasing sample time doesn't decrease signal but probably increases noise.
                                Attached Files

                                Comment

                                Working...
                                X