*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->IRIX man pages -> f90/compl (3)              
Title
Content
Arch
Section
 

Contents


COMPL(3I)					       Last changed: 1-6-98

NAME    [Toc]    [Back]

     COMPL - Computes complement

SYNOPSIS    [Toc]    [Back]

     COMPL ([I=]i)

IMPLEMENTATION    [Toc]    [Back]

     UNICOS, UNICOS/mk,	and IRIX systems

STANDARDS    [Toc]    [Back]

     CF90 and MIPSpro 7	Fortran	90 compiler extension to Fortran 90

DESCRIPTION    [Toc]    [Back]

     The COMPL intrinsic function computes the complement of i.	 It accepts
     the following argument:

     i	  A Boolean, integer, real, logical, or	Cray pointer value.

     COMPL is an elemental function.  The name of this intrinsic cannot	be
     passed as an argument.

     The following tables show both the	logical	complement and the bit-wise
     logical complement:

     ------------------------------------
     Logical	    COMPL
     Variable	    (Logical Variable)
     ------------------------------------
	   T		      F
	   F		      T
     ------------------------------------


     -----------------------------------
     Bit of	   COMPL
     Variable	   (Bit	of Variable)
     -----------------------------------
	  1		     0
	  0		     1
     -----------------------------------

NOTES    [Toc]    [Back]

     COMPL is outmoded.	 Refer to the Fortran Language Reference Manual,
     Volume 2, publication SR-3903, for	information about outmoded features
     and their preferred standard alternatives.

CAUTIONS    [Toc]    [Back]

     Unexpected	results	can occur when Boolean functions are declared
     external and then used with logical arguments.  On	UNICOS and
     UNICOS/mk systems,	the external Boolean functions always treat their
     arguments as type Boolean and return a Boolean result.  On	IRIX
     systems, the result is an integer.

RETURN VALUES    [Toc]    [Back]

     When given	an argument of type logical, COMPL computes a logical
     complement	and returns a logical result.

     On	UNICOS and UNICOS/mk systems, with an argument of type integer,
     real, Boolean, or Cray pointer, COMPL computes a bit-wise logical
     complement	and returns a Boolean result.  No type conversion occurs.

     On	IRIX systems, with an argument of type integer,	real, Boolean, or
     Cray Pointer, COMPL computes a bit-wise logical complement	and returns
     an	integer	result.

EXAMPLES    [Toc]    [Back]

     The following section of Fortran code shows the COMPL function used
     with an argument of type logical:

	  LOGICAL L1, L2
	  ...
	  L2 = COMPL(L1)

     The following section of Fortran code shows the COMPL function used
     with an argument of type integer.	The bit	patterns of the	argument
     and result	are also given.	 For clarity, only the rightmost 8 bits	are
     shown.

	  INTEGER I1, I2
	  I1 = 240
	  ...
	  I2 = COMPL(I1)


		 -------------------------------
		| 1 | 1	| 1 | 1	| 0 | 0	| 0 | 0	|
		 -------------------------------
			     I1

		 -------------------------------
		| 0 | 0	| 0 | 0	| 1 | 1	| 1 | 1	|
		 -------------------------------
			     I2

SEE ALSO    [Toc]    [Back]

      
      
     Intrinsic Procedures Reference Manual, publication	SR-2138, for the
     printed version of	this man page.

COMPL(3I)					       Last changed: 1-6-98

NAME    [Toc]    [Back]

     COMPL - Computes complement

SYNOPSIS    [Toc]    [Back]

     COMPL ([I=]i)

IMPLEMENTATION    [Toc]    [Back]

     UNICOS, UNICOS/mk,	and IRIX systems

STANDARDS    [Toc]    [Back]

     CF90 and MIPSpro 7	Fortran	90 compiler extension to Fortran 90

DESCRIPTION    [Toc]    [Back]

     The COMPL intrinsic function computes the complement of i.	 It accepts
     the following argument:

     i	  A Boolean, integer, real, logical, or	Cray pointer value.

     COMPL is an elemental function.  The name of this intrinsic cannot	be
     passed as an argument.

     The following tables show both the	logical	complement and the bit-wise
     logical complement:

     ------------------------------------
     Logical	    COMPL
     Variable	    (Logical Variable)
     ------------------------------------
	   T		      F
	   F		      T
     ------------------------------------


     -----------------------------------
     Bit of	   COMPL
     Variable	   (Bit	of Variable)
     -----------------------------------
	  1		     0
	  0		     1
     -----------------------------------

NOTES    [Toc]    [Back]

     COMPL is outmoded.	 Refer to the Fortran Language Reference Manual,
     Volume 2, publication SR-3903, for	information about outmoded features
     and their preferred standard alternatives.

CAUTIONS    [Toc]    [Back]

     Unexpected	results	can occur when Boolean functions are declared
     external and then used with logical arguments.  On	UNICOS and
     UNICOS/mk systems,	the external Boolean functions always treat their
     arguments as type Boolean and return a Boolean result.  On	IRIX
     systems, the result is an integer.

RETURN VALUES    [Toc]    [Back]

     When given	an argument of type logical, COMPL computes a logical
     complement	and returns a logical result.

     On	UNICOS and UNICOS/mk systems, with an argument of type integer,
     real, Boolean, or Cray pointer, COMPL computes a bit-wise logical
     complement	and returns a Boolean result.  No type conversion occurs.

     On	IRIX systems, with an argument of type integer,	real, Boolean, or
     Cray Pointer, COMPL computes a bit-wise logical complement	and returns
     an	integer	result.

EXAMPLES    [Toc]    [Back]

     The following section of Fortran code shows the COMPL function used
     with an argument of type logical:

	  LOGICAL L1, L2
	  ...
	  L2 = COMPL(L1)

     The following section of Fortran code shows the COMPL function used
     with an argument of type integer.	The bit	patterns of the	argument
     and result	are also given.	 For clarity, only the rightmost 8 bits	are
     shown.

	  INTEGER I1, I2
	  I1 = 240
	  ...
	  I2 = COMPL(I1)


		 -------------------------------
		| 1 | 1	| 1 | 1	| 0 | 0	| 0 | 0	|
		 -------------------------------
			     I1

		 -------------------------------
		| 0 | 0	| 0 | 0	| 1 | 1	| 1 | 1	|
		 -------------------------------
			     I2

SEE ALSO    [Toc]    [Back]

      
      
     Intrinsic Procedures Reference Manual, publication	SR-2138, for the
     printed version of	this man page.

[ Back ]
 Similar pages
Name OS Title
strcspn OpenBSD span the complement of a string
strcspn FreeBSD span the complement of a string
strcspn NetBSD span the complement of a string
cot IRIX Computes cotangent
poppar IRIX Computes bit population parity
eqv IRIX Computes logical equivalence
neqv IRIX Computes logical difference
blendfunction IRIX computes a blended color value for a pixel
div Tru64 Computes absolute value and division of integers
abs Tru64 Computes absolute value and division of integers
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service