| bio | website | |
|---|---|---|
| location | ||
| age | ||
| visits | member for | 8 months |
| seen | 9 hours ago | |
| stats | profile views | 46 |
|
9h |
comment |
How can I convert a plot to pdf or eps without errors? On Linux v9, Export["p.pdf",%] works for the simple $x^2$ and $x^5$ graphic. Left-clicking the graphic, then right-clicking Save Graphic As... also works. Clicking the cell bracket of the graphic, then clicking File > Save Selection As fails, producing a blank white *.pdf file. |
|
May 7 |
comment |
Implementing the Farey sequence efficiently @Michael E2: Brilliant. Your recommendations bring the timings down to 2/3 of previous values, much closer to those of farey2[n]. |
|
May 7 |
comment |
Implementing the Farey sequence efficiently Thank you @J.M. for these performance tips. I would also be interested to know your experience with GCD versus CoprimeQ in farey2[n]. I've found GCD faster in some cases... |
|
May 7 |
answered | Implementing the Farey sequence efficiently |
|
Apr 28 |
comment |
How do I get Mathematica to show a number in non-exponential form?AccountingForm[-15252264.7448716`15, NumberSigns -> {"-", ""}] ? |
|
Apr 26 |
comment |
Error messages when using NInverseFourierTransform @Hannah: Uq2 is basically ArcTan[some function of t] where t ranges from $-\infty$ to $\infty$. The integral inherent in the Fourier transform is difficult to evaluate because such a Uq2 is virtually constant at -1 or +1. The resulting delicate balance between two infinite areas, one positive and one negative, requires integration skills beyond mine, and it seems you must have this knowledge to guide Mathematica to the correct solution. |
|
Apr 26 |
comment |
Error messages when using NInverseFourierTransform @Hannah: Again, NInverseFourierTransform expects its first input argument, in your case Uq2, to be a function of its second input argument, in your case
the dummy variable t which has no value. Your comment above first confirms t
isn't a list of values, but then contradicts that statement by saying t should
be a 2D array of values. |
|
Apr 24 |
answered | Error messages when using NInverseFourierTransform |
|
Apr 21 |
answered | How to find an asymptote of a logarithmic curve |
|
Apr 15 |
comment |
substitution rules for Penrose tiles Please see Mathematica in Action by Stan Wagon. Chapter 9 of the second edition discusses Penrose tiles. It is available via Google Books. Try Googling: "TriangleDissection" "KitesAndDarts". |
|
Apr 9 |
answered | Discrete FFT of non-periodic signal excited by short pulse |
|
Apr 8 |
comment |
Efficiently filling area with disks located at certain points The answer from @Michael E2 based on Nearest is far better than mine. I found that with only 3 nearest neighbours the solutions are similar to the OP's. However, the number of constraints using Nearest is linear in the number of points rather than quadratic. So the corresponding timings can still be long, but much much faster than the original findRadii. |
|
Mar 29 |
awarded | Revival |
|
Mar 25 |
answered | Building a continued fraction |
|
Mar 7 |
awarded | Commentator |
|
Mar 7 |
comment |
How can this DivisorSigma code be made fast? @Mr.Wizard Building on the fast solution by @kale, the following gives another 40% speed-up Total[ParallelCombine[Pick[#, Mod[DivisorSigma[2., #]^0.5, 1], 0.`] &,
Range[64*10^6-1]]] |
|
Feb 18 |
comment |
Testing for primality in quadratic rings? Thank you for this code. From V6 onwards you could use PowerModList[d,1/2,m]instead of your function roots[d,m]. The only difference occurs when the only solution is 0. Then PowerModList returns $\{0\}$, and roots returns $\{0,0\}$. |
|
Feb 16 |
comment |
Product of Fibonacci numbers using For/Do/While loops Being lazy and loop averse too, I would suggest Times @@ Round[GoldenRatio^Range[20]/Sqrt[5]] |
|
Feb 15 |
answered | How can this DivisorSigma code be made fast? |
|
Feb 8 |
answered | Creating a simulation of our Solar System |