Re: x**2

From: Rene Brun (Rene.Brun@cern.ch)
Date: Fri May 30 1997 - 17:44:14 MEST


Otto Schaile wrote:
> 
> Dear roots,
> what do I wrong here:
>   *   Version   1.00/10     25 April 1997   *
> ....
> root [0] x2=new TFormula("x2","x**2")
> (class TFormula*)0x0
> root [1] xx2=new TF1("xx2","x2",400,1000)
> 
> *ERROR 5 :
>  Invalid Syntax "*"

The first statement using TFormula is OK. x**2 is recognized
as a valid expression by the Root formula compiler. Note that this is
illegal in C++. Use x^2 or x*x

The second statement using TF1 contains an illegal syntax.
What is "x2" ?
May be you meant x**2 or x^2 ?

Rene Brun



This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:26:19 MET