21,701 reputation
13073
bio website
location
age
visits member for 2 years, 9 months
seen 22 mins ago

9m
comment Curve fitting of a list
Have you tried reference.wolfram.com/language/ref/Fit.html and reference.wolfram.com/language/ref/FindFit.html ?
Oct
26
comment Could I define 0^0 to be 1?
I used before Leonid solution f = Unevaluated[#1^#2] /. HoldPattern[0^0] :> 1 & how-to-tell-mathematica-to-replace-0-to-power-0-by-1
Oct
26
comment An efficient way to compare two matrices
can't you take just the norm of the difference of the 2 matrices? There are number of norms defined for matrices. reference.wolfram.com/language/ref/Norm.html may be pick the appropriate norm for your needs, as in Norm[mat1-mat2, "Frobenius"] ? This will work for sparse matrices as well.
Oct
26
comment How to build a constant Graphics object
If you can show the plot1, may be someone can suggest some things. For example, adding Opacity can slow down things quite a bit (since this requires more layers), I remember there was another graphic primitive that was expensive to use but forget it now. You can btw test this yourself. Make a manipulate that only displays plot1, like this Manipulate[x;plot1,{{x,0,"x="},0,1,.1}] and let it run (play the slider). You can now get an idea how long it takes to render plot1 on its own each time. You'll see that the less 3D points/primitive, the faster it will run.
Oct
26
comment How to build a constant Graphics object
since plot1 is constant already (it is evaluated before even Manipulate does anything), then M does not evaluate it again. What you are seeing in the rendering of it on the screen, which is slow for large objects, not the evaluation. You can try to Rasterize plot1 and see if this improves the rendering performance.
Oct
25
comment Distance Time Warp (DTW) function implementation in mathematica
There is some here forums.wolfram.com/mathgroup/archive/2003/Jul/msg00544.html
Oct
24
comment Number of sequences with a certain condition
the left term is no greater than 3 This is not clear and your example sheds little lite on what it means.
Oct
24
comment Manipulate Solve for initial condition
It makes big difference. look at this: Manipulate[x, {{x, 0, "x="}, 0, 1, .1}] which works, move the slider and it updates. Now move x outside, as in x = 1; y = x; Manipulate[y, {{x, 0, "x="}, 0, 1, .1}] now move the slider, and nothing happens. no update. The control variable has to appear inside the Manipulate expression to be tracked.
Oct
24
comment Manipulate Solve for initial condition
But this code is not in the Manipulate expression. You should put all control variables dependent code inside Manipulate.
Oct
24
comment Manipulate Solve for initial condition
I do not understand your code at all. You have 2 control variables r and b, yet they do not appear anywhere in the Manipulate expression. Before jumping to using Manipulate, you should first test your code as standalone, on a cell by its own, to make sure it even works. You can enter some values for the parameters. Then when it is working, you can use Manipulate to automate things.
Oct
24
comment Simplifying vector expressions
@TrumanEllis it looks you need another transformation rule. May be post separate question with an example to use for input to duplicate the output and may be someone can then help better.
Oct
24
comment ListPointPlot 3D without function
I do not know what you typed there. I see copy-right sign being used. Try this: ListPointPlot3D[data, PlotRange -> {0, All}, ColorFunction -> (Hue[#3, 1, 1] &)]
Oct
23
comment Problem with series expansion and integrate (Bug?)
@rhermans I only studies Series expansion for functions at school. Teacher never mentioned series expansion for integrals. So I do not know. You could be right. I'll ask the teacher tomorrow when I go to school.
Oct
23
comment Problem with series expansion and integrate (Bug?)
The integration does not even do anything. Why even worry about what Series does? What is Series supposed to be when given an un-evaluated integral anyway? Is this even defined somewhere? Series work on functions.
Oct
23
comment Calculate expected value of piece-wise pdf
Just use Plot. I just typed DiscretePlot cause I was looking at example. Once you have Distribution, you can use Mean on it. As in Mean[D0] gives 3/4 There is also expectation, reference.wolfram.com/language/ref/Expectation.html
Oct
23
comment Calculate expected value of piece-wise pdf
hum.. Should not your function be Piecewise[{{1, 0 < x < 1/2 || 1 < x < 3/2}, {0, True}}] ? Otherwise, looks ok. Try it, like this D0 = ProbabilityDistribution[Piecewise[{ {1, 0 < x < 1/2 || 1 < x < 3/2}, {0, True}}], {x, -Infinity, Infinity}]; then you can plot it. DiscretePlot[Evaluate[CDF[D0, x], {x, -10, 10}]], etc... see help for more information.
Oct
23
comment Calculate expected value of piece-wise pdf
This is a function definition. Not PDF. Check how to define own PDF here reference.wolfram.com/language/ref/ProbabilityDistribution.html
Oct
22
comment Strange integration
which version are you using? on V10.01, I do not get 1/2 (-HarmonicNumber[-I] - HarmonicNumber[I]), but only Recursion depth. btw, doing NIntegrate[...] works and gives -0.396291 + 1.65436*10^-24 I which is the correct numerical value that you show there. screen shot: !Mathematica graphics
Oct
22
comment Exclude Infinite Value in Table
It works if you add -1. DeleteCases[{1, {2, Infinity}, 3, {4, 1/0}}, Infinity | ComplexInfinity, -1] gives {1, {2}, 3, {4}}
Oct
22
comment How to rotate the Axislabel to parallel with the axis in BarChart3D?
please post a minimal not working example.