Problema Gnuplot e Mathematica: non disegnano i grafici

Utilizzo di applicazioni in ambito professionale.
Scrivi risposta
Syn92
Prode Principiante
Messaggi: 11
Iscrizione: mercoledì 14 settembre 2011, 19:52

Problema Gnuplot e Mathematica: non disegnano i grafici

Messaggio da Syn92 »

Ho un problema con questi due software: non riesco a far disegnare i grafici nè a gnuplot nè a Mathematica. Li ho installati correttamente, li apro con i comandi "gnuplot" in un caso e "math" nell'altro ma quando do i comandi:

Codice: Seleziona tutto

plot sin(x)
e

Codice: Seleziona tutto

Plot[Sin[x],{x,-1,1}]
non mi disegnano il grafico. Non danno neanche un errore però. Mathematica come output da:

Codice: Seleziona tutto

In[1]:= Plot[Sin[x],{x,0,-1}]                                                   

Out[1]= -Graphics-
Cercando su internet ho visto che anche altri hanno avuto problemi con gnuplot poichè non avevano i terminali necessari. In effetti quando apro gnuplot come prima riga mi dice "Terminal type set to 'unknown'" Però non ho trovato una soluzione. In effetti con il comando

Codice: Seleziona tutto

set terminal
l'output è:

Codice: Seleziona tutto

Available terminal types:
       cairolatex  LaTeX picture environment using graphicx package and Cairo backend
           canvas  HTML Canvas object
              cgm  Computer Graphics Metafile
          context  ConTeXt with MetaFun (for PDF documents)
            corel  EPS format for CorelDRAW
             dumb  ascii art for anything that prints text
              dxf  dxf-file for AutoCad (default size 120x80)
            eepic  EEPIC -- extended LaTeX picture environment
              emf  Enhanced Metafile format
            emtex  LaTeX picture environment with emTeX specials
         epscairo  eps terminal based on cairo
         epslatex  LaTeX picture environment using graphicx package
              fig  FIG graphics language for XFIG graphics editor
              gif  GIF images using libgd and TrueType fonts
             gpic  GPIC -- Produce graphs in groff using the gpic preprocessor
          hp2623A  HP2623A and maybe others
           hp2648  HP2648 and HP2647
             hpgl  HP7475 and relatives [number of pens] [eject]
           imagen  Imagen laser printer
             jpeg  JPEG images using libgd and TrueType fonts
            latex  LaTeX picture environment
Press return for more: 
              lua  Lua generic terminal driver
               mf  Metafont plotting standard
              mif  Frame maker MIF 3.00 format
               mp  MetaPost plotting standard
             pcl5  HP Designjet 750C, HP Laserjet III/IV, etc. (many options)
         pdfcairo  pdf terminal based on cairo
              png  PNG images using libgd and TrueType fonts
         pngcairo  png terminal based on cairo
       postscript  PostScript graphics, including EPSF embedded files (*.eps)
          pslatex  LaTeX picture environment with PostScript \specials
            pstex  plain TeX with PostScript \specials
         pstricks  LaTeX picture environment with PSTricks macros
              qms  QMS/QUIC Laser printer (also Talaris 1200 and others)
            regis  REGIS graphics language
              svg  W3C Scalable Vector Graphics driver
          tek40xx  Tektronix 4010 and others; most TEK emulators
          tek410x  Tektronix 4106, 4107, 4109 and 420X terminals
          texdraw  LaTeX texdraw environment
             tgif  TGIF X11 [mode] [x,y] [dashed] ["font" [fontsize]]
             tikz  TeX TikZ graphics macros via the lua script driver
         tkcanvas  Tk/Tcl canvas widget [perltk] [interactive]
             tpic  TPIC -- LaTeX picture environment with tpic \specials
Press return for more: 
          unknown  Unknown terminal type - not a plotting device
            vttek  VT-like tek40xx terminal emulator
            xterm  Xterm Tektronix 4014 Mode
dove si vede che mi mancano x11, wxt e xlib che sono i terminali necessari o almeno questo ho capito dalla discussione [RISOLTO]gnuplot. In quella discussione dicono che bisogna attivare un pacchetto ma manca l'immagine che fa vedere che pacchetto è. Inoltre io ho installato gnuplot dall'Ubuntu software center.

Inoltre non ho capito se risolvendo il problema dei terminali di gnuplot verrebbe risolto anche il problema di Mathematica.

AGGIORNAMENTO:
per mathematica ho provato a dare il comando

Codice: Seleziona tutto

<<JavaGraphics`
ma quando poi provo a disegnare un grafico mi dà

Codice: Seleziona tutto

In[2]:= Plot[Sin[x],{x,-1,1}]                                                   

General::unavail: ExportString is not available in this version of Mathematica.

General::unavail: ExportString is not available in this version of Mathematica.

Java::argx: Method named setSize defined in class com.wolfram.jlink.MathJFrame
     was called with an incorrect number or type of arguments. The arguments,
     shown here in a list, were {30 + Null[System`Private`getWidth[]], 
     60 + Null[System`Private`getHeight[]]}.

General::unavail: ExportString is not available in this version of Mathematica.

General::stop: Further output of General::unavail
     will be suppressed during this calculation.

Java::argx: Method named setSize defined in class com.wolfram.jlink.MathJFrame
     was called with an incorrect number or type of arguments. The arguments,
     shown here in a list, were {30 + Null[System`Private`getWidth[]], 
     60 + Null[System`Private`getHeight[]]}.

Out[2]= -Graphics-
Qualcuno mi può aiutare? Grazie in anticipo.
Scrivi risposta

Ritorna a “Applicazioni professionali”

Chi c’è in linea

Visualizzano questa sezione: 0 utenti iscritti e 8 ospiti