« first day (1038 days earlier)      last day (3452 days later) » 

3:18 AM
@RolfMertig The parallel kernel startup speed improvement is really great, one of the first things that caught my eye in v10. It's likely due to MathLink improvements.
But the parallel tools still have nasty bugs that haven't been fixed for years. Take a look at the very end of this post. 1. arrays get unpacked only temporarily when they're returned, and this can take more time than the whole calculation in some cases. It's been reported, debugged by users, yet no fix. 2. there are functions which just get slow when evaluated in parallel. Some you'd never expect, e.g. Rule (!).
Some are really common ones like InterpolatingFunction
When I parallelize something, why do I have to keep all these bugs in mind just to make sure it'll run fast enough in the end?
2
 
 
6 hours later…
9:03 AM
@RolfMertig I have been looking at more and especially less official forward-looking schedule statements of releases and maintenance releases lately. I sense that every one of them has slipped considerably from the "promised" schedule. I don't know if that's just "business as usual", but it's an indication of trouble in product processes. I've seen the same myself, and also I've seen these things can be fixed (with a cost somewhere else).
 
 
2 hours later…
10:49 AM
@Szabolcs @Szabolcs You always have to keep all the bugs in mind and either fix them wherever possible or work around them. That usually (not so easy in the FrontEnd with Dynamic and so on) works quite well in Mathematica.
@kirma The problem I have with this is that it is hard to plan anything related to upgrading involving PlayerPro. So I mostly work with Mathematica 9.
 
 
1 hour later…
12:14 PM
PopupMenu Details & Options:
> Appearance->{"Clicked"->app1,"Unclicked"->app2} allows different appearances to be specified for the clicked and unclicked states of the popup menu.

Does it work for anyone?
 
12:30 PM
@Kuba Please provide an MWE where you think it should work and I'll try it... f.e. what is a sensible app1? Changing the size etc. doesn't make sense.
 
12:48 PM
@Pickett not sure but I suppose this should work:
PopupMenu[x, Range@5,
Appearance -> {"Clicked" -> "Palette", "Unclicked" -> "Frameless"}]
but it is not. I'm not really surprised. Just want to be sure.
 
1:35 PM
@Kuba OK, yeah I tried a few other appearances and they didn't work either.
 
@Pickett Thanks :)
 
hi guys, trying to make Conjugate work on symbolic expressions, but it doesn't seem to take my assumptions into account: e.g. Assuming[Element[a|a2,Reals],Conjugate[a+I*a2]]
it still gives Conjugate[a]-I*Conjugate[a2], how can I make it just give a-I*a2?
 
@user929304 ComplexExpand@Conjugate[a + I*a2]
 
@Kuba thanks, it worked, but how come your suggestion even works without the assumption?
we don't need to say what's real and not real when using complexexpand?
 
1:51 PM
@user929304 Look at the documentation for ComplexExpand. I think there's way to do that.
 
@MichaelE2 indeed, it assumes all are real.
thanks for the help guys
 
@Kuba Hi, Kuba! Wrapping Dynamic@PopupMenu[...] gives a pink-box message. It wasn't much help, though.
@user929304 You're welcome.
 
@MichaelE2 Hello :) and thanks. So it seems it is quite old leftover.
 
2:06 PM
@Kuba can I ask one more thing?
given a 10 by 10 matrix, if one wants to diagonalize it symbolically, using Eigenvalues[...], is it normal that it s taking more than 5 minutes? (the elements are all linear comb of trigonometric functions)
 
@user929304 I can't help you. I did Eigenvalues twice :P
 
@Kuba k :D
I guess I ll give the parameters before asking it to find them. I don't know how though, e.g. if we want to evaluate a symbolic expression but first giving it the params it needs e.g. Solve[ax+bx²==0,x] when a=3 and b=5, how does it work? I've tried Solve[a*x+b*x^2==0,x] /. {a,b}->{2,3}, it ignores that last bit
@MichaelE2 do you know? :)
 
2:29 PM
@user929304 I've used Eigenvalues more than twice but not that much. 10 x 10 of trig. fns. probably will take a while and a lot of memory. One trouble is that Mathematica has to keep track of 10 roots of a characteristic polynomial whose coefficients are nonconstant functions. That sounds really hard. As the coefficients vary, some roots converge and become multiple roots and then split again, sometimes going from real to complex conjugates.
 
@MichaelE2 alrighty, thanks, really good to know
 
@user929304 If there are just a few trigonometric forms, it can help sometimes to convert them to polynomials. E.g., if only Sin[x], Cos[x], Sin[2x], Cos[2x], then the replacements {Sin[x] -> a, Cos[x] -> b, Sin[2x] -> c, Cos[2x] -> d} together with the assumptions {a^2 + b^2 == 1, c^2 + d^2 == 1} change the problem to a problem about polynomials, which are generally easier. Mathematica does some of this under the hood, but sometimes it pays to do it explicitly up front.
 
@MichaelE2 it has given me after 10 mins, an answer with a lot of Root[......] ,Root,...., how can I get rid of these? any idea how to simplify?
 
2:45 PM
@user929304 (1) Why get rid of them? They're a somewhat recent enhancement...
11
Q: How do I work with Root objects?

minthao_2011I want to solve the trigonometric equation : $$(3-\cos 4x )\cdot (\sin x - \cos x ) = 2.$$ I tried Solve[(3 - Cos[4*x])*(Sin[x] - Cos[x]) == 2, x] It returns the solutions in terms of Root objects yielding also this message : Solve::ifun: Inverse functions are being used by Solve, so some s...

 
@MichaelE2 thanks a lot, for the suggestions and link, gonna start reading through cheers
 
@user929304 ... (2) You can converted them to numeric approximations with N. I'm not sure that they can be simplified. They can be made more complex and traditional looking with ToRadicals sometimes. -- You're welcome. Cheers to you.
 
3:24 PM
guys I am still struggling to feed parameter-values to an expression, I've tried Solve[ax+bx^2==0,x] /. {a,b}->{2,3}, it ignores that last bit, same with /@
and if I do Evaluate[a*x+b*x^2] /@ {a,b}->{2,3} it first takes a=2 and evalutes then takes b=3 and evaluates, but how to take both a=2 and b=3 before eval?
 
3:50 PM
@user929304 Try With[{a=2,b=3},Solve[...]]
The correct syntax for your rule is {a->2,b->3}
 
@Pickett thanks gonna try your suggestion
@Pickett both suggestions work the first time, but if I change the numbers and shift+enter again it ignores the new values and keeps the old params vals
do I have to clear[] by hand everytime?
 
My code doesn't alter the state of Mathematica at all, it doesn't define any variables etc. It must be something else that you've done.
 
k, I'll look into it, thanks
kind of you
 
4:23 PM
There's a question asking if sparse arrays can be used in compiled code. Some naive tests show that they can't. But it's interesting to note that since v10 it is possible to use sparse arrays in LibraryLink code. So perhaps under some conditions it is possible to use them in compiled code as well?
@RolfMertig Or they could just be fixed after all these years ... easy parallelization is one of the great features of Mathematica on paper. In practice it's not so easy. (But it's still very useful, otherwise I wouldn't use it.)
 
I've started writing Mathematica functions in JavaScript. I'm not sure if I should merge them with underscore.js though. I started with a basic rescale().
function rescale(input, inRange, outRange) {
                if(input.constructor === Array) {
                    return input.map(function (x) {
                        return outRange[0]+(x-inRange[0])/(inRange[1]-inRange[0])*(outRange[1]-outRange[0]);
                    });
                } else {
                    return outRange[0]+(input-inRange[0])/(inRange[1]-inRange[0])*(outRange[1]-outRange[0]);
                }
            }
 
5:03 PM
@MichaelE2 sorry to bother again, the eigenvalues are all given with Root[..], (in the root argument there are trig functions of x,y,z) and I'd like to define a function that has for expression, one of the eigenvalue expressions. But because they're given in root it doesn't let me, it says Tag Root in Root .... is protectec. my attempt was test[{{x},{y},{z}}]:=Root[....], ToRadicals and N[] didn't help either. Any ideas?
 
(Just testing the SEUploader. It was time)
 
@user929304 This works for me: Clear[test]; test[x_, y_, z_] := Root[x #^2 + y # + z &, 1]; test[4, 4, 1]. Note the underscores after x, y, z in the LHS of the definition. You would need those. You can keep your list structure, if appropriate.
 
@MichaelE2 thanks, yes I have them too x_ ... just forgot to write them here. I think it's because I'm copy pasting the long expression of the eigenvalue, if I do the following it doesnt work: d=Eigenvalues[mat], test[{{x},{y},{z}}]:=d[[1]] doesn't affect the expression of d[[1]] to my function test, but if I copy paste the expression of d[[1]] in front of it as test[{{x},{y},{z}}]:=Root[....] then it works, but gives protection error. Is there a way to not have to copy paste expressions
 
For the life of me, I can't find what I'm doing wrong. Given a list `{Style[#], Style[#2, Background -> LightBlue], Style[#3, Background -> Lighter[Blue, 0.7]]}` and another `{2,1,3}`, I want to apply the first list to the second, such that the second is returned with the highlighting (lower numbers = lighter color).
I've been trying variations of `Thread`, `Apply`, and `Map`, but I can't get it straight and I can't find out why. Here's what I was now trying:
`Map[Apply[#] &,Thread[{{Style[#], Style[#, Background -> LightBlue],Style[#,Background -> Lighter[Blue, 0.7]]}[[Ordering[{2, 1, 3}]]
 
@user929304 Try = instead of :=. Then d[[1]] will be evaluate before the definition is stored.
 
5:18 PM
(also, sorry for the wrong formatting, for some reason the code is not being properly tagged)
 
@MichaelE2 same issue, doesn't allow because tag root in root is apparently protected. it's ok thanks for helping out anyway, I ll see what I can do to get rid of the roots, cheers
@MichaelE2 fixed it... sigh sorry... just had to use clear on the function before :(((((((((((((
 
@user929304 I was just about to suggest Clear. (It's why I put it in my last post.) Better luck in future! :)
 
@MichaelE2 :D it's good experience anyway, I learn
 
@user929304 The "tag protected" error is always about the LHS of a def.
 
aha! so nice to know these things, thanks
 
5:30 PM
You're welcome.
 
6:08 PM
@VitaliyKaurov Links still don't render properly in Chrome on W Community. This has been broken for many months now.
Is there a fix on the horizon?
 
 
1 hour later…
7:35 PM
posted on November 21, 2014 by Matthias Odisio

For most of us, taking bad pictures is incredibly easy. Band-Aid or remedy, digital post-processing can involve altering the photographed scene itself. Say you’re trekking through the mountains taking photos of the horizon, or you’re walking down the street and catch a beautiful perspective of the city, or it’s finally the right time to put [...]

 
7:57 PM
@WolframBlog This looks pretty cool.
 
Hm, is there something missing in the way I'm using Thread[]? I'm using it like from the documentation: Thread[f[{a, b, c}, {x, y, z}]]
 
@FdotFloss well, what do you get and how does it differ from what you expected?
@FdotFloss Did you end up posting your fitting question elsewhere? It was off topic here, but that doesn't mean that it was a bad question.
 
with my function: Thread[GetSomeRegion[expdat, expregionlist]], where both expdat and expregionlist are lists of the time of parameter GetSomeRegion[] takes
so to test, I tried GetSomeRegion[expdat[[1]],expregionlist[[1]]], which works fine
and several other values besides 1
@Szabolcs, nah, I had a look at the paper though
 
@FdotFloss The paper is actually about fitting distributions, not fitting arbitrary measurements. Power-law distributions are common in some areas, but if you're not dealing with distributions, that paper won't be useful.
 
@Sosi why can't you just put Background dependent of given value?
 
8:07 PM
hmmm
 
 
2 hours later…
9:45 PM
I'm wondering if anyone has any insight to rendering in `RegionPlot`? Consider the following: `RegionPlot[(x - 150)^2 + (y - 10)^2 <= 50, {x, 0, 300}, {y, 0, 20},
AspectRatio -> Automatic]` which renders badly; however changing the x range from {x,0,300} to {x,15,300} makes things better. I need the original plot range but can't figure out what options to pass to RegionPlot in order to get the correct rendering.
 
9:59 PM
@bobthechemist Increase the PlotPoints ?
 
@Sektor That's the ticket. Must be a Friday afternoon. Thanks.
 
@bobthechemist No probz :) What are you working on ?
 
I'm doing some image tracking of cells that are too densely packed, so I was thinking of using RegionPlot to make a mask for the images.
 
That's a good idea
Is it behaviour related or structural ?
I really don't know much about your research except outside of your website
I mean I've read it a couple o'times , but still :D
 
Right now the cells should be moving around a la brownian motion, but the long term is to study some type of chemotaxis.
Well this is new and improved stuff that hasn't made it to the website yet :)
 
10:05 PM
:D
Well, hmm
If I can make something re-usable I would do that even tho sometimes it is more work
If there's a chance you might need that whole masking/counting/detecting analysis
hell yeah do it
 
Yes, re-usable and usable-by-undergrads are the two criteria I'm looking for.
 
And I think you should always look for those options :D
 
true enough
 
But that's just me I love when everything is in order, and properly formatted :)
Well, it's past 12 in here
so I should go to bed :D
I hope the projects going well and I will keep an eye on the web site :D
 
Thanks - enjoy your evening
 
10:12 PM
Thank you :)
 

« first day (1038 days earlier)      last day (3452 days later) »