Services & Resources / Wolfram Forums
MathGroup Archive
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2005

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Re: Asking questions

  • To: mathgroup at
  • Subject: [mg58280] Re: Re: Asking questions
  • From: Bharat Bhole <bbhole at>
  • Date: Sat, 25 Jun 2005 01:56:46 -0400 (EDT)
  • References: <> <> <>
  • Reply-to: Bharat Bhole <bbhole at>
  • Sender: owner-wri-mathgroup at

Thanks to Everyone for your help. I really appreciate it. Unfortunately,
because I am novice as far as Mathematica Programming is concerned I am not
familiar with Functional Programming. I have a question about the following
statement which most of you have sent
((Print[#]; #)&@f[#]) & /@ Range[10]
 Where do I type it? Do I type it just after the MapThread command and
exactly as you have given it.
 You do not need to answer me just yet. I will try doing this and the
Procedural hint given by Andrzej Kozlowski. Although he has given the hint
for the "Do command" I will try to apply the same for MapThread.
I have not got a chance to try this out yet.
 Again, thanks very much for your input. I really appreciate it.

 On 6/24/05, stephen layland <layland at> wrote:
> and thus spake Bharat Bhole [2005.06.24 @ 02:30]:
> >
> > Suppose I am running a code
> > MapThread[func,{Table[d,{d,1,10}]] which takes very long to evaluate for
> the
> > entire list. Mathematica gives me the output ONLY after 'func[d]' has
> been
> > evaluated for all d from 1 to 10.
> That's because the kernel is only doing what you tell it to do. The
> matheamtica kernel is single threaded. You will only 'get a result'
> when the entire function has been evaluated.
> > Is it possible to make Mathematica give
> > the output as it is evaluating after each d. For example, is it possible
> to
> > make it give output after it has evaluated func[1], then func[2] and so
> on.
> > Thank you for your help.
> You can get the kernel to Print[] the results as it maps like:
> ((Print[#]; #)&@f[#]) & /@ Range[10]
> but this still won't allow you to use the results in the kernel until
> the entire Map call has ended.
> (unless, of course, you use another mathematica kernel).
> --
> /*------------------------------*\
> | stephen layland |
> | Documentation Programmer |
> | |
> \*------------------------------*/

  • Prev by Date: Re: Documentation
  • Next by Date: Solve yields unreal solutions, NSolve yields real solutions
  • Previous by thread: Re: Re: Asking questions
  • Next by thread: Re: Re: Asking questions