Hi, I would like to convert my for loop to STL std::for_each loop.
bool CMyclass::SomeMember()
{
int ii;
for(int i=0;i<iR20;i++)
{
ii=indexR[i];
ishell=static_cast<int>(R[ii]/xStep);
theta=atan2(data->pPOS[ii*3+1], data->pPOS[ii*3]);
al2[ishell] += massp*cos(fm*theta);
}
}
Actually I was planning to use parallel STL from g++4.4
g++ -D_GLIBCXX_PARALLEL -fopenmp
which is allow to run code in parallel without changes if the code is written in standard STL library.
Thanks in advanced Arman.