Skip to main content

2 replies

25-Diamond I
September 1, 2018

It not clear what you'd like to achieve.

You should more clearly show what the result you are looking for should look like.

Your screenshot does not show the value of a, I guess its 3 (or less). So you sure should attach your worksheet - maybe not the full one but just a modified sheet to demonstrate what you are after.

Do you just want to extract the 3 non-zero rows? But your program suggest you are just interested to up to the 3a-1 column, not the full rows!?

If your goal is to extract just the non-zero rows you may try a combination of "match" and "trim".

 

1-Visitor
September 1, 2018

I WANT TO EXTRACT THE DATA FOR SPECIFIC ROWS WHICH INCLUDE 0,2..N-1 

FIRST MATRIX phi1 ==== EXTRACT THE DATA FOR ROWS WHICH INCLUDE 0,3..N-1 

SECOND MATRIX  phi2==== EXTRACT THE DATA FOR ROWS WHICH INCLUDE 1,4..N-1 

SECOND MATRIX  phi3==== EXTRACT THE DATA FOR ROWS WHICH INCLUDE 2,5..N-1 

 

SINCE N=3*A , AND ALL CELL  NOT EQUAL ZERO Capture.JPG

15-Moonstone
September 1, 2018

I am not sure waht you try to accomplish.  Use the submatrix function to extract a specific rows and columns

21-Topaz II
September 2, 2018

Hi,

 

You just need to add subscripts to phix in the program.   i/3 and j

 

Capture.JPG

25-Diamond I
September 2, 2018

@terryhendicott wrote:

Hi,

 

You just need to add subscripts to phix in the program.   i/3 and j

 

 


Better use trunc(i/3)  (and it should be Phi[i,j and not Phi[i[j).

 

What confuses me in the original screenshot provided by mostafaelhodiry is that his program returns 0 as value.

The value of a seems to be a=3 (he wrote n=3*a and n seems to be the number of rows in his matrix which is 9).

So the last value assigned to Phix is Phi[8,8 and this value would be returned. But Phi[8,8 is -0,185 and not 0 !?

So unless he is using a strange number format (Decimal with 0 as Decimal Precision) for the output  ... ???