view test/octave.test/arith/pow2-2.m @ 3170:7050b5006ef9

[project @ 1998-04-23 06:29:49 by jwe]
author jwe
date Thu, 23 Apr 1998 06:29:55 +0000
parents
children
line wrap: on
line source

x = [3, 0, -3, 4, 0, -4, 5, 0, -5];
y = [-2, -2, -2, 1, 1, 1, 3, 3, 3];
z = x .* (2 .^ y);
all (abs (pow2 (x,y) - z) < sqrt (eps))