public inbox for gsl-discuss@sourceware.org
 help / color / mirror / Atom feed
From: Brian Gough <bjg@network-theory.co.uk>
To: Fleur Kelpin <fleur@bio.vu.nl>
Cc: <gsl-discuss@sources.redhat.com>
Subject: Re: fprintf for blocks/vectors: why the \n?
Date: Wed, 19 Dec 2001 13:20:00 -0000	[thread overview]
Message-ID: <15383.58934.218222.495035@debian> (raw)
In-Reply-To: <Pine.GSO.4.33.0112121604530.18376-100000@monodon>

Fleur Kelpin writes:
 > If the automatic \n in block/fprintf_source.c were to go, people could
 > provide the format "%g\n" or "%g\t" or anything they like.

Hi,

That function is just intended as an ascii version of the binary write
function, for portability purposes.  Hence it dumps the list of
numbers to the stream without any structure.

 > The way things are now, I find I am writing my own for loops for printing,
 > whereas gsl tries to provide this functionality.

Yes, to actually display a vector or matrix you'll need to write your
own (little) display routine which prints them in your favorite
format.  Then you can call one of those routines whenever you need to
display a vector or matrix.

If somebody writes some good routines they can go into the library.
Ideally they should be able to display in all the standard formats
like Fortran, Octave, HTML, TeX, troff, etc using an argument to
select between them. 

regards

Brian

WARNING: multiple messages have this Message-ID
From: Brian Gough <bjg@network-theory.co.uk>
To: Fleur Kelpin <fleur@bio.vu.nl>
Cc: <gsl-discuss@sources.redhat.com>
Subject: Re: fprintf for blocks/vectors: why the \n?
Date: Wed, 05 Dec 2001 13:33:00 -0000	[thread overview]
Message-ID: <15383.58934.218222.495035@debian> (raw)
Message-ID: <20011205133300.VZEoYBNGZ0XysnkftSgU-NLsPHzHnA3Fa2b45oQkLkQ@z> (raw)
In-Reply-To: <Pine.GSO.4.33.0112121604530.18376-100000@monodon>

Fleur Kelpin writes:
 > If the automatic \n in block/fprintf_source.c were to go, people could
 > provide the format "%g\n" or "%g\t" or anything they like.

Hi,

That function is just intended as an ascii version of the binary write
function, for portability purposes.  Hence it dumps the list of
numbers to the stream without any structure.

 > The way things are now, I find I am writing my own for loops for printing,
 > whereas gsl tries to provide this functionality.

Yes, to actually display a vector or matrix you'll need to write your
own (little) display routine which prints them in your favorite
format.  Then you can call one of those routines whenever you need to
display a vector or matrix.

If somebody writes some good routines they can go into the library.
Ideally they should be able to display in all the standard formats
like Fortran, Octave, HTML, TeX, troff, etc using an argument to
select between them. 

regards

Brian

  parent reply	other threads:[~2001-12-12 23:52 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-12-19 13:20 Fleur Kelpin
2001-12-05 12:20 ` Fleur Kelpin
2001-12-19 13:20 ` Gerard Jungman
2001-12-05 12:20   ` Gerard Jungman
2001-12-19 13:20 ` Brian Gough [this message]
2001-12-05 13:33   ` Brian Gough

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=15383.58934.218222.495035@debian \
    --to=bjg@network-theory.co.uk \
    --cc=fleur@bio.vu.nl \
    --cc=gsl-discuss@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).