| New Reply |
Fortran: Pointer to array section with vector subscripts |
Share Thread | Thread Tools |
| Mar10-11, 12:38 PM | #1 |
|
|
Fortran: Pointer to array section with vector subscripts
Hi. I'm trying to make a pointer point to sections of a rank-2 array given by specific values of
it's second index. I other words: given a table I wan't a pointer to point to specific columns, making of it a "filtered" table. The method I was trying was like Code:
DOUBLE PRECISION, DIMENSION(M,N), TARGET :: arrA DOUBLE PRECISION, DIMENSION(:,:), POINTER :: ptr1 ... ptr1 => arrA(1:k,(/col1,col3/)) However, I've been told in the Intel forum that this procedure would consist in targeting an array subsection with a vector subscript, which is forbiden in the standard by the constraint C724 of F2008. Is there any other way of doing this? I'm not using a scalar triplet on the second index because, in practice, I'll select more columns without a regular stride, so a rule like col1:colN:stride doesn't seem to be of use. Thanks. |
| Jul29-12, 03:08 PM | #2 |
|
|
I would like to resurrect this thread, I am interested in the answer. :-)
|
| New Reply |
| Thread Tools | |
Similar Threads for: Fortran: Pointer to array section with vector subscripts
|
||||
| Thread | Forum | Replies | ||
| Printing 1D array in Fortran as 2D array... | Programming & Comp Sci | 7 | ||
| FORTRAN: Allocating a pointer | Programming & Comp Sci | 2 | ||
| Vector question on component subscripts | Introductory Physics Homework | 3 | ||
| Subscripts and Fractions in Fortran 95 | Programming & Comp Sci | 2 | ||
| pointer/ array question.. | Programming & Comp Sci | 5 | ||