title: Call a function inside an OpenMP for loop
body: <p>Just getting started with OpenMP. I was wondering if it's possible to run an OpenMP parallel for in a for loop that calls an external function, that in itself doesn't call any other function. I've put in some simplifed code to make my point:</p>
  
  <pre><code>#pragma omp parallel for
  for(span=0;span&lt;info.nospanelement;span++)
  {
      some_function(info,wakePtr[time][span],P,w_ind,1);
  
      //additions to be done each repeat
      w_wake[0] += w_ind[0];
      w_wake[1] += w_ind[1];
      w_wake[2] += w_ind[2];
  }
  </code></pre>
  
  <p>I know I need to add some more to the call, but can this openMp loop technically work?</p>