page
Sets or retrieves the page width or length.
Synopsis
#include <imsls.h>
void imsls_page (Imsls_page_options option, int *page_attribute)
Required Arguments
Imsls_page_options option (Input)
Option giving which page attribute is to be set or retrieved. Possible values are shown below.
Keyword
Description
IMSLS_SET_PAGE_WIDTH
Sets the page width.
IMSLS_GET_PAGE_WIDTH
Retrieves the page width.
IMSLS_SET_PAGE_LENGTH
Sets the page length.
IMSLS_GET_PAGE_LENGTH
Retrieves the page length.
int *page_attribute (Input, if the attribute is set; Output, otherwise.)
The value of the page attribute to be set or retrieved. The page width is the number of characters per line of output (default 78), and the page length is the number of lines of output per page (default 60). Ten or more characters per line and 10 or more lines per page are required.
Example
The following example illustrates the use of imsls_page to set the page width to 40 characters. Function imsls_f_write_matrix is then used to print a 3 × 4 matrix A, where aij = i + j/10.
 
#include <imsls.h>
 
#define NRA 3
#define NCA 4
int main()
{
int i, j, page_attribute;
float a[NRA][NCA];
 
for (i = 0; i < NRA; i++) {
for (j = 0; j < NCA; j++) {
a[i][j] = (i+1) + (j+1)/10.0;
}
}
page_attribute = 40;
imsls_page(IMSLS_SET_PAGE_WIDTH, &page_attribute);
imsls_f_write_matrix("a", NRA, NCA, (float *)a,
0);
}
Output
 
a
1 2 3
1 1.1 1.2 1.3
2 2.1 2.2 2.3
3 3.1 3.2 3.3
 
4
1 1.4
2 2.4
3 3.4