User Portlet
Discussions |
---|
Look at the definition of `Derror`. It evaluates to: -2 LogisticSigmoid[a.w].1 (1 - LogisticSigmoid[LogisticSigmoid[a.w].q]) (t - LogisticSigmoid[LogisticSigmoid[a.w].q]) LogisticSigmoid[ LogisticSigmoid[a.w].q] ... |
Everything is an **expression** in *Mathematica*. If you imagine that you're using **commands**, you'll thoroughly misunderstand what's going on. In particular, the first argument of `Table` can be pretty much any expression at all. So, make it a... |
`Integrate` will apparently only enter the land of generalized functions (`DiracDelta` and relatives) if the integrand contains a generalized function. This heuristic can be annoying. |
The problem that this kludge appears to address is that parallel kernels inherit the working directory of the master kernel when launched, but do not track subsequent `SetDirectory` invocations. Of course, once you've gone parallel, mutating global... |
This is much easier to do if you build up the program functionally. You have a simple function at the core of the problem: it deserves its own name. newV[v_] := If[RandomReal[] |
andre at mathematica.stackexchange.com found the answer. CUDAFunctionLoad wraps the function in **extern "C" { }**. I needed to unwrap the include as follows: } #include extern \"C\" { (backslashes needed to quote the quotes... |
I'm working with integrals that yield pairs of terms of the form `ArcTan[x,y]-ArcTan[x,-y]` or equivalent expressions involving `Arg` or complex `Log`. For Mathematica's choice of the branch cut, this is equal to `2 ArcTan[x,y]`. However, it appears... |
How about Total[Clip[list, {0, Infinity}]] |
`Root` objects have a well-defined ordering (reals before complexes, smaller real parts before larger). However, radical expressions do not. So, if you want order, don't use radicals. |
You might want to look up the Heaviside step function. |