MathGroup Archive 2004

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Undiscovered Bug?


MathGroup:

Thanks to all for help with Part documentation ...

    "When expr is a list, expr[[{i1, i2, ... in ]] gives a list of
parts. In general, the head of expr is applied to the list of parts."

ReplacePart's behavior, however, produces a different result ...

    Recall, we had for Part ...

    In[5]:= (x/y)[[{2, 1, 1, 0, 2, 2, 0}]]

                 2  2
            Times  x
    Out[5]= ---------
                3
               y

    But, we have for ReplacePart ...

    In[1]:= ReplacePart[(x/y), a, {2, 1, 1, 0, 2, 2, 0}]

                                                      x
    ReplacePart::partw: Part {2, 1, 1, 0, 2, 2, 0} of - does not
exist.
                                                      y

Maybe I'm still missing something, but it seems to me Part should be
revised to detect the same errors as ReplacePart.

Regards,
Harold


  • Prev by Date: nonlinear pde system
  • Next by Date: Re: Re: Re: Creating a symmetric matrix
  • Previous by thread: RE: Undiscovered Bug?
  • Next by thread: Re: Re: Undiscovered Bug?