Re: [racket] Controlling the size of plot symbols

2014-04-16 Thread Daniel Prager
Back in the day (1992 - yikes!) I wrote programs that started with an icosahedron and recursively divided each triangular face into four subtriangles and so on to lay a close to regular mesh over a sphere to arbitrary resolution. [The I solved simple pdes using a finite element method, but I digres

Re: [racket] Controlling the size of plot symbols

2014-04-16 Thread Alexander D. Knauth
Maybe I should've included an example. If points->surface was a function that took a list of points and connected those points into a surface (like in my last email), then this code would draw a sphere at the origin with a radius of 1: (define (point-on-sphere ctr r theta phi) (let* ([z (* r

Re: [racket] Controlling the size of plot symbols

2014-04-16 Thread Alexander D. Knauth
Is there something that can take a list of points, (or maybe a list of lists of points) and connects those points into a surface, sort of like lines3d takes a list of points and connects them into a curve? And then define parametric-surface3d could be defined in terms of it, like parametric3d i

Re: [racket] Controlling the size of plot symbols

2014-04-12 Thread Jens Axel Søgaard
> It might be time to take another look at Jens Axel's ideas for adaptive > sampling, now that Plot can do it in 3D without b0rking it. In a nut shell: A plotting algorithm should sample the function the same way a numeric integration routine does. The number of samples in a given interval should

Re: [racket] Controlling the size of plot symbols

2014-04-11 Thread Neil Toronto
Plot doesn't have parametric 3D surfaces yet because they can contain arbitrarily large, arbitrarily close, or intersecting polygons. Plot's current 3D engine sorts polygons wrongly when they're not in a grid or are too close together, and it never draws intersecting polygons right. The upcomi

Re: [racket] Controlling the size of plot symbols

2014-04-11 Thread Alexander D. Knauth
Is there something for plotting 3D parametric surfaces? (where there are two parameters instead of one) If there is, then I would do something like this: (define (sphere3d ctr-x ctr-y ctr-z r #:color color) (parametric-surface3D (lambda (theta phi) ; theta and phi are the parameters

Re: [racket] Controlling the size of plot symbols

2014-04-11 Thread Neil Toronto
On 04/11/2014 02:04 AM, Konrad Hinsen wrote: Neil Toronto writes: > On git HEAD this takes about 15-20 seconds on my computer, depending on > random sphere placement and size. It takes 5-6 seconds for 81 samples > instead of 121. For comparison, the following takes 7-10 seconds with > 12

Re: [racket] Controlling the size of plot symbols

2014-04-11 Thread Konrad Hinsen
Neil Toronto writes: > On git HEAD this takes about 15-20 seconds on my computer, depending on > random sphere placement and size. It takes 5-6 seconds for 81 samples > instead of 121. For comparison, the following takes 7-10 seconds with > 121 samples and 3-4 seconds with 81 samples. Than

Re: [racket] Controlling the size of plot symbols

2014-04-10 Thread Neil Toronto
On 04/10/2014 08:16 PM, Konrad Hinsen wrote: Neil Toronto writes: > It's unfortunately not. But I think there's something you can do > instead: use `parametric-interval' to draw the circles instead. Thanks for the example, which contains some nice tricks I'll keep in mind for some other app

Re: [racket] Controlling the size of plot symbols

2014-04-10 Thread Konrad Hinsen
Neil Toronto writes: > It's unfortunately not. But I think there's something you can do > instead: use `parametric-interval' to draw the circles instead. Thanks for the example, which contains some nice tricks I'll keep in mind for some other application. But I don't see a way to use this for

Re: [racket] Controlling the size of plot symbols

2014-04-10 Thread Neil Toronto
On 04/10/2014 08:17 AM, Konrad Hinsen wrote: Hi everyone, I am trying to use (abuse?) Racket's 3D plots for molecular visualization. It actually works out better than I expected, except that I haven't yet figured out how to control the size of the plot symbols in the way I want. The documentat

[racket] Controlling the size of plot symbols

2014-04-10 Thread Konrad Hinsen
Hi everyone, I am trying to use (abuse?) Racket's 3D plots for molecular visualization. It actually works out better than I expected, except that I haven't yet figured out how to control the size of the plot symbols in the way I want. The documentation says no more than that the size of a symbol