« first day (28 days earlier)      last day (4453 days later) » 
00:00 - 21:0021:00 - 00:00

12:11 AM
Congratulations everyone, 30 days beta! Enthusiast badges are shipping :-)
2
Oh, according to area 51 it's only been 28. Whatever, got my badge. ;-)
 
*confetti*
*high fives everybody*
@Szabolcs Yes, "Cartesian" and "hypercubic" grids both sound fine.
 
@JM:
Graphics@Table[{
RGBColor @@ RandomReal[{0, 1}, 3],
Translate[#, RandomVariate[NormalDistribution[], 2]] &@
Rotate[#, RandomReal[{0, 2 \[Pi]}]] &@
Scale[#, .1] &@
Rectangle[]
}, {1000}]
Should I post this as a question asking for improvement?
 
1:04 AM
@David it's 28 full days starting from launch, but we launched a couple of hours before the end of a StackExchange day (clicks over at 00:00 UTC), and we've just clicked over another one. So there will be more badges being handed out as people visit the site in this UTC day. So far there are 10 sad sacks (ahem) enthusiasts.
 
acl
@Verbeia Who's a sad sack!?!? :)
 
Hehe
 
1:42 AM
@Verbeia Waiting for mine as everyone else got in here a couple of hours before I did.
Anyway, congratulations everybody. We're still the fastest growing beta for same length of time.
Welcome, @IsaacMoses.
 
@rcollyer Thanks. I was just creepily popping in because someone said "Judaism" earlier, and it popped up in my search.
 
@IsaacMoses That was me.
I saw the weekly topic on Jewish Life and Learning was trees, and it amused me.
I thought, being a programming site, we could co-opt it.
 
@rcollyer Context-free, in the page of search results, I was wondering if that was in the Cannabis.SE chatroom.
 
@IsaacMoses Not nearly as interesting.
 
@rcollyer I've actually been trying to think of good Judaism questions that incorporate the concept of tree-structures, but have come up blank so far.
 
1:48 AM
Nice gravitar, by the way. How did you generate it?
Hi @Verbeia
 
@IsaacMoses anyway welcome! You have a very Mathematica-like gravatar :)
 
Do feel free to spin off from our challenge onto your site, if you like.
@rcollyer Thanks! It's from an M-Set generation program.
 
@IsaacMoses thought I recognized it.
 
OK, well thanks for the welcome. Gotta go.
 
Good luck.
@Verbeia lunchtime?
 
1:52 AM
I just checked we were hotter than sex, but we aren't hotter than beer. And yes @rcollyer it's lunchtime. Gotta get back to it soon, though. Wednesday is always full of meetings.
 
Don't see brewing on there.
 
15
Beer

Proposed Q&A site for beer writers, cicerones, and beer geeks

Currently in commitment.

There is also wine
55
Wine

Proposed Q&A site for wine enthusiasts, wine drinkers, wine makers, wine merchants, wine bloggers, wine buyers, wine writers, wine collectors, wine tasters, wine educators... in fact, anyone interested in wine

Currently in definition.

 
I saw Wine first.
 
I would have thought they could merge and been tags. (Along with whisky etc)
 
So, alcohol wins, but sex doesn't ...
Must be beer goggles that will sustain the species.
 
1:56 AM
Or they should have waited and launched Alcohol first
On that note, better get back to work :)
 
Followed shortly by frat parties.
@Verbeia Good night.
 
 
2 hours later…
CHM
3:32 AM
hi
 
@acl @OleksandrR thanks for the explanation :)
 
4:35 AM
hello @AndyRoss :)
 
@yoda hello
just popping into see what has been going on today :)
apparently its been a fairly slow one
 
yup, a slow day the 14th of Feb... wonder why :)
 
My wife and I like to pretend its just another day :)
 
I normally try to, but since I'm physically away right now, it really is :)
 
I hate it when that happens.
 
4:48 AM
cool :) time to remove the comment and the trail then :D
 
How does one delete said post?
@CHM hello
 
Comments? You just click the x next to it...
 
I tried that and it didn't seem to do anything
Oh, we aren't talking about the same thing. I thought you were referring to the chat.
 
oh, no.. chat messages can't be edited/deleted after 2mins (except by moderators)
 
Good to know for future reference.
 
4:52 AM
also, edit histories can be seen by everyone, and deleted chats can be read by moderators
good to remember that nothing is really deleted from anywhere on SE :)
 
Also good to know. I'm fairly new to the SE scene so its all still a bit of a mystery to me. I'm just shooting for that 2000 rep.
 
you'll soon see that when you get to 2k =) dead posts around... although, it's not as much as on SO...
ah, you're pretty close
 
Should get there tomorrow I'd guess unless I screw something up in my excitement :)
Thanks!
 
5:27 AM
nice talking to you too. take care @AndyRoss
 
CHM
Annoying error. There are lots of interesting texts in there.
 
@CHM Error establishing a database connection
 
CHM
@Rojo yes, sadly.
it worked 5 minutes ago.
 
Hehe, I'll check it out soon then. Never visited it
 
CHM
5:42 AM
:)
I'm off. Good night.
 
 
5 hours later…
10:37 AM
@David Why not?
 
10:50 AM
@JM This you understand this question right away? Am I a bit slow?
 
@Szabolcs have you had time to look at this yet?
 
I forgot about that answer. There should be a mark as unread feature. I'll take a look.
2
Does anyone know how to set the indent-width for auto-formatting in workbench?
 
Sorry, I don't use Workbench.
It's based on Eclipse, right?
 
Right.
Don't bother with trying to find out please ...
The formatting is not messy.
 
If you just voted for my answer you might want to wait on that until you test it; I never did. I expect it's full of holes, but I'll try to fix them as they are brought to light.
 
11:05 AM
@MrWizard What if for some reason the context is already not shown? This solution still tries to strip it from the symbol name. Admittedly it seems unlikely that this would happen.
 
@Szabolcs It wasn't clear until I saw the references in Juan's answer...
 
acl
11:41 AM
@Szabolcs it looks like you can't
 
12:37 PM
@Szabolcs Sounds like a good question/request for Meta.SO
 
@MrWizard You beat me to the rectangle question. I was typing up almost exactly the same answer when yours popped up.
 
@Heike which version?
 
@MrWizard The Graphics[] version
It took me a while to figure out what he really wanted (at least I think the second version is what he was after).
 
I often wonder if it is right to tell people to do it a different way, rather than answering their direct question. This time I decided to do both. By the way, since you've joined SE I don't get to answer many Graphics questions, and I get even fewer Accepts. Being first is about my only hope. :)
 
@MrWizard The graphics question are the ones I'm most confident about. I rarely get to answer the "How do I create this list more efficiently" ones.
@MrWizard I try to do both as well so the user gets to choose (and hopefully learn something).
 
12:51 PM
@Szabolcs It appears to have been asked for and declined, but I voted for it anyway
 
@MrWizard I'm here
 
@halirutan I wanted to ask about your highlight script. Is it possible to add fractional spaces to the styled code that will not interfere with copy&paste into Mathematica?
 
@MrWizard You mean, that it has the same line-breaks in Mathematica as it has here?
What are fractional spaces?
 
Sorry, let me explain what I am thinking and then you can tell me if there is a solution.
 
I think prettify will change the styling of code, but it will not change the code text.
 
1:01 PM
I am bothered by the appearance of the function application @ in the code blocks. In Mathematica the @ is round and has some space around it, making a line such as String@Of@Function@Names fairly readable. At least in my browser (Firefox 10) the StackExchange code block @ is narrow and has no space around it. It makes that kind of line very hard to read.
First I should ask others if they are seeing the same thing that I am and if it bothers them. (?)
 
I assume that if operators could be matched in their own category, it would be possible technically to change parameters such as kerning using CSS, or even add some more margin around the corresponding <span> (does it use <span>s)?
(without modifying the code text)
 
Ahh, ok. So what prettify does is only an annotation, which means, it give colors and styles to different parts. It does not modify the text
 
whether it's worth trying to do it is another question
 
We would have to make an exception for @ and try to implement this fractional space within the css if thats possible
 
Another option would be to get the round @ sign, if in fact others are seeing what I am. I see the same thing here in chat. String@Of@Function@Names is smashed together. String@Of@Function@Names has the round @ signs. Ideally I would like String @ Of @ Function @ Names but with less space.
How do those examples look to you both?
 
1:08 PM
@MrWizard Whether it's round or not depends on the font used. It will be different from system to system I guess. It looks quite different on the Mac screenshots than here.
As a workaround you can change the fixed width font of your browser to something that has rounder @ characters if you wish.
 
Isn't the font set by the site? I know I could force a different one, and I know if the font is missing a substitution will have to be made, but I still assume there is a "correct" font.
 
@MrWizard And you have of course the oportunity to try it!
 
@halirutan pardon, what?
 
@MrWizard Yes, it is set by the site. I just checked.
 
@MrWizard you can just hack the script. It's done in a few seconds.
 
1:11 PM
Here's proof that it's possible:
 
@MrWizard Download it from herer github.com/halirutan/Mathematica-Source-Highlighting/blob/… Go to line 84 where the styles of all operators are set an change the font or whatever you like.
 
You need to change the margins of the correct elements: w3schools.com/cssref/pr_margin-left.asp
It will be necessary to have a new category just for those operators that need extra margins and increase the left and right margin for that class
@halirutan @MrWizard I don't think this is a good idea though because there's a lot of value in having a fixed-width font and we would break that.
 
I would rather not change the font, just add some space. Also, I was thinking of this being a change in the default script. Do either of you feel the need for this?
 
@MrWizard I think this should not be in the default script because it conflicts with the fixed-width aspect of code blocks. We couldn't align code any more.
the front end does code alignment/indenting on its own, we can't do that here
 
(head slap) -- oh, now I understand what you're saying. yeah that would be annoying.
 
1:17 PM
I just wanted to show that it is possible when I pointed to left-margin and right-margin, but I didn't mean that it's preferable ;-)
OK, back to work for me!
 
I guess this was ill conceived. halirutan I am sorry for wasting your time.
I do have a question for my own personal use of the script.
 
Ideas are always good :-)
 
I disabled the italics because I get strange serifs with it on. I would like the italics to be simply slanted glyphs rather than quite different ones. Is there anything you know that controls this?
 
@MrWizard It's better someone really looks at it, even if suggestions cannot be implemented.
@MrWizard You have to post a screen-shot. I don't know whether my italics look right here, but I find it ok.
 
Let me see what I can do. I haven't monkeyed with HTML in about ten years; this could take a while.
Maybe it would be faster for you; can you give me a "bookmarklet" that will make selected text (or all page text for that matter) italic, in the same font it was before?
 
1:27 PM
Can you change a html-page dynamically in FF?
 
@Szabolcs I don't have workbench, but I use manual indenting inside Input cells and I use a tab width of 4 (default is 2). You can set it in Options Inspector > Formatting Options > Text layout options > Tab spacings. Perhaps there's something similar in workbench
 
@halirutan Probably, but I don't know how. More things I should learn I guess. (That's a long list.)
hello yoda
 
@MrWizard Then you could change a simple example from selfhtml here de.selfhtml.org/css/eigenschaften/anzeige/font.htm
 
I've got this, apparently:
/*
* This is a JavaScript Scratchpad.
*
* Enter some JavaScript, then Right Click or choose from the Execute Menu:
* 1. Run to evaluate the selected text,
* 2. Inspect to bring up an Object Inspector on the result, or,
* 3. Display to insert the result in a comment after the selection.
*/
Still looking for a way to edit page code and have it refresh...
 
Hmm, in Chrome you can just "Inspect Element" and can edit as you like. You see the changes instantly
 
1:32 PM
That's possible in newer version of Firefox as well.
In older versions you had to install Firebug for that (which is like Chrome's dev tools, and in fact precedes those)
 
Wanna see what I can do to our chat?
@Szabolcs Did you find your indenting stuff?
 
@halirutan I can inspect elements, but again I don't know how to change them.
 
I found how to set the tab size globally which also affects indenting with spaces
 
Anyway I need some food. I'll come back to this. Thank you.
 
@MrWizard Click the style button while inspecting and edit the style definitions :-)
@MrWizard Altenatively click HTML and edit something there. (I think you need to double click to edit)
Now I made all text here red, it's ugly :(
 
1:37 PM
@MrWizard hello Mr. Wiz :)
 
1:50 PM
This will make it clear why I want a smaller indent size than 4 in Workbench: this looks like typical Workbench-written code
 
106 answers in 1 month... that's more than 25% of your SO tally, which was over the course of an entire year (admittedly, with breaks). Sure you're not burnt out (or nearing), @MrWiz? :)
 
It's a very real risk ... I have 70 here and 143 on SO in total.
Quick question: how do I plot planar graphs in a way that shows that they're planar?
 
Yeah, I was worried about you too... you're equally active on meta too. 33 posts in one month... my tally on gardening is 45 after 7-8 months... (although, very different levels of activity)
@Szabolcs Do you have an example of something you're trying to plot?
 
Row[{Graph[{{1, 2}, {2, 3}, {3, 1}, {1, 4}, {3, 4}}],
  Graph[{{1, 2}, {2, 3}, {3, 1}, {1, 4}, {3, 4}, {2, 4}}]}]
The second graph is planar too, but it is shown with two edges crossing
I need to make it look like the first plot here:
It's the same graph, visualized slightly differently.
 
for the second one
oh wait..
 
2:04 PM
Here's a set of graphs to test on. All of these are planar, and therefore can be plotted without crossing edges:
<< ComputationalGeometry`
graphs = DeleteDuplicates[
  Flatten@Table[
    Graph@
     Union[Sort /@
       Join @@ (Thread /@
          DelaunayTriangulation@RandomReal[1, {j, 2}])],
    {10}, {j, 4, 10}
    ], IsomorphicGraphQ]
 
acl
@Szabolcs actually I use the workbench in large part because it does this. But it is annoying not to be able to control indentation settings as flexibly as in the mma frontend
 
Oh, I like what it does, I just want 2 spaces instead of 4. I got it now, by changing the tab size, and setting it to expand tabs.
 
acl
@yoda You can set these in stylesheets too, with the LineIndent option
 
@acl nice...should've done that instead of changing globally.
 
@Szabolcs: sure. copied from Eclipse with Workbench plugin. If I find time I upload it to github.com
 
2:10 PM
@Rolf Your post wasn't what triggered my question. I was trying to format some code to post here in Workbench, but the indent size makes it usually too wide . Otherwise I agree that Workbench is better than the front end's auto-indenting.
I'll post the planar graph question ...
 
@yoda Could be. I tend to do things all or nothing. One of these days I am going to return to Project Euler, which I haven't done much with since discovering StackOverflow. When I do you'll probably think I fell off a boat or something.
 
We've thought that a few times last year, but then notice your PE flair improving =)
 
@Rolf Do you have any interesting Mathematica code on github? If yes, could you post a link?
@halirutan is your point that this is difficult to do so Mathematica might not have the functionality? I'm not sure I want to sit down and implement it if it doesn't ...
 
@Szabolcs I'm afraid that this is not trivial, but this is only a guess.
 
2:16 PM
@Szabolcs no, not yet. I was playing with gitorious over the last days (need that for a project anyway). But probably for open-source Mathematica code I guess github is fine too.
 
@yoda The big gap last year was a PC rebuild and good weather at last.
 
@Rolf I don't know gitorious and I can't even use git (I use mercurial a little with bitbucket), but a huge advantage of github is that it has a built-in online editor. Anyone can easily contribute to the code without installing git and learning how to use it. I think that's very important as most Mathematica users might not even have used a version control system before.
 
@MrWizard it stopped raining, eh? :P
 
Summers here are usually really nice. Last year, not so much.
 
@Szabolcs I haven't been able to coerce PlanarGraphPlot to do it... are you aware of the function? Have you had success or does it not do what the name suggests it does?
 
2:28 PM
@yoda It needs explicit point coordinates as input and it just shows a Delaunay triangulation of the points. Yes, I found it (it was the first search result)
 
2:45 PM
Please see my comment here. Can you reproduce this weird behaviour?
 
@Szabolcs I can reproduce two printouts, seperated by an error. However, changing window focus doesn't change that. Same effect each time. 8.0.0.0on Win XP x64
 
3:11 PM
@Szabolcs that shouldn't give a message because the compiler knows that Print isn't compilable. No message and works correctly in 6.0.3 and 7.0.1 (don't have 5.2 installed on this computer but probably would work the same there too). Only 8.0.4 gives the message, though switching windows doesn't change that. Putting cf = Compile[{a}, Print[a], {{_Print, Null, 0}}]; cf[2] also doesn't improve the situation. I think this is a VM bug for Print.
 
3:28 PM
@Oleksandr I tried it on 8.0.4, and I just can't imagine why switching to another window would matter at all .... it's very unusual.
I suspect some Dynamic weirdness.
 
@OleksandrR @Szabolcs But if you have a more complex function it works without a message ;-)
@OleksandrR @Szabolcs let me repair your Mathematicas: cf = Compile[{{a, _Integer, 0}}, Print[1];]; cf[2]
 
@halirutan looks like 8.0.4 doesn't know what to do if the only thing in a compiled function is a MainEvaluate call.
 
Sorry, wrong example. this one: cf = Compile[{a}, Print[1];]; cf[2]
It's just the semicolon which is important
Very funny
 
@Szabolcs not that I am a git specialist. I just installed egit into a newer eclipse and then the Wolfram Workbench plugin. (I could not get egit installed into the original Wolfram Workbench Eclipse version)
 
3:37 PM
@halirutan it's even odder than that. Try cf = Compile[{a}, Print[a]]; cf[2], then cf1 = Compile[{a}, Print[a];]; cf[2]. The result (i.e. message or not) depends on the order you defined them. Then if you define cf2 = Compile[{a}, Print[a]]; cf[2], it sometimes works or not depening on which of cf or cf1 was last evaluated. Extremely strange bug.
(Yes, those should all be cf[2]. That is, the act of compiling cf1 and cf2 has a weird effect on the result of cf[2] even if you never evaluate them.)
 
@OleksandrR Ahh, I think I found the buggy part in the Kernel:
If[ EvenQ[IntegerPart[WeatherData["Champaign", "Temperature"]]],Message[CompiledFunction::cfex, 1]]
:-)
 
3:54 PM
@halirutan hahaha could be!
 
4:14 PM
@RolfMertig git does a line by line diff, so if you're considering using github, it might be better to upload the .m file instead of the notebook... Otherwise, it ends up trying to diff something like Notebook[{ Cell[BoxData[{ RowBox[{ RowBox[{ ... (which can change a whole lot even if the meaningful contents in the notebook haven't changed), and you won't be able to see differences between versions (and also cause several merge conflicts if you or others branch and merge two commits)
Or at the very least, disable file outline cache, which will prevent these unnecessary boxes from showing up. Also, see this question:
21
Q: Version control of Mathematica notebooks

EtaoinMathematica notebooks are, of course, plaintext files -- it seems reasonable to expect that they should play nice with a version-control system (git in my case, although I doubt the specific system matters). But the fact is that any .nb file is full of cache information, timestamps, and other as...

 
4:39 PM
@yoda But the code is in .m The notebook file is just a simple test.
 
4:53 PM
oh, alright then :)
 
5:51 PM
posted on February 15, 2012 by Abigail Nussey

The Wolfram Science Summer School (formerly the NKS Summer School) is now accepting applications for its 10th season, to be held June 25–July 13, 2012, at Curry College in Milton, Massachusetts, United States. We are looking for highly motivated individuals who want to get involved with original research at the frontiers of science. Our participants come [...]

 
CHM
Funny, I was looking at that yesterday, when it was still called the NKS Summer School.
 
The name change is obvious: it certainly isn't "new" anymore... :P
 
@RolfMertig @yoda Is there any reason not to just use the notebook diff from AuthorTools (or the version of it included and loaded by default in the NotebookTools` context)? Most Tortoise clients on Windows include a diff tool which uses this functionality.
@JM A rubber tire? Too rough and black for my taste. I liked the snake better.
 
@Szabolcs well, you were talking of sharing it on github right?
 
@yoda Do you work with signal processing? What is the simplest way to obtain a spectrogram-like thing with Mathematica? (I just need something that'll more or less reflect what I would hear with my ears, including frequency fluctuations)
 
5:59 PM
@Szabolcs Well, that's one interpretation... :) (I'm applying the technique I was talking about in my last blog entry.)
 
@yoda There are other reasons to use the m-file on github: the online editor that everyone can use to contribute. But if it weren't for that I think I'd prefer the notebook. I think it was @Rolf who wrote the notebook diff functionality, wasn't it? So he probably know how safe it is.
 
@Szabolcs That's just ListPlot[Abs[Fourier[stuff]]], no?
 
@JM well, that's not a spectrogram :)
A spectrogram is a 2D plot with frequency on one axis and time on the other
 
@JM I'd like something that shows changes in time Then I have this Heisenberg-uncertainty like tradeoff: if I cut it to small pieces I lose frequency resolution. If I cut it to large pieces, I lose time resoltuoin. That's how far my physicist training could take me.
 
@yoda Ah, yes. I haven't touched signal processing in months... :)
 
6:02 PM
@Szabolcs So, I haven't implemented one in Mathematica, but if it's not something you need right away, I can take a shot at it. Should be a fun thing to do :)
I can then check one thing off my list...
 
Weren't you planning to do QR codes at some point, also? ;)
 
hush you!
 
whoops...
*innocent gaze*
 
@Szabolcs Isn't that what Play more or less shows?
 
I can do the spectrogram (or atleast a rough cut version) a lot sooner than the QR code though... I'm still not sure if I was foolish for taking that on
 
6:10 PM
I was just counting how many times you've said "that should be fun to do" and variations thereof... ;)
 
that's how I got into grad school...
now I need to find something else that's "fun to do" to get out of it.
 
So I am not sure what's the best approach.
@yoda my internet is very flaky, keeps disconnecting ... sorry
 
Is there a 9.5pt option in latex?
do fractions of pt make sense?
 
@yoda 4 pages exact?!? What conference are you submitting to? OCD March Meeting?
 
@yoda Can't you fiddle with the margins?
or choose a different font
 
6:17 PM
@Heike need to use their stylesheet
 
@yoda What did your adviser say about this nonsense?
 
@EliLansey Coming to think of it, exact might not actually be enforced...
 
How much too long/short is the 10/9 pt?
 
@yoda fiddle with the quality of line breaking. Try the microtype package, it reduces the length in practice while improving text grayness
 
@JM he said throw away all the subsections and use 10pt :D
... not asking him.
 
6:20 PM
@yoda how many lines too long?
if it's only 5 or so, microtype might shorten it enough without any visible (to the eye) difference.
 
@Heike 10 is a little too much, 9 is too short (half-page remains), but I think Eli is right... exactness is probably not enforced (probably my own ocd).
 
@yoda regarding that spectrogram thing: I have a spectrum with lines (pretty periodic signal). What I'd like to check if some of the frequencies are fluctuating. So I need a short enough window to see the fluctuation (in case it's fast), but a long enough one to have sufficient frequency resolution to detect it
 
what's your sampling and bandwidth?
 
The only problem with microtype is that you must use PDF output and must use scalable fonts. CM-super are good fonts, so are LatinModern.
 
@Szabolcs So many "must"s... :D
 
6:25 PM
@yoda It's an approximately periodic signal, and one period has between 1000-2000 sample points
The whole signal is between 1*10^6 - 5*10^6 sample points long
@JM I like microtype ... open tex.ac.uk/CTAN/macros/latex/contrib/microtype/microtype.pdf , go to page 4, and try turning protrusion and expansion on or off (the buttons are in the margin). The interactive demo only works in Adobe Reader ...
 
I'll have to try that tomorrow. But for now, shut-eye. Later!
 
2:30 AM, you're a nightowl too
 
Clear[spectrogram, Hanning, Hamming, Rectangular]
Rectangular = (Function[{n, N}, 1]);
Hanning = (0.5 (1 - Cos[2 \[Pi] #1 / #2]) &);
Hamming = ((0.08 + 0.46 (1 - Cos[2 \[Pi] #1/#2])) &);
spectrogram[x_List, npts_Integer, rate_, lag_: 0, w_: Rectangular] :=

Block[{window = Array[w[#, npts] &, npts]},
Abs[Fourier[#*window, FourierParameters -> {1, -1}]][[
Range[1, Min[npts/2, rate/2]] ]] & /@
Partition[x, npts, npts - lag, {1, 1}, 0] // Transpose
]
@Szabolcs See above for a spectrogram code. It still needs to be visualized, but that's the calculation for it.
Generally, I've just used ListDensityPlot for visualization.
 
6:43 PM
@yoda Most conferences I've submitted to give a maximum page range, sometimes with a minimum lower bound, but how the hell can they expect you to get an exact amount?
 
or, even this from one of the sounds on the mac.
@yoda Already done. I wrote up a spectrogram for my grad lab class when the <censored> professor insisted on us using MatLab, and I wanted to show I could do everything he wanted in Mathematica, and get it done faster.
 
7:03 PM
@rcollyer Been there. I've already pissed off professors who prefer MATLAB, C, Fortran... Been told to code up some algorithm, solved it using built-in MMA function.
 
@EliLansey This was the same guy who insisted on teaching us what a file extension meant!
In this case, my lab partner and I weren't sure what the MatLab code was doing under the hood, so I looked up what a spectrogram was, and coded it up in MMA. Took me a half-hour tops.
 
Hmm, I haven't answered a single question today.
 
@Heike Don't be sad, I was too slow too.
 
@Heike sounds normal, for me.
 
Maybe I should think of an interesting question to ask instead
 
7:16 PM
That would work.
 
BTW, what happened to your avatar, @rcollyer?
 
It's now a black metal @rcollyer
 
Oh, wait, it's the spectrogram.
 
@Heike I used the spectrogram, above, for it. Unfortunately, it has a lot of fine detail that isn't showing up to well in the small form.
 
@rcollyer Yes, that's a pity.
 
7:19 PM
It's a really nice graphic, which I can't seem to reproduce as well as I'd like, and I've thought about changing it for a while now.
 
acl
7:43 PM
@yoda add a random displayed equation
 
7:55 PM
@rcollyer That's nice! Although, I probably would've used {1,-1} for the overhangs and would've added an nfft parameter. I'll still implement one of my own though soon (and I mean it!)... good practice for using options for something more serious than toy examples
@EliLansey Like I said, exact was my OCD... it used to be exact w/ 10 pt until the "suggested changes" from the man pushed it over which pissed me off :)
 
@yoda I wrote it five years ago, so no telling why I chose what I chose. I think I tried to match up to the matlab one as best I could, but no telling at this point. However, running it on v.8, I can't reproduce the second graphic! So, I need to play with it a bit more.
For the life of me, I can't remember why I added the rate parameter ...
 
Well, it does depend on the sampling rate or sampling frequency... so you probably added it for that.
 
never mind. It's to get the correct frequencies.
 
Here's a challenge: convert @rcollyer's gravatar back to sound and listen to it ;-)
4
 
:)
I like that idea.
 
@Szabolcs Better yet, do it with mma.
 
of course!
that applet can't even do it
I know next to nothing about how to do it, but already writing the code ;-) (no hints please!)
 
@Szabolcs How about I post it as a question?
 
I got my first ever bounty to "reward" my answer yesterday... pretty delighted
well, first that was not on MSO anyway...
 
well, it's always nice to have a little fun :-)
why not post it?
I would approve
 
8:15 PM
Give me a couple of minutes.
There's another question to answer.
 
@rcollyer just make it clear that this is a fun question and not a practical problem you have, to avoid downvotes for wasting people's time ...
 
Good point.
 
don't explicitly say it is fun...
just pose it as a serious problem.. even if you don't need the answer right away, it's worth answering
for example, you could phrase it as: I made this plot from a waveform recording 5 years ago, but I don't have the original wav file... is it possible to recover it (to some quality) from the image of the spectrogram
perhaps also a test example and spectrogram so that people can verify their results
 
@rcollyer what's the spectral range and sampling speed?
 
@EliLansey I don't know the spectral range, but 22050 for the sampling rate.
 
8:20 PM
@rcollyer Without the spectral range i'm pretty sure there's no way to reconstruct the sound
 
@rcollyer why half of audio? also Eli is right... we need to know the spectral range, and if you plotted in dB
 
@yoda It was a sound file I pulled off of my computer, so I don't know why it was sampled at the slower rate.
 
This must be the shortest answer that Leonid has ever given mathematica.stackexchange.com/a/1806/46
4
 
@Heike Ha! Alright, so who's up to write the parody "Leonid answer" to this question?
 
Here's the code I used to make the plot:
ListDensityPlot[newsp,
 Mesh -> False,
 ColorFunctionScaling -> False,
 ColorFunction -> ( clrfcn[Rescale[#, {mn, mx}]] &  ),
 PlotRange -> {All, {0, 4000}, All}]
clrfcn = Blend[{{0, Black}, {0.5, Red}, {0.7, Orange}, {0.9,
     Yellow}, {1, White}}, #] &
newsp = spectrogram2[snd[[1, 1, 1]], 1000, 50];
{mn, mx} = {Min[#], Max[#]} & @ newsp;
 
8:34 PM
@Heike lol... I'm even surprised he answered that! That's for low-hanging-fruit hunters like me
 
spectrogram2[x_List, npts_Integer, shift_: 1] :=

 Block[{mask = Array[If[1 <= # <= npts, 1, 0] &, Length[x]]},
  Table[
    Abs[
      Fourier[
       x*RotateRight[mask, i]]
      ][[ Range[1, Length[x]/2] ]], {i, 1, Length[x] - npts,
     shift} ] // Transpose
  ]
 
lol, sorry @rcollyer :)
 
it happens. (you can add the "be quiet" sound at the beginning, if you so wish)
 
wrong saga
 
I have to run, for now. But, I'll post the question when I can figure out the spectral range.
@yoda :)
 
8:48 PM
0
Q: Mathematica : duplicate edges

JuliaI am trying to generate a graph from an adjacency list, but Mathematica doesn't want to plot my graph because of multiple edges i think. This is my script : Needs["GraphUtilities`"] data = Import["adj_matrix.txt", "Table"]; data2 = Flatten[Table[{data[[i, 1]] \[UndirectedEdge] data[[i, 2]]}, {i...

Is this better here, or on SO, i.e. is it off-topic enough to get it moved here?
 
@rcollyer well flag it and ask for it to be migrated... if none of us answer there, mathematica questions wil eventually become off-topic there =)
 
@rcollyer Is this what it sounded like?
 
I mean, if we don't, then I see no difference from before where we had 3 sites to juggle and now 2
 
@EliLansey That sounds like my neighbour drilling holes in the wall.
 
@yoda but this site isn't listed as a better "it belongs here" option
 
8:52 PM
@EliLansey only the top 5 migration targets are listed... for everything else, a mod has to do it
 
@Heike yah, i agree. but it also sounds vaguely "computery"
you should hear what the Transpose sounds like...
 
@EliLansey It might be right. For all I know @rcollyer is a big trash metal fan.
 
00:00 - 21:0021:00 - 00:00

« first day (28 days earlier)      last day (4453 days later) »