Re: Machine-size real number?
- To: mathgroup at smc.vnet.net
- Subject: [mg33153] Re: Machine-size real number?
- From: Jens-Peer Kuska <kuska at informatik.uni-leipzig.de>
- Date: Wed, 6 Mar 2002 01:55:27 -0500 (EST)
- Organization: Universitaet Leipzig
- References: <a61uom$gom$1@smc.vnet.net>
- Reply-to: kuska at informatik.uni-leipzig.de
- Sender: owner-wri-mathgroup at wolfram.com
Hi,
function calls are written with [] in Mathematica and
only
f[x_] := 1 - (Cos[\[ExponentialE]^(3x/4)])
is correct.
Second functions should have *arguments* f is a symbol, f[x] is
a function call, so, f[x] will work:
Plot[f[x], {x, a, b}]
Since Plot has the attribut HoldAll you should use
Plot[Evaluate[f[x], {x, a, b}]]
Regards
Jens
Mike O'Leary wrote:
>
> I'm trying to plot this function
>
> f[x_] := 1 - (Cos(\[ExponentialE]^(3x/4)))
> {a, b} = {-1, 1.5}
> Plot[f, {x, a, b}]
>
> and I keep getting an error that says f is not a machine-size real number at
> x = -1. Any help would be appreciated.