Reputation
Next privilege 10,000 Rep.
Access moderator tools
Badges
2 13 79
Newest
 Yearling
Impact
~67k people reached

Apr
14
comment Trying to model Heat flow trough different materials with NDsolve
BTW, let alone the vagueness of this question, how to Implement heat flux continuity condition is indeed a interesting question, I do find a solution for this, but not that general and I'm not satisfied. I'm hesitating whether I should post it as an answer or start a new question, which will of course state the problem in a clearer way.
Apr
14
comment Trying to model Heat flow trough different materials with NDsolve
Just a sidenote, I believe that OP and @Laurent and this OP did want to add a flux continuity condition, they just didn't understand what a flux continuity condition is very well. Flux continuity condition depends on heat conductivity coefficient (usually notated with $\lambda$) rather than thermal diffusivity (usually notated with $\alpha$, for OP's question, (1 + 4 UnitStep[5 - x])/5. plays the role of thermal diffusivity exactly. )
Apr
13
comment Assumptions with patterns
@Fabio Well, the above code has been tested in v9.0.1, vista 32bit. Have you tried it with a fresh kernel?
Apr
13
comment Simplify equations with pattern assumptions
It's a pity that psimp doesn't support Subscript or I could mark this question as a duplicate. Still +1.
Apr
13
comment Assumptions with patterns
Which version are you using? In v9.0.1, both of the assumptions failed. And in v8.0.4, the result is on the contrary!
Apr
11
comment How to make RegionPlot3D automatically choose PlotRange?
I've already upvoted it. BTW there is no definite relationship between upvotes and being answered.
Apr
11
comment How to make RegionPlot3D automatically choose PlotRange?
You're welcome, qsraaaa520.
Apr
11
comment How to make RegionPlot3D automatically choose PlotRange?
In v10.1 you can use the function MinMax :) BTW, I noticed something interesting. In v8.0.4 WolframAlpha["bat ineqalty", "Result"] only returns an inequality, not a pure function!
Apr
10
comment Fix my code to return a table of values
@Nasser Actually I just made a pact with the devil and got the ability to figure out the use of the code, at the cost of being unable to use Do in my answer :D
Apr
9
comment How can i subtract a surface from another
……我想我猜的没错吧?你的母语是汉语吧?你真的明白accept the answer和click the checkmark sign的意思吗?也就是说,至今为止你得到的答案没有一个让你满意的吗?
Apr
9
comment How can i subtract a surface from another
那啥,同学,我姑且确认一下,你知道上面那条Standard Welcome里的 accept the answer 指的是啥吗?
Apr
8
comment Compile, “global variables” and recursion
But this still calls MainEvaluate……
Apr
5
comment How to speed up auxilary DoolittleDecomposite function?
Well, I'm not that familiar with the internal mechanism, either, but the Compile`GetElement trick does work, at least on my machine.
Apr
4
comment How to speed up auxilary DoolittleDecomposite function?
For the reason why Compile`GetElement is fast, it's mentioned here that it turns off the bound check.
Apr
4
comment How to speed up auxilary DoolittleDecomposite function?
Maybe it's due to the compiler? I use TDM-GCC 4.8.1, with "CompileOptions"->"-Ofast", and this is my implementation: doolittleDecomposition2 = With[{g = Compile`GetElement}, Compile[{{a, _Real, 2}}, With[{n = Length[a]}, Module[{t = a}, Do[Do[Do[ t[[i, j]] -= g[t, i, k] g[t, k, j];, {k, 1, i - 1}];, {j, i, n}]; Do[Do[t[[j, i]] -= g[t, j, k] g[t, k, i];, {k, 1, i - 1}]; t[[j, i]] /= g[t, i, i];, {j, i + 1, n}];, {i, 1, n}]; t]], RuntimeOptions -> "Speed", CompilationTarget -> "C"]].
Apr
4
comment How to speed up auxilary DoolittleDecomposite function?
You can use Compile`GetElement to speed up doolittleDecomposition by a factor of 2. (See here for an example. )
Apr
3
comment Backslide of Limit
@MichaelE2 Yeah, I know, I just feel obligated to remind all the people who take part in the discussion for the correctness of v8 :)
Apr
3
comment Backslide of Limit
@MichaelE2 I added a step-by-step proof, have a look.
Apr
3
comment Backslide of Limit
I'm sorry but the answer given by v8 is undoubtedly correct. See my edit for the step-by step proof. @blochwave
Apr
3
comment Poisson PDE over a irregular region with FDM
@wlkyr It's just because I didn't use the original coordinate. Map it back if you like.