@halirutan I really haven't tried. It wasn't working, and I just replaced it in the script. Then it started working again. Do you want me to try something?
I usually use that when there is more code after the output. When there isn't code following the output I'm using ">" like here mathematica.stackexchange.com/a/34601/193
@rm-rf @belisarius @m_goldberg @Calle The updated version is now ready. I tested it under Linux and OSX. For a list of changes please see the official post
Update:
23. October 2023
The dependent jquery.livequery.js is now loaded from googlecode
Introduced another button for the stripping of In[3]:= and Out[3]= marks. For this you have to select the complete codeblock where the I of In is the first letter in the selection. Pressing the button remo...
@YvesKlett when I was in Frankfurt at the European conference ... I am not in the US right now. But yes, we should all meet next year there and have a beer.
@m_goldberg I'll answer you here, since the comment-section is getting quite large
Currently, the In[]-Out[] replacement is really just a simple regular expression replacement. I wrote the most simple version which fits my needs.
If you want it more sophisticated, it would be nice if I have a version in Mathematica with StringReplace which does what you need and I see that I get it implemented in JavaScript.
@m_goldberg Sorry, It seems that when reviewing I no longer receive an error message if an edit/suggestion has been made. That's the second time this is happening to me.
@halirutan I was wondering is it possible to use the editor while reviewing new/late posts, cuz right now I can edit only when submitting an answer ?
@NikolaDimitrov I saw your edits. I didn't think they were helpful, so I restored mine. I think it was a situation where we both editing at the nearly the same time. This happens sometimes and causes a kind of race condition. In this case, you lost the race.
when using WhenEvent to assign the value of a parameter at a certain time point
how should I do it?
I was doing WhenEvent[t>=1800, p0->0] for a parameter p0 whose value should be 430 when t<1800, and 0 when t>=1800
but this then returns an error: NDSolve::wenset: Warning: the rule 430->0 will not directly set the state because the left-hand side is not a list of state variables. >>
presumably, that 430shows there because I'm using a replace to input it.
But no, this is just wrong. When you replace something, you might as well substitute it in yourself: NDSolve[{Ho'[t] == 430 - ke Ho[t], Ho[0] == 1 ... this is what you've written. You should add another equation to the system instead, po = 430. I haven't used NDSolve like ever but I think that's how it's supposed to be done.
@Calle well, even then it doesn't work. I tried adding po[t]==430 and it returns that function po comes with no arguments, or having po==430 and then it says that it's not an ODE
I would try to emulate the bouncing ball example in the documentation. Instead of >= 1800, I think you should add two WhenEvent's: one with > and one with < because that tells WhenEvent in which direction it goes (check Details and options). I need to go now, hopefully someone experienced will come along and help you :)
Does anyone know if it is guaranteed that vertexlist === VertexList@Graph[vertexlist, edgelist], i.e. Graph doesn't reorder vertices when invoked this way?
I guess only someone familiar with the internal implementation can answer ...
At least in v9 if you provide an explicit vertex list for Graph, it maintains that order of the vertices (unless you add/remove vertices or edges via e.g. VertexAdd or EdgeAdd). So your suggested method should work, with an extra caveat! A DAG might have multiple equivalent topological orders, wh...
This question is inspired by one of @whuber's answers
Consider the following code:
μ = RandomReal[{0, 1}, 100];
Σ = DiagonalMatrix[Exp[RandomReal[{0, 1}, 100]]];
AbsoluteTiming[
RandomVariate[MultinormalDistribution[μ, Σ], 400000];]
It runs in 3.5 seconds here.
Now let's parallelize it:
L...
And MemberQ would be an ideal candidate for optimizing on packaged arrays. It's immediately clear that a symbol is not a member of, say, an integer packed array, without having to look at individual elements.
@Rojo Why don't you complain to support a bit? The more people complain the more likely they'll fix it.
@rm-rf Is it possible to tell me why the flagging was declined when clearly all he needs to do is read the documentation? I am speaking about the incomplete Gamma function
@NikolaDimitrov I didn't decline your flag... moderators don't get "recommend closure" flags from users. I saw the question in the close review queue and voted to leave it open. That had the side effect of declining your flag (by the system)
@rm-rf Or put a full screen empty notebook on the back :P. Believe me, this is by request, I don't care at all about making it full screen, and I refuse to try hard
@Rojo Whenever someone requests something in Mathematica that I'm too lazy to implement, I just blame it on WRI and Mathematica's "lack of support" for that... It is EXTREMELY easy to sell that argument when the damned thing doesn't even have undo :P
I see a lot of people posting on Facebook about running, so if there was a way for me to expand the track and field data coverage in WA I would. That is why I keep getting forced to throw stuff on Wikicode.
Maybe some of the new Mathematica online and cloud stuff will make it so my friends that don't have Mathematica can use functionality I add on Wikicode.
No, but most people I talk to want to learn how to program. That could be a cool way to get them into it.
Like my dad just signed up for the free, online AI course from Stanford. He's probably going to end up doing it in Python. I can tell him I can do it faster in Mathematica, and then he says well you could probably do it faster in Python too because you have done more programming.