Skip to content

Instantly share code, notes, and snippets.

@Kaupenjoe
Created November 18, 2015 19:25
Show Gist options
  • Save Kaupenjoe/ae013d98a2e622f8c9f2 to your computer and use it in GitHub Desktop.
Save Kaupenjoe/ae013d98a2e622f8c9f2 to your computer and use it in GitHub Desktop.
std::vector<std::vector<double> > computeTrainingSin(unsigned int pA)
{
//Temp Vectors
std::vector<double> tempTrainingSinX (pA);
std::vector<double> tempTrainingSinT (pA);
std::vector<std::vector<double> > tempTrainingSin(2);
for (int i = 1; i < pA; ++i)
{
tempTrainingSinX[i] =
((((2.0 * i - 1.0) * M_PI) / pA) - M_PI + 0.01);
tempTrainingSinT[i] =
sin(tempTrainingSinX[i]/2.0);
cout << "TEST SINX " << i << ": " << tempTrainingSinX[i] << endl;
}
tempTrainingSin[0] = tempTrainingSinX;
tempTrainingSin[1] = tempTrainingSinT;
return tempTrainingSin;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment