Ask Your Question

Revision history [back]

Which simplification do you expect? With ...simplify_full() you get

-750751*sin(4/5*pi)^2 - 750751/8*sqrt(5) - 2252253/8

and

-613486447667250*sin(4/5*pi)^2 - 306743223833625/4*sqrt(5) - 920229671500875/4

respectively.

Which simplification do you expect? With ...simplify_full() you get

-750751*sin(4/5*pi)^2 - 750751/8*sqrt(5) - 2252253/8

and

-613486447667250*sin(4/5*pi)^2 - 306743223833625/4*sqrt(5) - 920229671500875/4

respectively.

If you aim to expand sin(4/5*pi) Sage can help you with some tricks. From formula pages we can derive that sin(4/5*pi) is the root of a 4-degree polynomial, so we can find its exact representation by:

sage: ex = sin(4/5*pi)
sage: ex.n(200)
0.58778525229247312916870595463907276859765243764314599107227
sage: _.algebraic_dependency(4)
16*x^4 - 20*x^2 + 5
sage: solve(SR(_),x)
[x == -1/2*sqrt(1/2*sqrt(5) + 5/2), x == 1/2*sqrt(1/2*sqrt(5) + 5/2), x == -1/2*sqrt(-1/2*sqrt(5) + 5/2), x == 1/2*sqrt(-1/2*sqrt(5) + 5/2)]
sage: [eq.rhs().n() for eq in _ ]
[-0.951056516295154, 0.951056516295154, -0.587785252292473, 0.587785252292473]

so sin(4/5*pi) is 1/2*sqrt(-1/2*sqrt(5) + 5/2). Now substitute in the two expressions above, simplify, and get:

sage: (-750751*x^2 - 750751/8*sqrt(5) - 2252253/8).subs(x==1/2*sqrt(-1/2*sqrt(5) + 5/2))-750751
sage: (-613486447667250*x^2 - 306743223833625/4*sqrt(5) - 920229671500875/4).subs(x==1/2*sqrt(-1/2*sqrt(5) + 5/2))
-613486447667250

Which simplification do you expect? With ...simplify_full() you get

-750751*sin(4/5*pi)^2 - 750751/8*sqrt(5) - 2252253/8

and

-613486447667250*sin(4/5*pi)^2 - 306743223833625/4*sqrt(5) - 920229671500875/4

respectively.

If you aim to expand sin(4/5*pi) Sage can help you with some tricks. From formula pages we can derive that sin(4/5*pi) is the root of a 4-degree polynomial, so we can find its exact representation by:

sage: ex = sin(4/5*pi)
sage: ex.n(200)
0.58778525229247312916870595463907276859765243764314599107227
sage: _.algebraic_dependency(4)
16*x^4 - 20*x^2 + 5
sage: solve(SR(_),x)
[x == -1/2*sqrt(1/2*sqrt(5) + 5/2), x == 1/2*sqrt(1/2*sqrt(5) + 5/2), x == -1/2*sqrt(-1/2*sqrt(5) + 5/2), x == 1/2*sqrt(-1/2*sqrt(5) + 5/2)]
sage: [eq.rhs().n() for eq in _ ]
[-0.951056516295154, 0.951056516295154, -0.587785252292473, 0.587785252292473]

so sin(4/5*pi) is 1/2*sqrt(-1/2*sqrt(5) + 5/2). Now substitute in the two expressions above, simplify, and get:

sage: (-750751*x^2 - 750751/8*sqrt(5) - 2252253/8).subs(x==1/2*sqrt(-1/2*sqrt(5) + 5/2))-750751
5/2))
-750751
sage: (-613486447667250*x^2 - 306743223833625/4*sqrt(5) - 920229671500875/4).subs(x==1/2*sqrt(-1/2*sqrt(5) + 5/2))
-613486447667250

Which simplification do you expect? With ...simplify_full() you get

-750751*sin(4/5*pi)^2 - 750751/8*sqrt(5) - 2252253/8

and

-613486447667250*sin(4/5*pi)^2 - 306743223833625/4*sqrt(5) - 920229671500875/4

respectively.

If you aim to expand sin(4/5*pi) Sage can help you with some tricks. From formula pages we can derive that sin(4/5*pi) is the root of a 4-degree polynomial, so we can find its exact representation by:

sage: ex = sin(4/5*pi)
sage: ex.n(200)
0.58778525229247312916870595463907276859765243764314599107227
sage: _.algebraic_dependency(4)
16*x^4 - 20*x^2 + 5
sage: solve(SR(_),x)
[x == -1/2*sqrt(1/2*sqrt(5) + 5/2), x == 1/2*sqrt(1/2*sqrt(5) + 5/2), x == -1/2*sqrt(-1/2*sqrt(5) + 5/2), x == 1/2*sqrt(-1/2*sqrt(5) + 5/2)]
sage: [eq.rhs().n() for eq in _ ]
[-0.951056516295154, 0.951056516295154, -0.587785252292473, 0.587785252292473]

so sin(4/5*pi) is 1/2*sqrt(-1/2*sqrt(5) + 5/2). Now substitute in the two expressions above, simplify, and get:

sage: (-750751*x^2 - 750751/8*sqrt(5) - 2252253/8).subs(x==1/2*sqrt(-1/2*sqrt(5) + 5/2))
-750751
sage: (-613486447667250*x^2 - 306743223833625/4*sqrt(5) - 920229671500875/4).subs(x==1/2*sqrt(-1/2*sqrt(5) + 5/2))
-613486447667250

It would be easy to add expansions of trig. functions of multiples of pi/5. I'll open a ticket.

Which simplification do you expect? With ...simplify_full() you get

-750751*sin(4/5*pi)^2 - 750751/8*sqrt(5) - 2252253/8

and

-613486447667250*sin(4/5*pi)^2 - 306743223833625/4*sqrt(5) - 920229671500875/4

respectively.

If you aim to expand sin(4/5*pi) Sage can help you with some tricks. From formula pages we can derive that sin(4/5*pi) is the root of a 4-degree polynomial, so we can find its exact representation by:

sage: ex = sin(4/5*pi)
sage: ex.n(200)
0.58778525229247312916870595463907276859765243764314599107227
sage: _.algebraic_dependency(4)
16*x^4 - 20*x^2 + 5
sage: solve(SR(_),x)
[x == -1/2*sqrt(1/2*sqrt(5) + 5/2), x == 1/2*sqrt(1/2*sqrt(5) + 5/2), x == -1/2*sqrt(-1/2*sqrt(5) + 5/2), x == 1/2*sqrt(-1/2*sqrt(5) + 5/2)]
sage: [eq.rhs().n() for eq in _ ]
[-0.951056516295154, 0.951056516295154, -0.587785252292473, 0.587785252292473]

so sin(4/5*pi) is 1/2*sqrt(-1/2*sqrt(5) + 5/2). Now substitute in the two expressions above, simplify, and get:

sage: (-750751*x^2 - 750751/8*sqrt(5) - 2252253/8).subs(x==1/2*sqrt(-1/2*sqrt(5) + 5/2))
-750751
sage: (-613486447667250*x^2 - 306743223833625/4*sqrt(5) - 920229671500875/4).subs(x==1/2*sqrt(-1/2*sqrt(5) + 5/2))
-613486447667250

It would be easy to add expansions of trig. functions of multiples of pi/5. I'll open a ticket.

The ticket is http://trac.sagemath.org/ticket/18954