|
[Date Index]
[Thread Index]
[Author Index]
Re: variables versus functions
- To: mathgroup at smc.vnet.net
- Subject: [mg28803] Re: variables versus functions
- From: "Paul Lutus" <nospam at nosite.com>
- Date: Mon, 14 May 2001 01:32:55 -0400 (EDT)
- References: <9dld6m$o9g@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
"Julian Sweet" <jsweet at engineering.ucsb.edu> wrote in message
news:9dld6m$o9g at smc.vnet.net...
> How is it different to define a variable such as A=Cos[x]
> versus a function A[x_]:=Cos[x] ?
In the first case, x must be predefined:
a = Cos[x]
x = Pi
a
In the second, x doesn't have to be defined at all outside the function:
f[x_] := Cos[x]
f[Pi]
--
Paul Lutus
www.arachnoid.com
Prev by Date:
RE: Exponential Equations
Next by Date:
Re: Exponential Equations
Previous by thread:
variables versus functions
Next by thread:
Re: variables versus functions
|