> Date: Wed, 15 Nov 2000 19:53:45 +0010
> Subject: Re: constant kinds
> From: [log in to unmask]
> To: [log in to unmask]
> Reply-to: [log in to unmask]
> I agree up to here.
>
> >Use of "real" etc is redundant, unnecessary, superfluous, and not needed.
>
> Use of REAL() with an integer argument is sometimes necessary and often makes
> the intent of the code more discernible.
Indeed. My comments related to the use of REAL in the context of
the email, namely in expressing a real constant.
> There was a thread here or over in the other place (C.L.F) a short while ago,
> but part of it concerned something like (K-1)/(K+1). As the RHS, either the
> numerator or denominater needs to be made real to make the whole RHS real.
> O.K., one of the components might be first assigned to a temporary REAL
> variable, but to my mind that makes the formulation even less readable.
>
> The intent for me reads better if I say:
>
> x = REAL(K-1)/REAL(K+1)
>
> not
>
> temp = K-1 ! temp is a REAL variable
> x = temp/(K+1)
>
> or even worse (to me)
>
> temp1 = k-1 ! real variable
> temp2 = k+1 ! another real variable
> x = temp1/temp2
>
> Regards, Paddy
>
> Paddy O'Brien,
> Transmission Development,
> TransGrid,
> PO Box A1000, Sydney South,
> NSW 2000, Australia
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|