Carl Love

Carl Love

28035 Reputation

25 Badges

12 years, 318 days
Himself
Wayland, Massachusetts, United States
My name was formerly Carl Devore.

MaplePrimes Activity


These are replies submitted by Carl Love

@Adam Ledger Yes, I was going to suggest that, although I don't know the precise details.

@Samir Khan  In the workbook attached to the section about centrality measures of graphs, you've misused the attenuation factor (alpha), which is the second parameter of GraphTheory:-KatzCentrality. You've used alpha=0.1, but this factor (for the results to be meaningful) must be smaller than the reciprocal of the eigenvalue of the adjacency matrix (A) of largest magnitude. In this case, that means it should be smaller than about 1/41. The reason for this is that the Katz measure is based on a matrix infinite geometric series with ratio alpha*A. This series diverges if alpha is larger than as stated above. The reason that KatzCentraility doesn't catch this is because it sums the series with the familiar geometric series formula: ((I-alpha*A^+)^(-1) - I), but this summation formula isn't valid for alpha larger than as stated above.

Actually, the bar chart produced for the Katz Centrality has a severe discontinuity for some alpha in 1/589.9390449..1/589.9390448, and the results seem meaningless to me for larger alpha. Since the reciprocal of the maximum eigenvalue of the weight matrix (not the adjacency matrix A) is in this interval, it must be that KatzCentraility is using rather than A. (I'd like to see a reference that backs up the validity of this.) If it's correct to use W, then certainly it's utterly meaningless to use alpha > 1/589.... 

@TianyuCheng The arrows, just like the curves, are generated in cartesian coordiantes. The transformation into polar coordinates causes some distortion.

@Adam Ledger Get CygWin on your Windows computers. It's a free, downloadable Linux-like "shell" command-window environment with all the standard Linux commands and text-processing tools. 

@Kitonum The polynomial is degree 8 wrt each of x and (and biquartic in y, thus symbolically solvable, though I didn't make use of that). So, splitting wrt x or gives 8 functions of y or x, respectively. Conveniently it turns out that in each case 4 of these functions are real-valued. The below plots show these 8 real-valued branches color-coded, so you can see where each connected component of the original plot comes from.

restart:
p:= add(seq((lambda/3)^k/k!, k= 0..4) *~ [1$3, -1/2, 1]):
pxy:= evalc(abs(eval(p, lambda= x+I*y))^2-1):
(d1,d2):= degree(pxy, x), degree(pxy, y):
plot(
    [seq([RootOf(pxy, x, index= k), y, y= -12..12], k= 1..d1)],
    color= [seq(COLOR(HUE, .85*(k-1)/(d1-1)), k= 1..d1)],
    thickness= 3
);
plot(
    [seq([x, RootOf(pxy, y, index= k), x= -6..7], k= 1..d2)],
    color= [seq(COLOR(HUE, .85*(k-1)/(d2-1)), k= 1..d2)],
    thickness= 3
);

@BarKop I just fully updated my Answer below to include summarize and programmatic extraction of r-squared and adjusted r-squared from the solutionmodule. Also, I added several more formatting tricks ("bells & whistles") to the plot.

Although I have no issue with Acer's final results and plot---they are equivalent to mine---I think that the huge ratio of singular values (exacerbated by lowering the svdtolerance) leads to the hard-to-believe t-values and p-values shown in his summarize chart.

I redid the worksheet above using a more-intuitive method to compute the ellipse fit's residuals so that they'd be directly comparable to those for the circle fit.

@rameen hamood I just put a Reply and worksheet below my Answer. Try it. But I can't tell what, if anything at all, you did wrong. It looks right to me. My first guess is that something messes up when you take variable names from palettes instead of typing them.

@Carl Love I can't tell what, if anything, you did wrong. But try the following. It's essentially the same thing as your code, in plain text:

restart:
assume(c > 0);
f:= (8*sin(x)+11*cos(x))*exp((-5/2)*c*x);
ans1:= int(f, x= 0..infinity);
limit(c*ans1, c= infinity);
      22/5


 

restart:

assume(c > 0);

f:= (8*sin(x)+11*cos(x))*exp((-5/2)*c*x);

(8*sin(x)+11*cos(x))*exp(-(5/2)*c*x)

ans1:= int(f, x= 0..infinity);

2*(55*c+16)/(25*c^2+4)

limit(c*ans1, c= infinity);

22/5

 


 

Download Rameen.mw

@tomleslie I'm nearly certain that the OP is referring to a Maple internal format file generated by the save command. A user-specified file extension of ".m" causes it to be in internal format. Still, I believe that they are text files (although not human readable), so changing the file extension to .txt would probably work, as long as one remembers to change it back to .m after downloading it. Since unzipping a file automatically restores its original name and extension, I thought that that'd be the easiest option.

@Kitonum I fitted a circle to the roots in the upper right corner. Visually, it was a perfect fit. But, plotting the residuals (although small ~ 1e-3) showed a nearly perfect sinusoidal pattern of two periods. So I guessed that an ellipse would be a better fit. The ellipses' residuals are over 400 times smaller, but still have a nearly perfect sinusoidal pattern, this time with 3 periods.

Maple Worksheet - Error
Failed to load the worksheet /maplenet/convert/Ellipse.mw .

Download Ellipse.mw

 

The worksheet won't display inline for unknown reasons, but you should still be able to download it.

@abdgafartunde Out of curiosity: Are you investigating the most-efficient way to compute all 10002 terms of the sequence? Or, on the other hand, do you want the most-efficient way to compute just the last term? The latter can be done directly much more efficiently than by computing the whole sequence, and it can be done using only 27 characters of Maple code:

(<0,1;1,1>^10000 . <1,5>)[2]

The time for this single operation is too small to measure on my computer.

I just deleted a copy of this Question to which you'd made minor changes. You can/should/ought to/must edit this Question instead of posting a new one.

@Scot Gould I haven't worked on it since I tried your first suggestion, Feedly. Right now I'll try your second suggestion, EasyRSS.

@acer Can you tell to what extent, if any at all, the nondifferentiable endpoint of sqrt contributed to the original slowness?

First 214 215 216 217 218 219 220 Last Page 216 of 708