File tree Expand file tree Collapse file tree 1 file changed +2
-4
lines changed
src/doc/en/a_tour_of_sage Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -38,15 +38,15 @@ Here we integrate a simple function.
38
38
39
39
::
40
40
41
- sage: var('x') # create a symbolic variable
41
+ sage: x = var('x') # create a symbolic variable
42
42
sage: integrate(sqrt(x) * sqrt(1 + x), x)
43
43
1/4*((x + 1)^(3/2)/x^(3/2) + sqrt(x + 1)/sqrt(x))/((x + 1)^2/x^2 - 2*(x + 1)/x + 1) - 1/8*log(sqrt(x + 1)/sqrt(x) + 1) + 1/8*log(sqrt(x + 1)/sqrt(x) - 1)
44
44
45
45
This asks Sage to solve a quadratic equation. The symbol ``== `` represents equality in Sage.
46
46
47
47
::
48
48
49
- sage: var('a')
49
+ sage: a = var('a')
50
50
sage: S = solve(x^2 + x == a, x); S
51
51
[x == -1/2*sqrt(4*a + 1) - 1/2, x == 1/2*sqrt(4*a + 1) - 1/2]
52
52
@@ -126,8 +126,6 @@ This asks Sage to factor a polynomial in two variables.
126
126
x^30*y^30 - x^27*y^33 + x^21*y^39 + x^18*y^42 - x^12*y^48 -
127
127
x^9*y^51 + x^3*y^57 + y^60)
128
128
129
- ::
130
-
131
129
sage: F.expand()
132
130
x^99 + y^99
133
131
You can’t perform that action at this time.
0 commit comments