ASKSAGE: Sage Q&A Forum - Latest question feedhttp://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Mon, 23 May 2016 00:23:52 -0500Plot intersections of two relationshttp://ask.sagemath.org/question/33521/plot-intersections-of-two-relations/ How can I plot an intersection of two relations? For instance, if I have two spheres $x^2 + (y-1)^2 + (z-1)^2 = 1$ and $x^2 + y^2 + z^2 = 1$, how can I plot their intersection on a graph?slemonideMon, 23 May 2016 00:23:52 -0500http://ask.sagemath.org/question/33521/Error rending 3d Scene...http://ask.sagemath.org/question/27300/error-rending-3d-scene/I have been attempting to render 3d objects and have been successful for the whole day until just recently. I am constantly getting the following error:
"error rendering 3d scene -- error downloading /blobs/836a1670-2631-40ea-87a8-a4047e9e432d.sage3d?uuid=836a1670-2631-40ea-87a8-a4047e9e432d"
Here is my code
counter3 = 0
counter2 = 0
counter1 = 0
#array for the list of points
pts = []
# Your substitution
w = WordMorphism('1->12,2->13,3->1')
# Your word you wish to apply the substitution to
toApplyOn = "1"
# Number of times to apply the substition
upTo = 4
# empty graphics object
P=Graphics()
for j in range(upTo):
word = w(toApplyOn)
toApplyOn = word
for x in word:
previousVector = v
if int(x) == 3:
counter3 += 1
if int(x) == 2:
counter2 += 1
if int(x) == 1:
counter1 += 1
v = (counter1, counter2, counter3)
pts.append(v)
if not int(x) == (len(word)-1):
if int(x) == 3:
P += line3d([v,previousVector],color='red')
if int(x) == 2:
P += line3d([v,previousVector],color='blue')
if int(x) == 1:
P += line3d([v,previousVector],color='green')
P+=point3d(pts,color='black')
P
My code is suppose to output a 3D image (a neat looking staircase).
I am using the Sage Math Cloud as my environment. Does anyone else get this error? Does anyone have ideas why I receive this error?OzeraAltThu, 09 Jul 2015 18:48:13 -0500http://ask.sagemath.org/question/27300/Plotting 3D points in a certain wayhttp://ask.sagemath.org/question/27281/plotting-3d-points-in-a-certain-way/ I wish to recreate this sort of plot: http://i.imgur.com/19UPf5D.png i.e, plot 3d points in the xyz plane and connect the points by a line.
Does anyone know how to do that?
I found: http://doc.sagemath.org/html/en/reference/plotting/sage/plot/line.html but I haven't been able to find exactly what I want.OzeraWed, 08 Jul 2015 13:15:31 -0500http://ask.sagemath.org/question/27281/