Ask Your Question
0

html.table() in sage???

asked 2011-07-05 19:43:55 +0100

sir jazs gravatar image

updated 2011-07-06 10:38:36 +0100

kcrisman gravatar image

Hi group:

I need make the table in sage. I have var that run, so I generated the header problems. these problems do not occur when I remove the header.

my code is:

with header

sage: html.table([("A","B","C","D")],[(k,j,find_minimum_on_interval(Vp(r, 1, 0.33, k/10, 1, (2*j)/10),0,5,tol=0.0000000003, maxfun=500)[0] ,find_minimum_on_interval(Vp(r, 1, 0.33, k/10, 1, (2*j)/10),0,5,tol=0.0000000003, maxfun=500)[1]) for k in [1..2] for j in [1..2] ])

without header

sage: html.table([(k,j,find_minimum_on_interval(Vp(r, 1, 0.33, k/10, 1, (2*j)/10),0,5,tol=0.0000000003, maxfun=500)[0] ,find_minimum_on_interval(Vp(r, 1, 0.33, k/10, 1, (2*j)/10),0,5,tol=0.0000000003, maxfun=500)[1]) for k in [1..2] for j in [1..2] ])

thank

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2011-07-05 19:48:46 +0100

Jason Grout gravatar image

Your code should be:

sage: html.table([("A","B","C","D"), (k,j,find_minimum_on_interval(Vp(r, 1, 0.33, k/10, 1, (2j)/10),0,5,tol=0.0000000003, maxfun=500)[0] ,find_minimum_on_interval(Vp(r, 1, 0.33, k/10, 1, (2j)/10),0,5,tol=0.0000000003, maxfun=500)[1]) for k in [1..2] for j in [1..2] ], header=True)

(note I deleted two square brackets after the header)

In the next version of Sage, it could be done like this:

sage: html.table([(k,j,find_minimum_on_interval(Vp(r, 1, 0.33, k/10, 1, (2j)/10),0,5,tol=0.0000000003, maxfun=500)[0] ,find_minimum_on_interval(Vp(r, 1, 0.33, k/10, 1, (2j)/10),0,5,tol=0.0000000003, maxfun=500)[1]) for k in [1..2] for j in [1..2] ], header=("A","B","C","D"))

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2011-07-05 19:43:55 +0100

Seen: 1,186 times

Last updated: Jul 05 '11