digital PID controller

Discussion in 'Homework Help' started by suzuki, Sep 20, 2011.

  1. suzuki

    Thread Starter Member

    Aug 10, 2011
    Last edited: Oct 7, 2011
  2. mik3

    Senior Member

    Feb 4, 2008
    I don't remember exactly but you might need to adjust the gain or wrap the frequency when using transformations like the bilinear. I have to revise my course!
  3. suzuki

    Thread Starter Member

    Aug 10, 2011

    thank you for the reply. i guess i'm unsure as to how i want to change my gain factors since it is already working in the s domain form, and i don't think i can do too much of a trial and error here since the simulation takes some time to run.

    What did you mean by wrapping the frequency? As far as i know, the bilinear transform lets you choose whatever sampling frequency you desire. In my case, I just chose the highest operating frequency in my circuit.

  4. suzuki

    Thread Starter Member

    Aug 10, 2011
    Still having some trouble figuring this out. I can get some results if i change the sampling frequency very low (1kHz) instead of using something high (150kHz), but this seems counter-intuitive since i would be sampling more at the higher rate.
  5. t_n_k

    AAC Fanatic!

    Mar 6, 2009
    It's hard to comment in an informed manner as you provide an incomplete picture of the problem. It might help if you provide a full description of the problem including the Plant (with some numbers) you are attempting to optimize with the PID block. Again, some numbers for your optimized 's' domain PID would probably be of help.
  6. steveb

    Senior Member

    Jul 3, 2008
    Oh boy - That's very likely a big part of the problem. There are two issues with this approach.

    First of all, the Nyquist sampling rate constraint is to sample at at least twice the maximum bandwidth you want. This is the a theoretical constraint, based on mathematics, that determines whether it is even possible to reconstruct a continuous time signal from the sampled system.

    Second, you typically need to sample at about 20 times the controller bandwidth in order for your discretized system to reasonably match the continuous time equivalent system.

    Also note that the use of a bilinear transform will "warp" the frequency domain characteristics. Adequate sampling rate will minimize the error in warping, but your pole and zero frequencies will not exactly match.

    There is the well known MPZ (matched pole zero) method of discretizing that gives exact match of zero and pole frequencies, but this is still not an exact representation, since exact matching is impossible.
    suzuki likes this.