Ask your own question, for FREE!
Mathematics 18 Online
OpenStudy (anonymous):

Conway series, can someone explain the formula?

OpenStudy (anonymous):

a(1)=a(2)=1, a(n) = a(a(n-1)) + a(n-a(n-1)) for n>2.

OpenStudy (anonymous):

I have two version of the program: 1)conway:=proc(n) description`Conway with remember table`: option remember: if n=1 then return 1; elif n=2 then return 1; else return conway(a(a[n-1]))+conway(a(n-a[n-1])); end if; end proc;

OpenStudy (anonymous):

2)conway2:=proc(n) local A,k; A[1],A[2]:=1,1; for k from 3 to n do A[n]:=A[A[k-1]]+A[k-A[k-1]]; end do; return A; end proc;

OpenStudy (anonymous):

both are not returing the sequence

OpenStudy (anonymous):

what is the deal with the conway series? can somone explain the formula?

OpenStudy (anonymous):

man, i just read this paper on recursive programing and i think this might be more subtle than i thought

OpenStudy (anonymous):

but give me your thoughts on it

OpenStudy (anonymous):

i might just be missing somehting obvious

OpenStudy (anonymous):

I think it's this \[\huge a _{n} = a _{a _{n-1}} + a _{n-a _{n-1}}\]

OpenStudy (anonymous):

yeah, that what i am thinking, thats why i put in maple a[a[n-1]], the brackets are suppose to denote subscripts

OpenStudy (anonymous):

you supposed to be implementing recursively?

OpenStudy (anonymous):

i guess so, its not explicetly mentioned in the problem(the problem only says go to internet and search conway, then right a program on it), but upon googling conway series it says that its a recursive formula

OpenStudy (anonymous):

sec

OpenStudy (anonymous):

so what site are you looking at?

OpenStudy (anonymous):

http://www.skrause.org/math/conway.shtml

OpenStudy (anonymous):

thats basically it on info about conway, there are someothers like wolfram that has info on conway series, but its all the same

OpenStudy (anonymous):

we should click your own link a bunch of times and then you should ask the question: "Does anyone know any know of any good links with info about the Conway Series?? plz hapl"

OpenStudy (anonymous):

eventually, due to recursion, we'll get a good link with all the info we need.

OpenStudy (anonymous):

you sent me back to my own problem, your a genius :)

OpenStudy (anonymous):

i might have found something broski, let me try it

OpenStudy (anonymous):

stand back everybody summoning the math gods... @UnkleRhaukus @experimentX @estudier @ganeshie8 @ByteMe @algebraic!

OpenStudy (anonymous):

I summoned myself only for the sake of recursion.

OpenStudy (anonymous):

like i am using this program: conway:=proc(n) description`Conway with remember table`: option remember: if n=1 then return 1; elif n=2 then return 1; else return A(A(n-1))+A(n-A(n-1)); end if; end proc; but when i input in maple i get this: conway(1); 1 conway(2); 1 conway(3); A(A(2)) + A(3 - A(2))

OpenStudy (anonymous):

hmm yeah, maple probably has some special notation for terms in a series with sub scripts

OpenStudy (anonymous):

that's not "A[ ] "

OpenStudy (anonymous):

now i changed it to:A[A(n-1)]+A[n-A(n-1)]; and got: conway(3); A[A(2)] + A[3 - A(2)]

OpenStudy (experimentx):

what are you trying to get?

OpenStudy (anonymous):

yeah I don't think " A[ ]" is going to do it... we need something like:

OpenStudy (anonymous):

i am trying output the conway series

OpenStudy (anonymous):

he's trying to find a recursion relation for the conway series so he can implement in Maple

OpenStudy (experimentx):

Error, unable to match delimiters could you edit the program?

OpenStudy (experimentx):

I find it easy to program in Matlab.

OpenStudy (anonymous):

Need something like \[\huge Conway _{n} = Conway _{Conway _{n-1}} +Conway _{n-Conway _{n-1}}\]

OpenStudy (anonymous):

wow that totally worked

OpenStudy (anonymous):

\[ Conway _{n} = Conway _{Conway _{n-1}} +Conway _{n-Conway _{n-1}}\]

OpenStudy (anonymous):

\[\huge Conway _{n} = Conway _{Conway _{n-1}} \] \[\huge +Conway _{n-Conway _{n-1}}\]

OpenStudy (anonymous):

check this out, its different versions of what i have tried:

OpenStudy (anonymous):

see what I'm saying?

OpenStudy (anonymous):

if you can find the syntax in Maple for 'series terms with subcripts' it would make it easier...

OpenStudy (anonymous):

did you see the first part of that pdf i sent you

OpenStudy (unklerhaukus):

i have made a matlab code that seems working

OpenStudy (anonymous):

please post it, thank you

OpenStudy (anonymous):

the thing with mine, is that it gives me the subscripts but it doesnt want to evauate or give me the value of that term, if i could figure out how to do that, it would work

OpenStudy (unklerhaukus):

% conway % L=20; % lenght of series a=1:L; % set vector a a(1)=1; % initial value a(2)=1; % second value for n=3:L; a(n) = a(a(n-1)) + a(n-a(n-1)); % other values end a % dipsplay

OpenStudy (unklerhaukus):

>> conway a = Columns 1 through 20 1 1 2 2 3 4 4 4 5 6 7 7 8 8 8 8 9 10 11 12

OpenStudy (anonymous):

yeah so, find out the Maple syntax for terms in a series with sub scripts it's evidently not " A [ ]"

OpenStudy (anonymous):

yup thats the series

OpenStudy (anonymous):

To select members of a sequence, use index notation: s[i]refers to the ith element of the sequence s.

OpenStudy (anonymous):

or figure out how to write a Maple proc that opens matlab and executes that program and then returns the result, all the while pretending that it did the work... *whistles innocently* might help

OpenStudy (anonymous):

there ya go

OpenStudy (anonymous):

but isnt that notation what i have used in my program?

OpenStudy (anonymous):

I took it to mean you have to use 's' specifically... maybe A is some notation used for a matrix? I dunno...

OpenStudy (anonymous):

ah, part of the problem is that in your program I don't think you tell it that A[1] =1 and A[2] =1 ...?

OpenStudy (anonymous):

you just tell it what to return...

OpenStudy (anonymous):

@UnkleRhaukus in matlab is () suppose to denote a subscript?

OpenStudy (anonymous):

i do define a[1] and a[2]

OpenStudy (anonymous):

yeah

OpenStudy (anonymous):

ok, in the second program..? but you have the brackets wrong in that one...

OpenStudy (anonymous):

s[n] := s[s(n-1)]+s[n-s(n-1)] <---you mean here?

OpenStudy (anonymous):

can't copypasta from pdf but... in " conway2:= " you have the wrong brackets for some of the things that *should* be subscripts....

OpenStudy (anonymous):

I changed that and look what i got: seq(G[i],i=3..30); s[3], s[4], s[5], s[6], s[7], s[8], s[9], s[10], s[11], s[12], s[13], s[14], s[15], s[16], s[17], s[18], s[19], s[20], s[21], s[22], s[23], s[24], s[25], s[26], s[27], s[28], s[29], s[s[29]] + s[30 - s[29]]

OpenStudy (anonymous):

" A[A(n-1)] " try it with A[A[n-1]]

OpenStudy (anonymous):

whats the program is not doing is this: i defined the terms s[1] and s[2], they should both be 1, so when i plug in n=3 meaning i want the s[3] term, it should automatically say okay s[3-1] is s[2] and i know s[2] is =1 , so then it should use 1 and the subscript for the outer s

OpenStudy (unklerhaukus):

in matlab is () suppose to denote a subscript? Yes

OpenStudy (anonymous):

I'd try the exact code you have in conway2 , but with the right brackets... if that doesn't work... then, one problem down.

OpenStudy (anonymous):

I switched it to this:s[n]:= s[s[n-1]]+s[n-s[n-1]];

OpenStudy (anonymous):

ok

OpenStudy (anonymous):

with s[1] = s[2] =1 ?

OpenStudy (anonymous):

and it gave me this:seq(G[i],i=3..30); s[3], s[4], s[5], s[6], s[7], s[8], s[9], s[10], s[11], s[12], s[13], s[14], s[15], s[16], s[17], s[18], s[19], s[20], s[21], s[22], s[23], s[24], s[25], s[26], s[27], s[28], s[29], s[s[29]] + s[30 - s[29]]

OpenStudy (anonymous):

yup i said:s[1], s[2] := 1, 1

OpenStudy (anonymous):

try i=1..30 , looks like it's not including s[1], s[2]

OpenStudy (anonymous):

all it does is include 1,1 but the rest of them stayed the same

OpenStudy (anonymous):

seq(G[i]:=s[s[n-1]]+s[n-s[n-1]],i=1..30) ?

OpenStudy (anonymous):

dead end

OpenStudy (anonymous):

don't know... syntax thing.

OpenStudy (anonymous):

conway2 looks closest to me... I'd play with it.

OpenStudy (anonymous):

thanks for wokring with me, i'll try and keep working on it to see what happens

OpenStudy (anonymous):

So check out this link, scroll down to where it says Maple: http://oeis.org/A004001

OpenStudy (anonymous):

you wanna know somethin crazy, i just called Neil Sloane, the guy that wrote that page. Well he didnt answer but i left my number.

OpenStudy (anonymous):

anyway, can you believe that all i did was copy and paste that code into maple, and its acutally does return each indivdual conway term

OpenStudy (anonymous):

rfl

OpenStudy (anonymous):

but what i am trying to figure out is does A00400l have a deeper meaning in maple or is that just a name for soomething?

OpenStudy (anonymous):

"option remember" maybe you have to turn recursion on in maple. I like how the function name is a link to the page. just keep recurring.

OpenStudy (anonymous):

right, but in maple, does A004001 actually have a meaning or does it just name the program

OpenStudy (anonymous):

name it I think, it's a joke...I'm guessing.

OpenStudy (anonymous):

what does rfl stand for?

OpenStudy (anonymous):

like, "hey, if I click this link, it'll show me what the function is!"

OpenStudy (anonymous):

so, lets say that i edit my program and instead of A004001 i write conway, could it still work?

OpenStudy (anonymous):

Yeah, I think so.

OpenStudy (anonymous):

or maybe he just names his functions on each page after each page address. if they're* all recursive functions, that's kind of funny. when he calls back, ask him for me.

OpenStudy (anonymous):

yea i will, you know whats funny? is that his wife or daughter answers, and when i ask to speak to mister sloan, she is like" sure, can he call you back", really politely, she dosent even who is. I think i am not the first student to call him.

OpenStudy (anonymous):

she doesent even ask who it is *

OpenStudy (anonymous):

lol. sounds like a family with a sense of humor.

OpenStudy (anonymous):

now let me ask you, how does this program work?

OpenStudy (anonymous):

just like we've been doing all along, I guess the brackets don't matter... it's the same thing I wrote above. also I don't know what 'option remember' means in Maple, maybe that needs to be enabled so it can call a function inside itself (it remembers where it is in 'n')

OpenStudy (anonymous):

oh man, the program rembers the values of the conway(1) and conway(2)

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!