title: Inter Thread Communication in C
body: <p>As a part of my project I have to modify a Numerical Integration Algorithm using threads. </p>
  
  <p>This is roughly what happens in the conventional sequential approach..</p>
  
  <pre><code>void Controller(struct DE)
  {
      //initialization step
      for(;;)   //till the entire range has not been covered...
      {
           //compute the next time-point solution using the previously known solutions.
           NIiter();
           //then check if the result is acceptable or not and take the necessary steps...
      }
  }
  </code></pre>
  
  <p>Now this is what I intend to do....</p>
  
  <pre><code>void Controller(struct DE)
  {
      //initialization step
      for(;;)   //till the entire range has been covered...
      {
           //compute the next time using the previously known solution.
           NIiter();
           //when I have an approximate solution available..launch a thread to compute the next time-point using this approximate solution as a previous solution...something like forward pipelining...
           //then check if BOTH the results are acceptable or not and take the necessary steps...
      }
  }
  </code></pre>
  
  <p>But I dont understand how to notify my controller that the an approximate solution is available...so it can launch a new thread...</p>
  
  <p>This is my first exposure to multi-threaded programming...so forgive me if this seems to be an obvious question..also I am using Pthread library in my project...</p>