asymptote output and Sage question  Yann Le Du  5/3/12 3:30 AM  Hi, Great project! Superb graphics; I'm a user of asymptote, and can't find the export to latex nor to asymptote that is mentioned in the features. Also, I'm currently installing Mathics with Sage support, so perhaps someone could tell me how to use Sage to solve the following from within Mathics (diesn't work at the moment from within Mathics on the web, but it works in Sage): f=D[x * Exp[2*x^2+1/2],x] Solve[f==0,x] Yann 
Re: asymptote output and Sage question  Jan Pöschko  5/4/12 5:29 AM  Hi Yann, On Thursday, May 3, 2012 12:30:08 PM UTC+2, Yann Le Du wrote:
Thanks!
This is not available as a command in the notebook interface, but as a function TeXForm, e.g. TeXForm[Sqrt[x]] (or, equivalently, Sqrt[x]//TeXForm). Unfortunately, something seems to be broken with displaying the generated Asymptote code in MathJax  I'm getting an "Unexpected text node" error, which is rather weird, as this used to work already. The code is generated correctly, it's just no displayed in the browser for me. I hope I can resolve this. It does work in the console version of Mathics (which you get if you download and install it locally): >> Graphics[Rectangle[]]//TeXForm = . \begin{asy} . size(5.83333333333cm, 5cm); . filldraw((0.0,0.0)(350.0,0.0)(350.0,350.0)(0.0,350.0)cycle, rgb(0, 0, 0), nullpen); . \end{asy} The dots just indicate beginnings of new lines and should be removed when copying to Asymptote.
Solve doesn't use Sage (yet), it uses SymPy's solve. Maybe that cannot solve this particular type of equation. I will have a look into this. A potential workaround could be FindRoot which finds a solution numerically, although in this case it seems hard to guess a reasonable starting point. FindRoot[f,{x,0.3}] does work, for instance. Best regards, Jan 
Re: asymptote output and Sage question  Yann Le Du  5/4/12 1:58 PM 
Okm that's cool, let's wait for a web version that works with that.
Yes, but now that my mathics server works inside Sage, how can I call Sage functions like Sage's solve? The doc only mentions SageIntegrate, but is that the only one currently exposed? Also, I had a look at the code for SageIntegrate, it looks quite painful to call Sage's functions properly... yet I understand many issues need to be dealt with when calling Sage ; couldn't there be a set of templates that applies to most of Sage's functions? Yann
