1 | initial version |
Insead of using strings, you can directly save the Sage object:
sage: polynomial.save('/home/pro/Desktop/polynomials.sobj')
Then you can load it as follows:
sage: P = load('/home/pro/Desktop/polynomials.sobj')
2 | No.2 Revision |
Insead of using strings, you can directly save the Sage object:
sage: Then you can load it as follows:
sage: P = 3 | No.3 Revision |
Insead of using strings, you can directly save the Sage object:
sage: polynomial.save('/home/pro/Desktop/polynomials.sobj')
Then you can load it as follows:
sage: P = load('/home/pro/Desktop/polynomials.sobj')
EDIT
If you want to save various polynomials in the same file, you can save a list of polynomials (note that a list do not have a save
merhod, so you have to use the save
function), if P1
,P2
,P3
aez polynomials, you can do:
sage: L = [P1, P2, P3] sage: save(L, '/home/pro/Desktop/polynomials.sobj')
and then recover it as before:
sage: L = load('/home/pro/Desktop/polynomials.sobj')
4 | No.4 Revision |
Insead of using strings, you can directly save the Sage object:
sage: polynomial.save('/home/pro/Desktop/polynomials.sobj')
Then you can load it as follows:
sage: P = load('/home/pro/Desktop/polynomials.sobj')
EDIT
If you want to save various polynomials in the same file, you can save a list of polynomials (note that a list do not have a save
merhod, so you have to use the save
function), if P1
,P2
,P3
aez polynomials, you can do:
sage: L = [P1, P2, P3]
sage: save(L, and then recover it as before:
sage: L = load('/home/pro/Desktop/polynomials.sobj')
5 | No.5 Revision |
Insead Instead of using strings, you can directly save the Sage object:
sage: polynomial.save('/home/pro/Desktop/polynomials.sobj')
Then you can load it as follows:
sage: P = load('/home/pro/Desktop/polynomials.sobj')
EDIT
If you want to You can save various several polynomials in the same file, you can save file by saving a list of polynomials (note that a list do not (but since lists have a no save
merhod, so method, you have to use the save
function), function). For example, if P1
,P2
,P3
aez are polynomials, you can do:
sage: L = [P1, P2, P3]
sage: save(L, '/home/pro/Desktop/polynomials.sobj')
and then recover it as before:
sage: L = load('/home/pro/Desktop/polynomials.sobj')
and you can then get your polynomials back:
sage: P1, P2, P3 = L