Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2006
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2006

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

Search the Archive

Re: Lists and polynomials

  • To: mathgroup at smc.vnet.net
  • Subject: [mg71047] Re: [mg71023] Lists and polynomials
  • From: Bob Hanlon <hanlonr at cox.net>
  • Date: Mon, 6 Nov 2006 02:52:58 -0500 (EST)
  • Reply-to: hanlonr at cox.net

IntegerDigits[1027, 2^10]

{1,3}

FromDigits[%, 2^10]

1027

IntegerDigits[6718213, 2^10]

{6,416,773}

FromDigits[%, 2^10]

6718213


Bob Hanlon

---- aland <alandix at yahoo.com> wrote: 
> Hi All,
> Another beginner here!
> I am trying to create a list based around a polynomial.
> In particular, I want to work with a large-ish number based on a power
> of 2
> e.g.
> 629 x^2  + 863 x + 271
> where x = 2^10
> What I want to do is take a number y such as y=6718213 and derive a
> list where the list values are the coefficients of the polynomial.
> So that if my number y=1027 (2^10 +3)
> the polynomial would be
> x+3
> and the list would be { 1,3 }
> 
> I have tried NestWhileList[] and PolynomialRemainder[]  but I'm really
> struggling to get them to do what I want.  I have a procedural
> programming background; functional programming looks excellent, I just
> can't get it to work!
> 
> Any suggestions (like you're using the wrong functions, try these
> others....) would be gratefully received.
> 
> I'm also looking to convert the list back into a number once I've
> finished working with the polynomial.
> 
> Mathematica v4.2, although it probably doesn't make a lot of
> difference.
> 
> Thanks in advance,
> 
> Alan
> 

--

Bob Hanlon
hanlonr at cox.net



  • Prev by Date: Re: Re: Wolfram Workbench
  • Next by Date: Re: Workbench: get nb's into a project & compare them
  • Previous by thread: Re: Lists and polynomials
  • Next by thread: Re: Lists and polynomials