Intel® Fortran Libraries Reference

Intel® Fortran Libraries Reference Intel® Fortran Libraries Reference

h.eng.cam.ac.uk
from h.eng.cam.ac.uk More from this publisher
12.07.2015 Views

2 Intel Fortran Libraries ReferenceEND SUBROUTINEENDDRANSETDTIMEPortability Subroutine: Sets the seed for the random number generator.Module: USE IFPORTSyntaxCALL DRANSET (seed)seed(Input) REAL(8). The reset value for the seed.CompatibilityCONSOLE STANDARD GRAPHICS QUICKWIN GRAPHICS WINDOWS LIBSee Also: “RANGET”Portability Function: Returns the elapsed CPU time since the start of program execution whenfirst called, and the elapsed execution time since the last call to DTIME thereafter.Module: USE IFPORTSyntaxresult = DTIME (tarray)tarray(Output) REAL(4). A rank one array with two elements:• tarray(1) – Elapsed user time, which is time spent executing user code. This value includestime running protected Windows subsystem code.• tarray(2) – Elapsed system time, which is time spent executing privileged code (code in theWindows Executive).Results:The result type is REAL(4). The result is the total CPU time, which is the sum of tarray(1) andtarray(2). If an error occurs, –1 is returned.CompatibilityCONSOLE STANDARD GRAPHICS QUICKWIN GRAPHICS WINDOWS LIB2-72

Descriptions of the Library Routines 2See Also: the DATE_AND_TIME and CPU_TIME intrinsic procedures in the LanguageReferenceExampleUSE IFPORTREAL(4) I, TA(2)I = DTIME(TA)write(*,*) 'Program has been running for', I, 'seconds.'write(*,*) ' This includes', TA(1), 'seconds of user time and', && TA(2), 'seconds of system time.'ELLIPSE, ELLIPSE_WGraphics Functions: Draw a circle or an ellipse using the current graphics color. These functionsare only available on Windows* systems.Module: USE IFQWINSyntaxresult = ELLIPSE (control, x1, y1, x2, y2)result = ELLIPSE_W (control, wx1, wy1, wx2, wy2)control(Input) INTEGER(2). Fill flag. Can be one of the following symbolic constants:• $GFILLINTERIOR - Fills the figure using the current color and fill mask.• $GBORDER - Does not fill the figure.x1, y1(Input) INTEGER(2). Viewport coordinates for upper-left corner of bounding rectangle.x2, y2(Input) INTEGER(2). Viewport coordinates for lower-right corner of bounding rectangle.wx1, wy1(Input) REAL(8). Window coordinates for upper-left corner of bounding rectangle.wx2, wy2(Input) REAL(8). Window coordinates for lower-right corner of bounding rectangle.Results:The result type is INTEGER(2). The result is nonzero if successful; otherwise, 0. If the ellipse isclipped or partially out of bounds, the ellipse is considered successfully drawn, and the return is 1.If the ellipse is drawn completely out of bounds, the return is 0.2-73

2 Intel <strong>Fortran</strong> <strong>Libraries</strong> <strong>Reference</strong>END SUBROUTINEENDDRANSETDTIMEPortability Subroutine: Sets the seed for the random number generator.Module: USE IFPORTSyntaxCALL DRANSET (seed)seed(Input) REAL(8). The reset value for the seed.CompatibilityCONSOLE STANDARD GRAPHICS QUICKWIN GRAPHICS WINDOWS LIBSee Also: “RANGET”Portability Function: Returns the elapsed CPU time since the start of program execution whenfirst called, and the elapsed execution time since the last call to DTIME thereafter.Module: USE IFPORTSyntaxresult = DTIME (tarray)tarray(Output) REAL(4). A rank one array with two elements:• tarray(1) – Elapsed user time, which is time spent executing user code. This value includestime running protected Windows subsystem code.• tarray(2) – Elapsed system time, which is time spent executing privileged code (code in theWindows Executive).Results:The result type is REAL(4). The result is the total CPU time, which is the sum of tarray(1) andtarray(2). If an error occurs, –1 is returned.CompatibilityCONSOLE STANDARD GRAPHICS QUICKWIN GRAPHICS WINDOWS LIB2-72

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!