# User Portlet

Discussions |
---|

Can anyone help me understand why the `Compile` fails here: f = Compile[{{\[Sigma]t, _Real, 1}, {s\[Rho], _Complex, 1}, {dt, _Real, 1}, {x, _Real}, {nnt, _Integer}}, Module[{kz = 1/2 x, \[Sigma] = \[Sigma]t, d = dt, i,... |

How can I cluster the list so that elements that are within specified distance or less from each other gather together in the sublist? Thanks. t = RandomInteger[1000, 50]; FindClusters[ t, DistanceFunction -> ManhattanDistance] ... |

How can I generate a very large (billions) list of sublists consisting of randomly permuted integers from 1 to N and then gather them in subsublists where all elements differ only by one unit? I have especially hard time with the last operation. I... |

I am a little confused with this two functions: `AppendTo` adds and resets the variable while `Reap` and `Sow` have the attribute `Hold` and do not return unless finished: t = Flatten[Reap[For[i = 1, i |

Do I understand correctly that `AccuracyGoal` option in `NonlinearModelFit` specifies the accuracy of the parameters that are sought by fitting? The problem is that when I monitor the steps it is obvious that it quickly reaches the `AccuracyGoal` but... |

I defined a function through a module and then tried to fit it to the data, but it gets stuck for hours, no response even when I leave only one parameter. I would appreciate help a lot! |

Why don't overscript and underscript work in sum as it is written in Documentation? \!\(\*OverscriptBox[ UnderscriptBox[\(\[Sum]\), \(i = 0\)], \(2\)]\)4^i |

Can I somehow specify that `G` is a vector in function definition so that it won't complain? c0[G_, \[Theta]0_, \[CapitalPhi]0_, Q_] := Normal@SeriesCoefficient[Sqrt[ G[[1]]^2 + G[[2]]^2 - 2 Q Sin[\[Theta]] (G[[1]]... |

How can I test whether the argument of the function is a vector with numbers as members? I know `f[x_?VectorQ]` but it won't test whether members are numbers, `VectorQ[list, NumericQ]` does, but how to put it into brackets? |

I wrote some long code, which basically is to calculate a function `int[vars]` with `Module` but NonlinearModelFit doesn't recognize it! It just takes it as a constant, which is wrong. Any ideas why this is happening? |