x[t_] = Sin[t] + Cos[t];
y[t_] = Sin[t] + Sin[2 t];
i =
NIntegrate[Sqrt[(x'[t])^2 + (y'[t])^2], {t, 0, 1},
AccuracyGoal -> 8, MaxPoints -> 10000, MaxRecursion -> 100];
XS =
Quiet[
Timing[
ParallelTable[
FindRoot[
NIntegrate[Sqrt[(x'[t])^2 + (y'[t])^2], {t, 0, X},
AccuracyGoal -> 8, MaxPoints -> 10000, MaxRecursion -> 100] == i/k,
{X, 0}],
{k, 100, 1, -1}]]]
Even though I put Quiet after ParallelTable, it doesn't supress kernel warnings, which are present in large amounts. If I replace ParallelTable with Table, the code works, though. How can I get the same behavior from ParallelTable?
NDSolve[]to evaluate your arclength function?NDSolveValue[{s'[t] == Sqrt[x'[t]^2 + y'[t]^2], s[0] == 0}, s, {t, 0, 1}]– J. M.'s missing motivation Mar 07 '18 at 12:06arclen = NDSolveValue[{s'[t] == Sqrt[x'[t]^2 + y'[t]^2], s[0] == 0}, s, {t, 0, 1}]; i = arclen[1]; Table[FindRoot[arclen[X] == i/k, {X, 0}], {k, 100, 1, -1}]. Have you seen this, BTW? – J. M.'s missing motivation Mar 07 '18 at 12:21