How to achieve a nurbs quadball in rhino?

Fun stuff. It sure beats working on STEP import.

ah… ok… the surface i was making is:

NURBS Surface
“U”: degree =3 CV count = 7 (0.000 <= U <= 12.087)
“V”: degree =3 CV count = 7 (0.000 <= V <= 12.087)

I remember I read of a paper about such an object years ago, it was a true sphere but IIRC the surfaces had degree 4.
I was not able to get the text because an ACM login was needed (or something like that)

Ok, I had to finish this. It’s the geek in me. I couldn’t get this using rhino commands. I had to write a test command and use our low level stuff.QuadSphere.3dm (91.9 KB) It’s not perfect because I used an overly computational method. I’ll figure out the exact solution some day. Mitch, yours is almost identical to this.

Chuck

1 Like

one way to get the height of that point (or to get the same surface) using only rhino is to use the setup arcs that mitch is using (the red ones in the first drawing i posted) then span a single arc across the midpoint… then use sweep2 - simple sweep…

hmm… actually, that :point_up: exposes a very slight error in simple sweep2…

the middle control point i get when doing it that way is at:
-2.33688e-14, 0, 2.37069

whereas the version you (chuck) posted is at
0, 0, 2.37069

so while the height is showing the same, my version has shifted ever so slightly on the X axis…

Looks like simple sweep uses the same low level code that I did, except it must do some other calculations to set things up. That’s where your numerical noise is coming from. Most likely from calculating the weights for the middle points on the sides. I already knew what they needed to be.

Chuck

[quote=“chuck, post:27, topic:5244, full:true”]… the weights for the middle points on the sides. I already knew what they needed to be.
[/quote]

not me… i still don’t.

i just know (some of) the geometric games which should arrive at the proper solutions then count on you guys to handle the geek stuff under_the_hood / out_of_sight :smile:

so just keep on doing whatever it is you all are doing :thumbsup:

I used EdgeSrf from the arcs, it preserves the control point structure and weights from the input curves. Unfortunately it doesn’t know what to do in the middle, so it makes a very flat curved surface - but all that needs adjusting at that point is the middle CV vertical location and weight (all the others are already set correctly).

I ended up doing that by eye to a reference arc in an orthographic view, the weight affects the flatness of the surface curve, so it’s adjust the weight, nudge the control point so the apex is correct, compare along the arc, adjust, nudge, compare, etc… in the end I think I reached the limits of the display accuracy.

I had tried simple sweep2 but it didn’t work originally (that was one of my first ideas) but now I tried it and it is working… :confused: It looks slightly better than my handmade one and a lot less effort…

–Mitch

Thanks for you guys answers. @chuck where can I learn the way you calculate the weight? very cool.

I’m a rhino enthusiast,here is my new post about a similar question. link

are you seeing the same tiny deviation of the center control point in the x or y axis? the version i did was off by -2.33688e-14mm …i didn’t think rhino could even deal with or display measurements that small.
?

Mine said “0” but my model was bigger than yours…
– or maybe my Rhino is better behaved… :smile:

Anyway, XXXXXe-14 IS zero for all intents and purposes, it’s just floating point “fuzz”…

–Mitch

There are some references here. http://www.rhino3d.com/resources/. The Nurbs Book might be a good place. I just used the fact that for a rational quadratic bezier arc with equal end weights w, the middle control point has weight w*cos(a/2), where a is the angle of the arc. For the side arcs, don’t try to find the angle, just use elementary geometry and trigonometry to find cos(a/2). Look at the inscribed cube, and lets assume the radius of the sphere is 1. In the file, you need adj/h. h=1.0 since it is the radius. The direction of h is (1,1,1), and has length 1, so the corner at the end of h is (1/sqrt3, 1/sqrt3, 1/sqrt3) and the end of adj must be (1/sqrt3, 0, 1/sqrt3) so its length is sqrt(2/3).

For the mid weight of the surface,I figured out what the weight would have to be to get the surface evaluation formula to give a 90 degree arc across the middle.

Chuck

I feel like I’m missing something. Please tell me if my solution is too simple for
the result you are trying to achieve.

I started with a sphere. Extracted isocurves on the diameter. Rotated and copied
@ 45 and 90 degrees until I had the rough quad ball layout on the sphere. Then trimmed
all the intersecting lines that weren’t necessary. Then used the resulting lines to split the sphere.

I ran the zebra on it and it looks very good.

Again, Please tell me if I missed something. All the offered solutions seem

complicated.

you’re making a complicated surface though (look at the properties)… the challenge (or whatever) is to make it:

each surface will be 2 degree 3 CV count in both U and V direction (a 2 degree bezier surface)

ie- the simplest nurbs surface… and not a trimmed surface etc.

but if the idea was to just draw a sphere then divide it up, i think there might be an even easier way to do it than how you’ve shown.

I knew I had missed something! Thanks!
Sooo…what is the purpose of creating a simple nurb surface in this situation?
Just curious now that I’ve stuck my nose in it.

To be able to get a better quality surface?

Did a little more digging. Got it. I’m fairly new to Rhino and have found high quality surface
modeling to be, at best, challenging!

Question: Now that the curves are built, is it possible to rebuild them as degree 3 and use them to
achieve the desired result? I’m guessing that would throw off the geometry.

well, it appears the best way to do this accurately would be with a revolved surface (the sphere)… your version is, i assume, the most accurate of all the solutions posted here…
the first version i posted was really close to being a true sphere but even it showed some variance in radius… and that surface didn’t meet the qualifications of the challenge as it was too ‘heavy’.

i think the OP was more just wondering if it was possible to create the quadball with a rational nurbs surface and the conclusion (or my conclusion at least) is no, it’s not possible to do it accurately… at least not if you’re trying to make a sphere out of 6 of them… maybe if you did one which was divided into thousands of sections- then it would be possible or at least unnoticeable in it’s inaccuracies.

fwiw, the control points should look like this if the surface meets the qualifications of the challenge… notice each arc on the side has its ends pinned with a point then a single point in the middle which pulls the curve into an arc (those are true arcs… you don’t need more points than that to make true radii)… then the surface itself has one single point in the middle which pulls up in order to form the dome…

and under those conditions, it’s been shown (again, to me at least) that you can’t make a true spherical shape using the least possible amount of control points required for a surface shaped like this… you need more points in there to really get it round.

I found two papers with the exact solution for the quadball. However, when I duplicate the supplied coordinates and weights to a single span 5x5 point NURBS surface, the geometry doesn’t match a perfect sphere. I’m at a loss on how to obtain the correct values and weights of the internal control points.

The attached file contains 6 patches with the coordinates and weights copied from the two papers.

QuadballSphere.3dm (210.7 KB)

1 Like