Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #15594 > unrolled thread

Re: Help with Delete cases

Started byChris Degnen <degnen@cwgsy.net>
First post2011-02-08 10:08 +0000
Last post2011-02-08 10:08 +0000
Articles 1 — 1 participant

Back to article view | Back to comp.soft-sys.math.mathematica

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: Help with Delete cases Chris Degnen <degnen@cwgsy.net> - 2011-02-08 10:08 +0000

#15594 — Re: Help with Delete cases

FromChris Degnen <degnen@cwgsy.net>
Date2011-02-08 10:08 +0000
SubjectRe: Help with Delete cases
Message-ID<iir4m2$6p2$1@smc.vnet.net>
On Feb 7, 11:05 am, KenR <ramsey2...@msn.com> wrote:
> I have a list= Range[3003]  I want to delete cases of n = m(m+1) mod P
> from the list, but Delete cases only deletes cases matching a pattern,
> i.e.
>
> list = DeleteCases[list,Mod[N - m(m+1)/2,P] = 0] will definitely not
> work.  I want to keep list, as the same identifier, throughout since
> this is within a looping process. Any suggestions?


You can use something of this form:

DeleteCases[Range[10], _?((# + 1)/2 == 4 &)]

or use Select:

Select[Range[10], (# + 1)/2 != 4 &]

[toc] | [standalone]


Back to top | Article view | comp.soft-sys.math.mathematica


csiph-web