abc/src/bdd/cudd/cuddApa.c
/**Function********************************************************************

  Synopsis [Shifts right an arbitrary precision integer by one binary
  place.]

  Description [Shifts right an arbitrary precision integer by one
  binary place. The most significant binary digit of the result is
  taken from parameter <code>in</code>.]

  SideEffects [The result is returned in parameter <code>b</code>.]

  SeeAlso     []

******************************************************************************/
Function
Synopsis [Shifts right an arbitrary precision integer by one binary
place.]

Description [Shifts right an arbitrary precision integer by one
binary place. The most significant binary digit of the result is
taken from parameter in.]

SideEffects [The result is returned in parameter b.]


Function Synopsis [ Shifts right an arbitrary precision integer by one binary place . ] Description [ Shifts right an arbitrary precision integer by one binary place . The most significant binary digit of the result is taken from parameter in . ] SideEffects [ The result is returned in parameter b . ]
void
Cudd_ApaShiftRight(
  int  digits,
  DdApaDigit  in,
  DdApaNumber  a,
  DdApaNumber  b)
{
    int i;
    for (i = digits - 1; i > 0; i--) {
        b[i] = (a[i] >> 1) | ((a[i-1] & 1) << (DD_APA_BITS - 1));
    }
    b[0] = (a[0] >> 1) | (in << (DD_APA_BITS - 1));
}
void Cudd_ApaShiftRight ( int digits , DdApaDigit in , DdApaNumber a , DdApaNumber b ) { int i ; for ( i = digits - 1 ; i > 0 ; i -- ) { b [ i ] = ( a [ i ] >> 1 ) | ( ( a [ i - 1 ] & 1 ) << ( DD_APA_BITS - 1 ) ) ; } b [ 0 ] = ( a [ 0 ] >> 1 ) | ( in << ( DD_APA_BITS - 1 ) ) ; }
Function
Synopsis [Shifts right an arbitrary precision integer by one binary
place.]
Function Synopsis [ Shifts right an arbitrary precision integer by one binary place . ]