Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

PID algorithm for constant temperature controller.

  1. Jan 30, 2015 #1
    Hello.

    I`m looking for help to write the coorect PID algorithm for heating controller.

    For start in attachment I`m sending You the graph. If someone of You can help I could send some more informations.

    Best regards,
    Greg.
     

    Attached Files:

  2. jcsd
  3. Jan 31, 2015 #2
    Any idea?
     
  4. Jan 31, 2015 #3

    jim hardy

    User Avatar
    Science Advisor
    Gold Member
    2016 Award

    Just what do you mean by
    ?

    One PID algorithm is
    Controller output = proportional gain P X error + integral gain I X ∫(error) + derivative gain D X d(error)/dt
     
  5. Jan 31, 2015 #4

    Svein

    User Avatar
    Science Advisor

    The one thing you need to remember when trying to regulate a heating controller is the time lag through whatever you are trying to regulate. This lag can easily run into hours.
     
  6. Jan 31, 2015 #5

    jim hardy

    User Avatar
    Science Advisor
    Gold Member
    2016 Award

    Slope of temperature curve during that first on-cycle should give a clue about process thermal capacity, and maybe that time lag mentioned by svein..
     
  7. Jan 31, 2015 #6
    Thank You for the answer.

    I know the formula for PID. But If You have seen my first drawing You should see that We are regulating the time when the relay is ON. We all supposed to regulate the time when the relay is OFF. Is it possible to make it by one formula or I will have to make two formula with time: first when the relay is ON second when the relay is OFF and make a loop.

    Best regards,
    Greg
     

    Attached Files:

  8. Jan 31, 2015 #7

    jim hardy

    User Avatar
    Science Advisor
    Gold Member
    2016 Award

    I'm not sure i understand that statement.
    ONtime is (1-OFFtime).

    You're mixing linear control with" on-off control" here, sometimes that's called "Bang-Bang control"
    and the math of that is another world. I won't go there myself
    From a quick search:
    Here's a paper...
    http://dimacs.rutgers.edu/Workshops/AIMS/slides/SLafrica4.pdf

    and a couple references
    http://en.wikipedia.org/wiki/Bang–bang_control
    http://cds.linear.com/docs/en/datasheet/1041fa.pdf
    http://liberzon.csl.illinois.edu/teaching/cvoc/node86.html

    Your best bet is to keep your on-off intervals short compared to the process time constants and treat it as linear
    or insert a PWM at your controller output.
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook




Similar Discussions: PID algorithm for constant temperature controller.
  1. Pid current controller (Replies: 4)

  2. PID control (Replies: 6)

  3. PID controller - order (Replies: 5)

Loading...