41,661 reputation
562169
bio website
location
age
visits member for 2 years, 6 months
seen 1 hour ago

Aug
27
comment Find patterns in a list
@Mr.Wizard, ooh that's clever! I like it.
Aug
26
comment Unusual Slow Down with LocatorPane/DynamicModule
To be really helpful the code should be complete, ie someone should be able to copy and paste it into a Mathematica notebook and run it. This means including definitions for things like watershedMatrix - it doesn't have to be your actual data, some simple code to generate fake data will be just as good.
Aug
26
comment Rational display with Quantity
It looks like the formatting for reciprocal units comes from ToPerBox and ToSlashBox in CalculateScan`UnitScanner`Private.
Aug
26
comment Listlineplot starting from 0
Related, possibly duplicate?
Aug
25
comment Unusual Slow Down with LocatorPane/DynamicModule
Please focus on just one question, and try to strip your code down to a minimal example which demonstrates the problem and include the code.
Aug
25
comment Counting the zeros in a factorial expansion
This question appears to be off-topic because it is about programming in C++
Aug
21
comment Export Grayscale Bitmap
@AlexeyPopkov, yes that is my understanding.
Aug
20
comment Gradient Filter Function
You can view the definition of GradientFilter and the functions it depends on using Spelunk
Aug
19
comment Problem with hole filling using filledCurveToPolygons3D in MMA 10
The InPolygonQ function has moved in version 10 to Graphics`PolygonUtils`InPolygonQ. With that change it should work properly.
Aug
18
comment Simple string pattern crashes kernel
No problem with version 10 on Windows 7
Aug
17
comment How to modify the elements of a list in a loop?
I think the OP wants to apply each transformation in turn to each point, i.e. points.Transpose[t2.rx.t1]. It's hard to tell though, when the only thing we have to go on is some code which does something else entirely.
Aug
15
comment Determining the total illumination of a polygon
The rendering happens when the front end displays the graphics, so I don't think there is any way to obtain the illumination from the kernel. You could Rasterize the graphics and read a pixel value from the result but this will get tricky if there is more than one polygon.
Aug
15
comment Convert spectral distribution to RGB color
@MichaelE2, I enjoy a bit of spelunking, but it does frustrate me sometimes that gems like CIE color matching functions are built in but not made easily available.
Aug
15
comment Convert spectral distribution to RGB color
Nice! I wasn't too far wrong then, just got the normalisation wrong (as I suspected). It seems that the built-in "BlackBodySpectrum" is not quite right.
Aug
14
comment How to make a stereogram in Mathematica? (2)
In fact my original code was broken (though I'm not sure exactly what was wrong). The new version is similar in spirit to what you have here - copying pixels in a loop rather than attempting to do it all in one go with Part.
Aug
14
comment How to make a stereogram in Mathematica? (2)
The shift needs to be a relative shift between a part of the image and its corresponding part in the tile to the left. So each vertical strip forms the "baseline" image to which shifts are applied for the next strip. That's why the Accumulate was there. In your code here you are shifting each pixel relative to the background, so for every "hill" in the 3D profile you will get a matching "hole" one tile to the right.
Aug
14
comment How to make a stereogram in Mathematica?
Regarding the artifacts, I think I may have the algorithm slightly wrong, though I can't see where. When I get a chance I will try to fix it.
Aug
13
comment How to make a stereogram in Mathematica?
@Ajasja, the threading error is because Rasterize gives an RGB image and the depth map needs to be grayscale. You could use ColorConvert, or just create the values directly in a Table (I extract the ImageData in the next line anyway).
Aug
13
comment How to make a stereogram in Mathematica?
@user16069, it should be fairly easy to create a depth map from a 3D model. You just need to shade each vertex according to its distance from the viewpoint. If you need help with it I would suggest asking a new question.
Aug
13
comment How to plot data points in the form X, Y, E(X, Y) where X and Y coordinates are not ordered?
In version 10 you could also use Plot3D[f[x, y], {x, y} ∈ Rectangle @@ Transpose @ f["Domain"]]