( ** Go back to PARENTPAGE ../Script-twospheres-aspl.html)
( ** Go back to HOMESITE https://www.tcnd.com)
( ** Go back to SetSphere https://www.setsphere.com)

How to find the intersection of two spheres by using group intersection

In the following example we show how to get the point of intersections of two spheres.

ASPL 1> displayoff
turn display off

ASPL 2> print INTERSECTION OF TWO SPHERES EACH WITH 500 POINTS

ASPL 3> println

ASPL 4> gg2Spheres(N,500,glb1,G1,glb2,G2)
call the GG-function to get the intersection of two spheres with 500 point each, the GADg has two labels: G1 to label the 1st sphere, and G2 to label the 2nd sphere, the result is pushed on the answer stack

ASPL 5> displayon
turn display on

ASPL 6> c&
find the checksum intersection for the dataset on the top of the answer stack, this will print the points where both spheres intersect