Skip to main content
1-Visitor
February 7, 2013
Question

Inserting the Matrices using if function

  • February 7, 2013
  • 1 reply
  • 765 views

Hello Friends,

I am facing a problem for putting a IF function for a matrics

a=(1

2

3

-5

10)

Thats a is in matrics format.

WL=3

if function reqired that

h= if a>WL then WL

else if a<0 then 0

else WL

Now i am not getting the solution due to "a" is in matrics format and WL is a scalar format

and i want "h" also as matrics format.

Expected answer of h=(1

2

3

0

3) But i want to know how to write the programm for that

1 reply

25-Diamond I
February 7, 2013