# Revision history [back]

First, you can bypass your pitfall by working in the field of algebraic numbers, QQbar, which is both exact and algebraically closed:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
RuntimeError: Some eigenvalue does not exist in Rational Field.


But:

sage: A = A.change_ring(QQbar)
sage: matrix_function_Jordan(A, pow_sym)
[0.7236067977499790?*2.618033988749895?^k + 0.2763932022500211?*0.3819660112501051?^k 0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k]
[0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k 0.2763932022500211?*2.618033988749895?^k + 0.7236067977499790?*0.3819660112501051?^k]


Second, you may not be happy with such a representation of the result, whose entries belong to the symbolic ring bundled with algerbraic numbers (written in a non-symbolic form).

However, some algebraic numbers have a symbolic representation by radicals. So we can use that representation of algebraic entries of the jordan form before mixing them with symbolic expressions. Let me propose the following change in @mforets code (my comments begin with ##):

def matrix_function_Jordan(A, f):

# returns jordan matrix J and invertible matrix P such that A = P*J*~P
## We change the matrix into a matrix on the field of algebraic numbers
[J, P] = A.change_ring(QQbar).jordan_form(transformation=True);

fJ = zero_matrix(SR, J.ncols())
num_Jordan_blocks = 1+len(J.subdivisions()[0])
fJ.subdivide(J.subdivisions());

for k in range(num_Jordan_blocks):

# get Jordan block Jk
Jk = J.subdivision(k, k)

# dimension of Jordan block Jk
mk = Jk.ncols();

fJk = zero_matrix(SR, mk, mk);

# compute the first row of f(Jk)
## Before applying a symbolic function to the coefficients of J, we change them into symbolic expressions
vk = [f.derivative(x, i)(Jk[i][i].radical_expression())/factorial(i) for i in range(mk)]

# insert vk into each row (above the main diagonal)
for i in range(mk):
row_Jk_i = vector(SR, zero_vector(SR, i).list() + vk[0:mk-i])
fJk.set_row(i, row_Jk_i)

fJ.set_block(k, k, fJk)

## We change the entries of P and P^-1 into symbolic expressions
fA = Psym*fJ*Psyminv

return fA


Now, we have:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
[                            1/10*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5) - 1/10*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 5)                                           1/5*sqrt(5)*(1/2*sqrt(5) + 3/2)^k - 1/5*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k]
[1/20*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5)*(sqrt(5) - 1) + 1/20*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1)*(sqrt(5) - 5)             1/10*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1) + 1/10*sqrt(5)*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 1)]


First, you can bypass your pitfall by working in the field of algebraic numbers, QQbar, which is both exact and algebraically closed:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
RuntimeError: Some eigenvalue does not exist in Rational Field.


But:

sage: A = A.change_ring(QQbar)
sage: matrix_function_Jordan(A, pow_sym)
[0.7236067977499790?*2.618033988749895?^k + 0.2763932022500211?*0.3819660112501051?^k 0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k]
[0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k 0.2763932022500211?*2.618033988749895?^k + 0.7236067977499790?*0.3819660112501051?^k]


Second, you may not be happy with such a representation of the result, whose entries belong to the symbolic ring bundled with algerbraic numbers (written in a non-symbolic form).

However, some algebraic numbers have a symbolic representation by radicals. So we can use that representation of algebraic entries of the jordan form before mixing them with symbolic expressions. Let me propose the following change in @mforets code (my comments begin with ##):

def matrix_function_Jordan(A, f):

# returns jordan matrix J and invertible matrix P such that A = P*J*~P
## We change the matrix into a matrix on the field of algebraic numbers
[J, P] = A.change_ring(QQbar).jordan_form(transformation=True);

fJ = zero_matrix(SR, J.ncols())
num_Jordan_blocks = 1+len(J.subdivisions()[0])
fJ.subdivide(J.subdivisions());

for k in range(num_Jordan_blocks):

# get Jordan block Jk
Jk = J.subdivision(k, k)

# dimension of Jordan block Jk
mk = Jk.ncols();

fJk = zero_matrix(SR, mk, mk);

# compute the first row of f(Jk)
## Before applying a symbolic function to the coefficients of J, we change them into symbolic expressions
vk = [f.derivative(x, i)(Jk[i][i].radical_expression())/factorial(i) for i in range(mk)]

# insert vk into each row (above the main diagonal)
for i in range(mk):
row_Jk_i = vector(SR, zero_vector(SR, i).list() + vk[0:mk-i])
fJk.set_row(i, row_Jk_i)

fJ.set_block(k, k, fJk)

## We change the entries of P and P^-1 into symbolic expressions
fA = Psym*fJ*Psyminv

return fA


Now, we have:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
[                            1/10*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5) - 1/10*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 5)                                           1/5*sqrt(5)*(1/2*sqrt(5) + 3/2)^k - 1/5*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k]
[1/20*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5)*(sqrt(5) - 1) + 1/20*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1)*(sqrt(5) - 5)             1/10*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1) + 1/10*sqrt(5)*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 1)]


Typeset:

$\left(\begin{array}{rr} \frac{1}{10} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} - \frac{1}{10} \, {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 5\right)} & \frac{1}{5} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} - \frac{1}{5} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} \ \frac{1}{20} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} {\left(\sqrt{5} - 1\right)} + \frac{1}{20} \, {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} {\left(\sqrt{5} - 5\right)} & \frac{1}{10} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} + \frac{1}{10} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 1\right)} \end{array}\right)$

First, you can bypass your pitfall by working in the field of algebraic numbers, QQbar, which is both exact and algebraically closed:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
RuntimeError: Some eigenvalue does not exist in Rational Field.


But:

sage: A = A.change_ring(QQbar)
sage: matrix_function_Jordan(A, pow_sym)
[0.7236067977499790?*2.618033988749895?^k + 0.2763932022500211?*0.3819660112501051?^k 0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k]
[0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k 0.2763932022500211?*2.618033988749895?^k + 0.7236067977499790?*0.3819660112501051?^k]


Second, you may not be happy with such a representation of the result, whose entries belong to the symbolic ring bundled with algerbraic numbers (written in a non-symbolic form).

However, some algebraic numbers have a symbolic representation by radicals. So we can use that representation of algebraic entries of the jordan form before mixing them with symbolic expressions. Let me propose the following change in @mforets code (my comments begin with ##):

def matrix_function_Jordan(A, f):

# returns jordan matrix J and invertible matrix P such that A = P*J*~P
## We change the matrix into a matrix on the field of algebraic numbers
[J, P] = A.change_ring(QQbar).jordan_form(transformation=True);

fJ = zero_matrix(SR, J.ncols())
num_Jordan_blocks = 1+len(J.subdivisions()[0])
fJ.subdivide(J.subdivisions());

for k in range(num_Jordan_blocks):

# get Jordan block Jk
Jk = J.subdivision(k, k)

# dimension of Jordan block Jk
mk = Jk.ncols();

fJk = zero_matrix(SR, mk, mk);

# compute the first row of f(Jk)
## Before applying a symbolic function to the coefficients of J, we change them into symbolic expressions
vk = [f.derivative(x, i)(Jk[i][i].radical_expression())/factorial(i) for i in range(mk)]

# insert vk into each row (above the main diagonal)
for i in range(mk):
row_Jk_i = vector(SR, zero_vector(SR, i).list() + vk[0:mk-i])
fJk.set_row(i, row_Jk_i)

fJ.set_block(k, k, fJk)

## We change the entries of P and P^-1 into symbolic expressions
fA = Psym*fJ*Psyminv

return fA


Now, we have:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
[                            1/10*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5) - 1/10*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 5)                                           1/5*sqrt(5)*(1/2*sqrt(5) + 3/2)^k - 1/5*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k]
[1/20*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5)*(sqrt(5) - 1) + 1/20*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1)*(sqrt(5) - 5)             1/10*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1) + 1/10*sqrt(5)*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 1)]


Typeset:

$\left(\begin{array}{rr} \frac{1}{10} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} - \frac{1}{10} \, {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 5\right)} & \frac{1}{5} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} - \frac{1}{5} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} \ \\ \frac{1}{20} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} {\left(\sqrt{5} - 1\right)} + \frac{1}{20} \, {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} {\left(\sqrt{5} - 5\right)} & \frac{1}{10} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} + \frac{1}{10} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 1\right)} \end{array}\right)$

First, you can bypass your pitfall by working in the field of algebraic numbers, QQbar, which is both exact and algebraically closed:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
RuntimeError: Some eigenvalue does not exist in Rational Field.


But:

sage: A = A.change_ring(QQbar)
sage: matrix_function_Jordan(A, pow_sym)
[0.7236067977499790?*2.618033988749895?^k + 0.2763932022500211?*0.3819660112501051?^k 0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k]
[0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k 0.2763932022500211?*2.618033988749895?^k + 0.7236067977499790?*0.3819660112501051?^k]


Second, you may not be happy with such a representation of the result, whose entries belong to the symbolic ring bundled with algerbraic numbers (written in a non-symbolic form).

However, some algebraic numbers have a symbolic representation by radicals. So we can use that representation of algebraic entries of the jordan form before mixing them with symbolic expressions. Let me propose the following change in @mforets code (my comments begin with ##):

def matrix_function_Jordan(A, f):

# returns jordan matrix J and invertible matrix P such that A = P*J*~P
## We change the matrix into a matrix on the field of algebraic numbers
[J, P] = A.change_ring(QQbar).jordan_form(transformation=True);

fJ = zero_matrix(SR, J.ncols())
num_Jordan_blocks = 1+len(J.subdivisions()[0])
fJ.subdivide(J.subdivisions());

for k in range(num_Jordan_blocks):

# get Jordan block Jk
Jk = J.subdivision(k, k)

# dimension of Jordan block Jk
mk = Jk.ncols();

fJk = zero_matrix(SR, mk, mk);

# compute the first row of f(Jk)
## Before applying a symbolic function to the coefficients of J, we change them into symbolic expressions
vk = [f.derivative(x, i)(Jk[i][i].radical_expression())/factorial(i) for i in range(mk)]

# insert vk into each row (above the main diagonal)
for i in range(mk):
row_Jk_i = vector(SR, zero_vector(SR, i).list() + vk[0:mk-i])
fJk.set_row(i, row_Jk_i)

fJ.set_block(k, k, fJk)

## We change the entries of P and P^-1 into symbolic expressions
fA = Psym*fJ*Psyminv

return fA


Now, we have:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
[                            1/10*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5) - 1/10*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 5)                                           1/5*sqrt(5)*(1/2*sqrt(5) + 3/2)^k - 1/5*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k]
[1/20*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5)*(sqrt(5) - 1) + 1/20*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1)*(sqrt(5) - 5)             1/10*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1) + 1/10*sqrt(5)*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 1)]


Typeset:

$\left(\begin{array}{rr} \frac{1}{10} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} - \frac{1}{10} \, {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 5\right)} & \frac{1}{5} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} - \frac{1}{5} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} \\ \frac{1}{20} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} {\left(\sqrt{5} - 1\right)} + \frac{1}{20} \, {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} {\left(\sqrt{5} - 5\right)} & \frac{1}{10} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} + \frac{1}{10} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 1\right)} \end{array}\right)$

It also works with matrix(QQ, [[0,4,1],[-1,1,5],[2,0,-89]]) but the result is huge.

First, you can bypass your pitfall by working in the field of algebraic numbers, QQbar, which is both exact and algebraically closed:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
RuntimeError: Some eigenvalue does not exist in Rational Field.


But:

sage: A = A.change_ring(QQbar)
sage: matrix_function_Jordan(A, pow_sym)
[0.7236067977499790?*2.618033988749895?^k + 0.2763932022500211?*0.3819660112501051?^k 0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k]
[0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k 0.2763932022500211?*2.618033988749895?^k + 0.7236067977499790?*0.3819660112501051?^k]


Second, you may not be happy with such a representation of the result, whose entries belong to the symbolic ring bundled with algerbraic numbers (written in a non-symbolic form).

However, some algebraic numbers have a symbolic representation by radicals. So we can use that representation of algebraic entries of the jordan form before mixing them with symbolic expressions. Let me propose the following change in @mforets code (my comments begin with ##):

def matrix_function_Jordan(A, f):

# returns jordan matrix J and invertible matrix P such that A = P*J*~P
## We change the matrix into a matrix on the field of algebraic numbers
[J, P] = A.change_ring(QQbar).jordan_form(transformation=True);

fJ = zero_matrix(SR, J.ncols())
num_Jordan_blocks = 1+len(J.subdivisions()[0])
fJ.subdivide(J.subdivisions());

for k in range(num_Jordan_blocks):

# get Jordan block Jk
Jk = J.subdivision(k, k)

# dimension of Jordan block Jk
mk = Jk.ncols();

fJk = zero_matrix(SR, mk, mk);

# compute the first row of f(Jk)
## Before applying a symbolic function to the coefficients of J, we change them into symbolic expressions
vk = [f.derivative(x, i)(Jk[i][i].radical_expression())/factorial(i) for i in range(mk)]

# insert vk into each row (above the main diagonal)
for i in range(mk):
row_Jk_i = vector(SR, zero_vector(SR, i).list() + vk[0:mk-i])
fJk.set_row(i, row_Jk_i)

fJ.set_block(k, k, fJk)

## We change the entries of P and P^-1 into symbolic expressions
fA = Psym*fJ*Psyminv

return fA


Now, we have:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
[                            1/10*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5) - 1/10*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 5)                                           1/5*sqrt(5)*(1/2*sqrt(5) + 3/2)^k - 1/5*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k]
[1/20*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5)*(sqrt(5) - 1) + 1/20*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1)*(sqrt(5) - 5)             1/10*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1) + 1/10*sqrt(5)*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 1)]


Typeset:

$\left(\begin{array}{rr} \frac{1}{10} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} - \frac{1}{10} \, {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 5\right)} & \frac{1}{5} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} - \frac{1}{5} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} \\ \frac{1}{20} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} {\left(\sqrt{5} - 1\right)} + \frac{1}{20} \, {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} {\left(\sqrt{5} - 5\right)} & \frac{1}{10} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} + \frac{1}{10} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 1\right)} \end{array}\right)$

It also works with matrix(QQ, [[0,4,1],[-1,1,5],[2,0,-89]]) but the result is huge.

$\left(\begin{array}{rrr} -\frac{1}{106517166} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{106517166} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{53258583} \, {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & -\frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(-32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & -\frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{9394814041200} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{4697407020600} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} - \frac{1}{4697407020600} \, {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{28184442123600} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} \, {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(-32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{28184442123600} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} \, {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{2348703510300} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{1174351755150} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{1174351755150} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{7046110530900} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(-32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{7046110530900} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \end{array}\right)$

First, you can bypass your pitfall by working in the field of algebraic numbers, QQbar, which is both exact and algebraically closed:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
RuntimeError: Some eigenvalue does not exist in Rational Field.


But:

sage: A = A.change_ring(QQbar)
sage: matrix_function_Jordan(A, pow_sym)
[0.7236067977499790?*2.618033988749895?^k + 0.2763932022500211?*0.3819660112501051?^k 0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k]
[0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k 0.2763932022500211?*2.618033988749895?^k + 0.7236067977499790?*0.3819660112501051?^k]


Second, you may not be happy with such a representation of the result, whose entries belong to the symbolic ring bundled with algerbraic numbers (written in a non-symbolic form).

However, some algebraic numbers have a symbolic representation by radicals. So we can use that representation of algebraic entries of the jordan form before mixing them with symbolic expressions. Let me propose the following change in @mforets code (my comments begin with ##):

def matrix_function_Jordan(A, f):

# returns jordan matrix J and invertible matrix P such that A = P*J*~P
## We change the matrix into a matrix on the field of algebraic numbers
[J, P] = A.change_ring(QQbar).jordan_form(transformation=True);

fJ = zero_matrix(SR, J.ncols())
num_Jordan_blocks = 1+len(J.subdivisions()[0])
fJ.subdivide(J.subdivisions());

for k in range(num_Jordan_blocks):

# get Jordan block Jk
Jk = J.subdivision(k, k)

# dimension of Jordan block Jk
mk = Jk.ncols();

fJk = zero_matrix(SR, mk, mk);

# compute the first row of f(Jk)
## Before applying a symbolic function to the coefficients of J, we change them into symbolic expressions
vk = [f.derivative(x, i)(Jk[i][i].radical_expression())/factorial(i) for i in range(mk)]

# insert vk into each row (above the main diagonal)
for i in range(mk):
row_Jk_i = vector(SR, zero_vector(SR, i).list() + vk[0:mk-i])
fJk.set_row(i, row_Jk_i)

fJ.set_block(k, k, fJk)

## We change the entries of P and P^-1 into symbolic expressions
fA = Psym*fJ*Psyminv

return fA


Now, we have:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
[                            1/10*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5) - 1/10*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 5)                                           1/5*sqrt(5)*(1/2*sqrt(5) + 3/2)^k - 1/5*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k]
[1/20*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5)*(sqrt(5) - 1) + 1/20*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1)*(sqrt(5) - 5)             1/10*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1) + 1/10*sqrt(5)*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 1)]


Typeset:

$\left(\begin{array}{rr} \frac{1}{10} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} - \frac{1}{10} \, {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 5\right)} & \frac{1}{5} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} - \frac{1}{5} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} \\ \frac{1}{20} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} {\left(\sqrt{5} - 1\right)} + \frac{1}{20} \, {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} {\left(\sqrt{5} - 5\right)} & \frac{1}{10} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} + \frac{1}{10} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 1\right)} \end{array}\right)$

It The function also works with matrix(QQ, [[0,4,1],[-1,1,5],[2,0,-89]]) but the result is huge.so huge that your browser will not like it:

$\left(\begin{array}{rrr} -\frac{1}{106517166} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{106517166} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{53258583} \, {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & -\frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(-32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & -\frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{9394814041200} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{4697407020600} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} - \frac{1}{4697407020600} \, {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{28184442123600} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} \, {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(-32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{28184442123600} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} \, {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{2348703510300} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{1174351755150} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{1174351755150} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{7046110530900} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(-32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{7046110530900} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \end{array}\right)$

First, you can bypass your pitfall by working in the field of algebraic numbers, QQbar, which is both exact and algebraically closed:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
RuntimeError: Some eigenvalue does not exist in Rational Field.


But:

sage: A = A.change_ring(QQbar)
sage: matrix_function_Jordan(A, pow_sym)
[0.7236067977499790?*2.618033988749895?^k + 0.2763932022500211?*0.3819660112501051?^k 0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k]
[0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k 0.2763932022500211?*2.618033988749895?^k + 0.7236067977499790?*0.3819660112501051?^k]


Second, you may not be happy with such a representation of the result, whose entries belong to the symbolic ring bundled with algerbraic numbers (written in a non-symbolic form).

However, some algebraic numbers have a symbolic representation by radicals. So we can use that representation of algebraic entries of the jordan form before mixing them with symbolic expressions. Let me propose the following change in @mforets code (my comments begin with ##):

def matrix_function_Jordan(A, f):

# returns jordan matrix J and invertible matrix P such that A = P*J*~P
## We change the matrix into a matrix on the field of algebraic numbers
[J, P] = A.change_ring(QQbar).jordan_form(transformation=True);

fJ = zero_matrix(SR, J.ncols())
num_Jordan_blocks = 1+len(J.subdivisions()[0])
fJ.subdivide(J.subdivisions());

for k in range(num_Jordan_blocks):

# get Jordan block Jk
Jk = J.subdivision(k, k)

# dimension of Jordan block Jk
mk = Jk.ncols();

fJk = zero_matrix(SR, mk, mk);

# compute the first row of f(Jk)
## Before applying a symbolic function to the coefficients of J, we change them into symbolic expressions
vk = [f.derivative(x, i)(Jk[i][i].radical_expression())/factorial(i) for i in range(mk)]

# insert vk into each row (above the main diagonal)
for i in range(mk):
row_Jk_i = vector(SR, zero_vector(SR, i).list() + vk[0:mk-i])
fJk.set_row(i, row_Jk_i)

fJ.set_block(k, k, fJk)

## We change the entries of P and P^-1 into symbolic expressions
fA = Psym*fJ*Psyminv

return fA


Now, we have:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
[                            1/10*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5) - 1/10*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 5)                                           1/5*sqrt(5)*(1/2*sqrt(5) + 3/2)^k - 1/5*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k]
[1/20*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5)*(sqrt(5) - 1) + 1/20*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1)*(sqrt(5) - 5)             1/10*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1) + 1/10*sqrt(5)*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 1)]


Typeset:

$\left(\begin{array}{rr} \frac{1}{10} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} - \frac{1}{10} \, {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 5\right)} & \frac{1}{5} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} - \frac{1}{5} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} \\ \frac{1}{20} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} {\left(\sqrt{5} - 1\right)} + \frac{1}{20} \, {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} {\left(\sqrt{5} - 5\right)} & \frac{1}{10} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} + \frac{1}{10} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 1\right)} \end{array}\right)$

The function also works with matrix(QQ, [[0,4,1],[-1,1,5],[2,0,-89]]) but the result is so huge that your browser will not like it:

$\left(\begin{array}{rrr} -\frac{1}{106517166} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{106517166} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{53258583} \, {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & -\frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(-32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & -\frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{9394814041200} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{4697407020600} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} - \frac{1}{4697407020600} \, {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{28184442123600} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} \, {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(-32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{28184442123600} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} \, {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{2348703510300} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{1174351755150} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{1174351755150} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{7046110530900} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(-32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{7046110530900} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \end{array}\right)$

First, you can bypass your pitfall by working in the field of algebraic numbers, QQbar, which is both exact and algebraically closed:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
RuntimeError: Some eigenvalue does not exist in Rational Field.


But:

sage: A = A.change_ring(QQbar)
sage: matrix_function_Jordan(A, pow_sym)
[0.7236067977499790?*2.618033988749895?^k + 0.2763932022500211?*0.3819660112501051?^k 0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k]
[0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k 0.2763932022500211?*2.618033988749895?^k + 0.7236067977499790?*0.3819660112501051?^k]


Second, you may not be happy with such a representation of the result, whose entries belong to the symbolic ring bundled with algerbraic numbers (written in a non-symbolic form).

However, some algebraic numbers have a symbolic representation by radicals. So we can use that representation of algebraic entries of the jordan form before mixing them with symbolic expressions. Let me propose the following change in @mforets code (my comments begin with ##):

def matrix_function_Jordan(A, f):

# returns jordan matrix J and invertible matrix P such that A = P*J*~P
## We change the matrix into a matrix on the field of algebraic numbers
[J, P] = A.change_ring(QQbar).jordan_form(transformation=True);

fJ = zero_matrix(SR, J.ncols())
num_Jordan_blocks = 1+len(J.subdivisions()[0])
fJ.subdivide(J.subdivisions());

for k in range(num_Jordan_blocks):

# get Jordan block Jk
Jk = J.subdivision(k, k)

# dimension of Jordan block Jk
mk = Jk.ncols();

fJk = zero_matrix(SR, mk, mk);

# compute the first row of f(Jk)
## Before applying a symbolic function to the coefficients of J, we change them into symbolic expressions
vk = [f.derivative(x, i)(Jk[i][i].radical_expression())/factorial(i) for i in range(mk)]

# insert vk into each row (above the main diagonal)
for i in range(mk):
row_Jk_i = vector(SR, zero_vector(SR, i).list() + vk[0:mk-i])
fJk.set_row(i, row_Jk_i)

fJ.set_block(k, k, fJk)

## We change the entries of P and P^-1 into symbolic expressions
fA = Psym*fJ*Psyminv

return fA


Now, we have:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
[                            1/10*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5) - 1/10*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 5)                                           1/5*sqrt(5)*(1/2*sqrt(5) + 3/2)^k - 1/5*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k]
[1/20*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5)*(sqrt(5) - 1) + 1/20*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1)*(sqrt(5) - 5)             1/10*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1) + 1/10*sqrt(5)*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 1)]


Typeset:

$\left(\begin{array}{rr} \frac{1}{10} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} - \frac{1}{10} \, {\left(-\frac{1}{2} \, {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 5\right)} & \frac{1}{5} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} - \frac{1}{5} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} \\ \frac{1}{20} \, {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} {\left(\sqrt{5} - 1\right)} + \frac{1}{20} \, {\left(-\frac{1}{2} \, {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} {\left(\sqrt{5} - 5\right)} & \frac{1}{10} \, \sqrt{5} {\left(-\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} + \frac{1}{10} \, \sqrt{5} {\left(\frac{1}{2} \, \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 1\right)} \end{array}\right)$

The function also works with matrix(QQ, [[0,4,1],[-1,1,5],[2,0,-89]]) but the result is so huge that your browser will not like it:

$\left(\begin{array}{rrr} -\frac{1}{106517166} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{106517166} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{53258583} \, {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & -\frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(-32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & -\frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{9394814041200} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{4697407020600} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} - \frac{1}{4697407020600} \, {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{28184442123600} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} \, {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(-32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{28184442123600} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} \, {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} \, {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 \, {\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \, \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{2348703510300} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{1174351755150} \, {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-1154521 i \, \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{1174351755150} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 \, {\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{7046110530900} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(-32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} \, {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{2 \, {\left(32133662 i \, \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{7046110530900} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} + \frac{-16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} - \frac{188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} \, {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \, \sqrt{3} + 1\right)} - \frac{-188329 i \, \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} \, {\left(11025 \, {\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \, \sqrt{3} + 1\right)} + \frac{16066831 i \, \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \, \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} \, {\left(\frac{2}{3} \, \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \, \sqrt{3} + 8005}{18 \, {\left(\frac{2}{3} \, {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 \, {\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \, \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \end{array}\right)$

First, you can bypass your pitfall by working in the field of algebraic numbers, QQbar, which is both exact and algebraically closed:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
RuntimeError: Some eigenvalue does not exist in Rational Field.


But:

sage: A = A.change_ring(QQbar)
sage: matrix_function_Jordan(A, pow_sym)
[0.7236067977499790?*2.618033988749895?^k + 0.2763932022500211?*0.3819660112501051?^k 0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k]
[0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k 0.2763932022500211?*2.618033988749895?^k + 0.7236067977499790?*0.3819660112501051?^k]


Second, you may not be happy with such a representation of the result, whose entries belong to the symbolic ring bundled with algerbraic numbers (written in a non-symbolic form).

However, some algebraic numbers have a symbolic representation by radicals. So we can use that representation of algebraic entries of the jordan form before mixing them with symbolic expressions. Let me propose the following change in @mforets code (my comments begin with ##):

def matrix_function_Jordan(A, f):

# returns jordan matrix J and invertible matrix P such that A = P*J*~P
## We change the matrix into a matrix on the field of algebraic numbers
[J, P] = A.change_ring(QQbar).jordan_form(transformation=True);

fJ = zero_matrix(SR, J.ncols())
num_Jordan_blocks = 1+len(J.subdivisions()[0])
fJ.subdivide(J.subdivisions());

for k in range(num_Jordan_blocks):

# get Jordan block Jk
Jk = J.subdivision(k, k)

# dimension of Jordan block Jk
mk = Jk.ncols();

fJk = zero_matrix(SR, mk, mk);

# compute the first row of f(Jk)
## Before applying a symbolic function to the coefficients of J, we change them into symbolic expressions
vk = [f.derivative(x, i)(Jk[i][i].radical_expression())/factorial(i) for i in range(mk)]

# insert vk into each row (above the main diagonal)
for i in range(mk):
row_Jk_i = vector(SR, zero_vector(SR, i).list() + vk[0:mk-i])
fJk.set_row(i, row_Jk_i)

fJ.set_block(k, k, fJk)

## We change the entries of P and P^-1 into symbolic expressions
fA = Psym*fJ*Psyminv

return fA


Now, we have:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
[                            1/10*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5) - 1/10*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 5)                                           1/5*sqrt(5)*(1/2*sqrt(5) + 3/2)^k - 1/5*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k]
[1/20*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5)*(sqrt(5) - 1) + 1/20*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1)*(sqrt(5) - 5)             1/10*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1) + 1/10*sqrt(5)*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 1)]


Typeset:

$\left(\begin{array}{rr} \frac{1}{10} {\left(\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} - \frac{1}{10} {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 5\right)} & \frac{1}{5} \sqrt{5} {\left(\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} - \frac{1}{5} \sqrt{5} {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} \\ \frac{1}{20} {\left(\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} {\left(\sqrt{5} - 1\right)} + \frac{1}{20} {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} {\left(\sqrt{5} - 5\right)} & \frac{1}{10} \sqrt{5} {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} + \frac{1}{10} \sqrt{5} {\left(\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 1\right)} \end{array}\right)$

The function also works with matrix(QQ, [[0,4,1],[-1,1,5],[2,0,-89]]) but the result is so huge that your browser will not like it:

$\left(\begin{array}{rrr} -\frac{1}{106517166} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{106517166} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{53258583} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & -\frac{1}{319551498} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{2 {\left(32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{2 {\left(-32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & -\frac{1}{319551498} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{9394814041200} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{4697407020600} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} - \frac{1}{4697407020600} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{28184442123600} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{2 {\left(32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{2 {\left(-32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{28184442123600} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{2348703510300} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{1174351755150} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{1174351755150} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{7046110530900} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{2 {\left(-32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{2 {\left(32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{7046110530900} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \end{array}\right)$

First, you we can bypass your the pitfall by working in the field of algebraic numbers, QQbar, which is both exact and algebraically closed:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
RuntimeError: Some eigenvalue does not exist in Rational Field.


But:

sage: A = A.change_ring(QQbar)
sage: matrix_function_Jordan(A, pow_sym)
[0.7236067977499790?*2.618033988749895?^k + 0.2763932022500211?*0.3819660112501051?^k 0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k]
[0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k 0.2763932022500211?*2.618033988749895?^k + 0.7236067977499790?*0.3819660112501051?^k]


Second, you may not be happy with such a representation of the result, whose entries belong to the symbolic ring bundled with algerbraic numbers (written in a non-symbolic form).

However, some algebraic numbers have a symbolic representation by radicals. So we can use that representation of algebraic entries of the jordan form before mixing them with symbolic expressions. Let me propose the following change in @mforets code (my comments begin with ##):

def matrix_function_Jordan(A, f):

# returns jordan matrix J and invertible matrix P such that A = P*J*~P
## We change the matrix into a matrix on the field of algebraic numbers
[J, P] = A.change_ring(QQbar).jordan_form(transformation=True);

fJ = zero_matrix(SR, J.ncols())
num_Jordan_blocks = 1+len(J.subdivisions()[0])
fJ.subdivide(J.subdivisions());

for k in range(num_Jordan_blocks):

# get Jordan block Jk
Jk = J.subdivision(k, k)

# dimension of Jordan block Jk
mk = Jk.ncols();

fJk = zero_matrix(SR, mk, mk);

# compute the first row of f(Jk)
## Before applying a symbolic function to the coefficients of J, we change them into symbolic expressions
vk = [f.derivative(x, i)(Jk[i][i].radical_expression())/factorial(i) for i in range(mk)]

# insert vk into each row (above the main diagonal)
for i in range(mk):
row_Jk_i = vector(SR, zero_vector(SR, i).list() + vk[0:mk-i])
fJk.set_row(i, row_Jk_i)

fJ.set_block(k, k, fJk)

## We change the entries of P and P^-1 into symbolic expressions
fA = Psym*fJ*Psyminv

return fA


Now, we have:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
[                            1/10*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5) - 1/10*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 5)                                           1/5*sqrt(5)*(1/2*sqrt(5) + 3/2)^k - 1/5*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k]
[1/20*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5)*(sqrt(5) - 1) + 1/20*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1)*(sqrt(5) - 5)             1/10*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1) + 1/10*sqrt(5)*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 1)]


Typeset:

$\left(\begin{array}{rr} \frac{1}{10} {\left(\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} - \frac{1}{10} {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 5\right)} & \frac{1}{5} \sqrt{5} {\left(\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} - \frac{1}{5} \sqrt{5} {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} \\ \frac{1}{20} {\left(\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} {\left(\sqrt{5} - 1\right)} + \frac{1}{20} {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} {\left(\sqrt{5} - 5\right)} & \frac{1}{10} \sqrt{5} {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} + \frac{1}{10} \sqrt{5} {\left(\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 1\right)} \end{array}\right)$

The function also works with matrix(QQ, [[0,4,1],[-1,1,5],[2,0,-89]]) but the result is so huge that your browser will not like it:

$\left(\begin{array}{rrr} -\frac{1}{106517166} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{106517166} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{53258583} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & -\frac{1}{319551498} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{2 {\left(32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{2 {\left(-32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & -\frac{1}{319551498} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{9394814041200} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{4697407020600} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} - \frac{1}{4697407020600} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{28184442123600} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{2 {\left(32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{2 {\left(-32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{28184442123600} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{2348703510300} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{1174351755150} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{1174351755150} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{7046110530900} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{2 {\left(-32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{2 {\left(32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{7046110530900} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \end{array}\right)$

EDIT : this feature should be soon part of Sage, see trac ticket 22523 !

First, we can bypass the pitfall by working in the field of algebraic numbers, QQbar, which is both exact and algebraically closed:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
RuntimeError: Some eigenvalue does not exist in Rational Field.


But:

sage: A = A.change_ring(QQbar)
sage: matrix_function_Jordan(A, pow_sym)
[0.7236067977499790?*2.618033988749895?^k + 0.2763932022500211?*0.3819660112501051?^k 0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k]
[0.4472135954999580?*2.618033988749895?^k - 0.4472135954999580?*0.3819660112501051?^k 0.2763932022500211?*2.618033988749895?^k + 0.7236067977499790?*0.3819660112501051?^k]


Second, you may not be happy with such a representation of the result, whose entries belong to the symbolic ring bundled with algerbraic numbers (written in a non-symbolic form).

However, some algebraic numbers have a symbolic representation by radicals. So we can use that representation of algebraic entries of the jordan form before mixing them with symbolic expressions. Let me propose the following change in @mforets code (my comments begin with ##):

def matrix_function_Jordan(A, f):

# returns jordan matrix J and invertible matrix P such that A = P*J*~P
## We change the matrix into a matrix on the field of algebraic numbers
[J, P] = A.change_ring(QQbar).jordan_form(transformation=True);

fJ = zero_matrix(SR, J.ncols())
num_Jordan_blocks = 1+len(J.subdivisions()[0])
fJ.subdivide(J.subdivisions());

for k in range(num_Jordan_blocks):

# get Jordan block Jk
Jk = J.subdivision(k, k)

# dimension of Jordan block Jk
mk = Jk.ncols();

fJk = zero_matrix(SR, mk, mk);

# compute the first row of f(Jk)
## Before applying a symbolic function to the coefficients of J, we change them into symbolic expressions
vk = [f.derivative(x, i)(Jk[i][i].radical_expression())/factorial(i) for i in range(mk)]

# insert vk into each row (above the main diagonal)
for i in range(mk):
row_Jk_i = vector(SR, zero_vector(SR, i).list() + vk[0:mk-i])
fJk.set_row(i, row_Jk_i)

fJ.set_block(k, k, fJk)

## We change the entries of P and P^-1 into symbolic expressions
fA = Psym*fJ*Psyminv

return fA


Now, we have:

sage: A = matrix(QQ, [[2,1],[1,1]])
sage: matrix_function_Jordan(A, pow_sym)
[                            1/10*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5) - 1/10*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 5)                                           1/5*sqrt(5)*(1/2*sqrt(5) + 3/2)^k - 1/5*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k]
[1/20*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 5)*(sqrt(5) - 1) + 1/20*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1)*(sqrt(5) - 5)             1/10*sqrt(5)*(-1/2*sqrt(5) + 3/2)^k*(sqrt(5) + 1) + 1/10*sqrt(5)*(1/2*sqrt(5) + 3/2)^k*(sqrt(5) - 1)]


Typeset:

$\left(\begin{array}{rr} \frac{1}{10} {\left(\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} - \frac{1}{10} {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 5\right)} & \frac{1}{5} \sqrt{5} {\left(\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} - \frac{1}{5} \sqrt{5} {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} \\ \frac{1}{20} {\left(\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 5\right)} {\left(\sqrt{5} - 1\right)} + \frac{1}{20} {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} {\left(\sqrt{5} - 5\right)} & \frac{1}{10} \sqrt{5} {\left(-\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} + 1\right)} + \frac{1}{10} \sqrt{5} {\left(\frac{1}{2} \sqrt{5} + \frac{3}{2}\right)}^{k} {\left(\sqrt{5} - 1\right)} \end{array}\right)$

The function also works with matrix(QQ, [[0,4,1],[-1,1,5],[2,0,-89]]) but the result is so huge that your browser will not like it:

$\left(\begin{array}{rrr} -\frac{1}{106517166} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{106517166} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{53258583} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & -\frac{1}{319551498} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{2 {\left(32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{2 {\left(-32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & -\frac{1}{319551498} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{319551498} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{159775749} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{9394814041200} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{4697407020600} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} - \frac{1}{4697407020600} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{28184442123600} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{2 {\left(32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{2 {\left(-32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{28184442123600} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{28184442123600} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} - 194460\right)} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} + \frac{1}{7046110530900} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(44100 {\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}} + \frac{188329}{{\left(\frac{1}{1225} \sqrt{2536123} \sqrt{7} + \frac{87716917}{9261000}\right)}^{\frac{1}{3}}} + 97230\right)} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \\ \frac{1}{2348703510300} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{1174351755150} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-1154521 i \sqrt{3} + 1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} - 35505722\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{1174351755150} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(53258583 {\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}} + \frac{1154521}{{\left(\frac{14048645297}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{3668486}{479327247}\right)}^{\frac{1}{3}}} + 17752861\right)} & \frac{1}{7046110530900} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{2 {\left(-32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{2 {\left(32133662 i \sqrt{3} - 32133662\right)}}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 {\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}} - \frac{64267324}{{\left(\frac{515211235568}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{7608369}\right)}^{\frac{1}{3}}}\right)} & \frac{1}{7046110530900} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} + \frac{-16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left({\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} + \frac{8005}{9 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} - \frac{1}{3523055265450} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-188329 i \sqrt{3} + 188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(i \sqrt{3} + 1\right)} - \frac{-8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} + \frac{16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} - 420630\right)} - \frac{1}{3523055265450} {\left(11025 {\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} + \frac{16066831 i \sqrt{3} + 16066831}{{\left(\frac{1}{3675} \sqrt{2536123} \sqrt{7} - \frac{64401404446}{1157625}\right)}^{\frac{1}{3}}} + 841260\right)} {\left(-\frac{1}{2} {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}} {\left(-i \sqrt{3} + 1\right)} - \frac{8005 i \sqrt{3} + 8005}{18 {\left(\frac{2}{3} \sqrt{17752861} - \frac{720217}{27}\right)}^{\frac{1}{3}}} - \frac{88}{3}\right)}^{k} {\left(159775749 {\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}} - \frac{188329}{{\left(\frac{87716917}{21580961113270008463041} \sqrt{114184979435291050069} - \frac{40}{2536123}\right)}^{\frac{1}{3}}}\right)} \end{array}\right)$