Menu

#190 Minus sign in equation viewer: problem with verbatiminput

v1.0_(example)
closed
nobody
None
5
2015-07-08
2015-04-10
No

I posted a problem with gretl to tex.stackexchange as I thought it was a pure LaTeX problem:
http://tex.stackexchange.com/questions/237842/verbatiminput-whitespace-formatting

The comments suggest that the minus sign currently used in the equation viewer causes LaTeX errors. Could you change the minus sign to something compatible with LaTeX?

Related

Bugs: #190

Discussion

  • Riccardo "Jack" Lucchetti

    On Fri, 10 Apr 2015, Sebastian Bayer wrote:


    [bugs:#190] Minus sign in equation viewer: problem with verbatiminput

    Status: open
    Group: v1.0_(example)
    Created: Fri Apr 10, 2015 07:50 AM UTC by Sebastian Bayer
    Last Updated: Fri Apr 10, 2015 07:50 AM UTC
    Owner: nobody

    I posted a problem with gretl to tex.stackexchange as I thought it was a pure LaTeX problem:
    http://tex.stackexchange.com/questions/237842/verbatiminput-whitespace-formatting

    The comments suggest that the minus sign currently used in the equation
    viewer causes LaTeX errors. Could you change the minus sign to something
    compatible with LaTeX?

    In fact, who should bear the burden of adjustment is debatable IMO.

    Here's the story: gretl has used (for a few years now) the Unicode
    character 2212 for the minus sign if the output terminal supports Unicode.
    This is typographically correct (see for example here:
    http://www.punctuationmatters.com/the-difference-between-a-dash-and-a-minus-sign/),
    but doesn't play nice with LaTeX because of its awkward relationships with
    Unicode: the solution I use is to put the two lines

    \usepackage[utf8]{inputenc}
    \DeclareUnicodeCharacter{2212}{-}

    in the LaTeX preamble, so that it's the inputenc package that takes care
    of everything.

    This said, I don't know whether some adjustments could be made on the
    gretl side to avoid problems.


    Riccardo (Jack) Lucchetti
    Dipartimento di Scienze Economiche e Sociali (DiSES)

    Università Politecnica delle Marche
    (formerly known as Università di Ancona)

    r.lucchetti@univpm.it
    http://www2.econ.univpm.it/servizi/hpp/lucchetti


     

    Related

    Bugs: #190

  • Sebastian Bayer

    Sebastian Bayer - 2015-04-10

    Thank you for the explanation and the solution!

     
  • Allin Cottrell

    Allin Cottrell - 2015-04-10

    Sebastian, you're sticking gretl's plain text (UTF-8)
    output into LaTeX. I'm puzzled: why wouldn't you use
    gretl's TeX output instead? (That has no problem with
    the minus signs.)

     
    • Riccardo "Jack" Lucchetti

      On Fri, 10 Apr 2015, Allin Cottrell wrote:

      Sebastian, you're sticking gretl's plain text (UTF-8)
      output into LaTeX. I'm puzzled: why wouldn't you use
      gretl's TeX output instead? (That has no problem with
      the minus signs.)

      I do that myself, from time to time, especially when preparing material
      for students: I use the gui client to try things out, then when I'm happy
      I just copy-n-paste the output into a \verbatim environment. Job done.

      I must also admit that I quite like the visual impact of a chunk of
      monospaced stuff inside an lmodern-dominated document.


      Riccardo (Jack) Lucchetti
      Dipartimento di Scienze Economiche e Sociali (DiSES)

      Università Politecnica delle Marche
      (formerly known as Università di Ancona)

      r.lucchetti@univpm.it
      http://www2.econ.univpm.it/servizi/hpp/lucchetti


       
      • Sebastian Bayer

        Sebastian Bayer - 2015-04-11

        Exactly - I like the font of verbatim and it is much easier and quicker to include.

         
  • Sven S.

    Sven S. - 2015-07-08
    • status: open --> closed
     
  • Sven S.

    Sven S. - 2015-07-08

    Again, could have closed this some time ago; AFAICS the solution is to use gretl's TeX output, and if you insist on using the other text output, well then you're on your own (with Jack's TeX solution).

     

Log in to post a comment.