Drexel dragonThe Math ForumDonate to the Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.

Math Forum » Discussions » Software » comp.soft-sys.math.mathematica

Topic: Function & Format (2)
Replies: 0  

Advanced Search

Back to Topic List Back to Topic List  
F Renard

Posts: 10
Registered: 12/7/04
Function & Format (2)
Posted: Oct 30, 1996 12:22 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Thanks for your answer (See included message below),
but I'm afraid it's not exactly what I want:

I want the function fun to RETURN, say x^2, but PRINT "-FUN-".
It's like Graphics, that PRINTS "-Graphics-", but RETURNS a more
complicated object, that it's possible to re-use for any other problem:

In[1]:= g = Graphics[...]

Out[1]= -Graphics-

In[2]:= Show[%]

Out[2]= -Graphics-

It's like the difference between InputForm and OutputForm...

Francois RENARD

------Beginning Included Message----------------------------------------

The function to solve your problem seems to be simple:

fun[x_]:= ( x^2 >>> "abc"; (* This appends the result x^2 to your
(existing) file abc.
(Example for your action)
"-FUN-" (* Alternative: Print["-FUN-"]


I hope, it helps

G. Lamprecht

------End Included Message----------------------------------------

Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum 1994-2015. All Rights Reserved.