On Dec 18, 2007, at 7:54 PM, Jason Grout wrote: > Robert Bradshaw wrote: >> On Dec 18, 2007, at 7:32 PM, Jason Grout wrote: >> >>> Robert Bradshaw wrote: >>>> I would say that latexing x_1 as x_1 is a bug, it should be x\_1 >>>> (probably, haven't looked at what the implications would be >>>> elsewhere). >>>> >>> How would you propose handling the case "x subscript n" (i.e., >>> $x_n$)? >> >> I'm not sure I understand your question, but to be more precise, >> here's what I'm suggesting: >> >> sage: latex(var('x1')) >> x_{1} >> sage: latex(var('x_1')) >> x\_{1} > > Sorry for not being clear. I meant to ask how you would propose > getting > an output latex of $x_n$. In other words, I would like to explicitly > tell latex that there is a subscript. > > Currently: > > sage: latex(var('xn')) > \mbox{xn} > sage: latex(var('x_n')) > x_{n} > > How would you propose getting an output like the second command? I > guess one possibility is that: > > sage: latex(var('variable123')) # where 123 could be any number > variable_{123} > > but > > sage: latex(var('variable_n')) > variable_{n}
Good point. Maybe this suggestion isn't the best idea. But I think x1 -> x_1 is too useful to get rid of (and doesn't cause major problems, if you are mixing x1 and x_1 you are treading on dangerous waters anyway. - Robert --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-devel@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://sage.scipy.org/sage/ and http://modular.math.washington.edu/sage/ -~----------~----~----~----~------~----~------~--~---