3,983 reputation
1841
bio website
location China
age
visits member for 2 years, 2 months
seen yesterday

Feel free to correct the grammar mistakes in my posts.


Sep
19
comment How to understand the process of ListCorrelate when it in two-dimensional condition?
I just checked it, and found it confusing, if I understood the document well, the output should be True. Also, I think it'll be better to paste the part about the 4th argument here, or simply cut off the part below Generalizing beyond Times, Plus in your post, anyway, it's no longer related to your specific question.
Sep
19
comment How to understand the process of ListCorrelate when it in two-dimensional condition?
Er… Why the output of the 4th picture is False? And where's the introduction for the usage of the 4th argument?
Sep
18
comment Numerical Solving Problem, PDE
Are you sure the analytic result should be like that?: q[x_, t_] = q0*Cos[k*x]*Cos[Sqrt[k^2 + 1]*t + delta]; FullSimplify[Derivative[0, 2][q][x, t] == -Derivative[2, 0][q][x, t] - q[x, t]]
Sep
18
revised Inconsistent linearity of inverse Fourier transform
added 86 characters in body; edited tags
Sep
17
comment Inconsistent linearity of inverse Fourier transform
I think it's not, at least I can't find an exact duplicate. Here's just a possible related one: mathematica.stackexchange.com/q/34027/1871
Sep
17
comment Inconsistent linearity of inverse Fourier transform
I guess you are in v8? I can reproduce this in this version. v9 and v10 give the correct result.
Sep
17
comment How to overwrite a private symbol value temporarily?
@qazwsx You can type " \` " instead of " ` " to make it display correctly inside the code block :)
Sep
17
revised How to overwrite a private symbol value temporarily?
add another way to protect the symbol
Sep
17
comment How to overwrite a private symbol value temporarily?
@qazwsx I think there's no attribute named Unprotected, to clear the attribute Protected you can use Unprotect[Foo`Bar`Private`tmp] or ClearAttributes[Foo`Bar`Private`tmp, Protected] :)
Sep
16
answered How to overwrite a private symbol value temporarily?
Sep
16
comment How to overwrite a private symbol value temporarily?
What's the context of tmp? Suppose it's Global`, then how about tmp = 3; SetAttributes[tmp, Protected]; Get["mypackage.m"]? And tmp in a different context can be modified in a similar way.
Sep
16
comment Second order differential equation
BTW, as far as I can see, nonlinear boundary value ODEs has plagued this community for a long time. I just posted a question in scicomp.stackexchange, you can have a look.
Sep
16
comment Second order differential equation
Not easy, I should say. Here's an example. Depending on the nature of your equation, it's even impossible, I guess, because it's so sensible around w'[1]==0. Try this code: s = ParametricNDSolveValue[{w''[x] w'[x] + 3 w[x]^2 - 2 w[x] w'[x] == 0, w[1] == 0.8, w'[1] == a}, w, {x, 0, 1}, a]; Plot[s[a][0], {a, -1, 1}].
Sep
16
comment Second order differential equation
@AlbertRetey I think the v10 result isn't quite reliable. The same code can produce different result. For example, make the code fail by setting eps = 0.35 etc. and try eps = 0.75567 again, this time the code will fail. In some conditions I can even make it success but give different plots!
Sep
16
comment Second order differential equation
@Marco I think Albert is in v10. Just tested the code on the wolfram cloud and it does work.
Sep
15
comment Second order differential equation
Seems to be a task for shooting method, then you'll have a hard time looking for a proper initial guess…
Sep
4
comment How to speed up my Project Euler code
That seems to be the reason, BTW the $MaxMachineInteger in my v8 (Win 64 bit) is the same as that in 32 bit, not sure if it's just the nature of v8…
Sep
3
comment How to speed up my Project Euler code
Which version of Mathematica are you using? It's quite strange that your code generates the CompiledFunction::cfn warning in my v8 (Win 32bit & 64bit) and v9 (Win 32bit), but it does work without warning on Wolfram Cloud!
Sep
3
answered How to speed up my Project Euler code
Sep
2
comment Solving equations with QuantityVariable
@rhermans I myself avoid using the one-argument syntax of Solve for complex tasks, anyway it's undocumented. And according to my test, it's also slower if one doesn't specify the variable in Solve.