I am folding the matrix in parallel and performing some function on the new matrix. I need to plot a graph and look at the execution time of a function with a different amount of thread.
my loop look that:
for (int i = 0; i < 8; i++)
{
Stopwatch sw = new Stopwatch();
var matrix3 = matrix1;
sw.Start();
LilMultithreading.SumAndOperationParallel(ref matrix1, matrix2, LilMultithreading.Operation, i + 1);
sw.Stop();
Console.WriteLine(sw.ElapsedMilliseconds);
// masLong[i] = sw.ElapsedMilliseconds;
// chart1.Series[0].Points.AddXY(i + 1, sw.ElapsedTicks);
sw.Reset();
}
I use for show graphics that code:
chart1.Series[0].Points.AddXY(i + 1, sw.ElapsedTicks);
but chart show me not true graphics(not true numbers)