Created
February 23, 2012 12:14
-
-
Save BillFoster/1892601 to your computer and use it in GitHub Desktop.
problems with subarrays
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
variables: { | |
j:"random(0..6)" | |
t6: "[6,1,[[3,2]],[[7,14],[9,18],[0]]]" | |
t10: "[10,1,[0],[[11,22],[0],[0]]]" | |
t12:"[12,1,[0],[[13,26],[0],t6]]" | |
t18:"[18,1,[[3,3]],[[19,38],[27,54],[0]]]" | |
t20:"[20,0,[[5,2]],[[0],[25,50],t10]]" | |
t22:"[22,1,[0],[[23,46],[0],[0]]]" | |
t28:"[28,1,[0],[[29,58],[0],[0]]]" | |
t:"[t6,t10,t12,t18,t20,t22,t28]" | |
si:"t[j]" | |
m:"t[j][0]" | |
m1:"m/2" | |
primess:"if(si[1]=1,'Since $\var{m}+1=\var{m+1}$ is a prime number we have solutions, $n=\var{m+1}$ and $n=2\times \var{m+1}=\var{2*(m+1)}$. Next we look to see if $\var{m}$ is a value in the table.', | |
'Since $\var{m}+1=\var{m+1}$ is not a prime number we next look to see if $\var{m}$ is a value in the table.')" | |
valmess:"if(si[2][0]=0,'Looking at the table we see that there is no value in the table such that $ \phi(\var{si[2][0][0]}^{\var{si[2][0][1]}})=\var{m}$','Looking at the table we see that $ \phi(\var{si[2][0][0]}^{\var{si[2][0][1]}})=\var{m}$. | |
Hence we have $n=\var{si[2][0][0]^si[2][0][1]}$ and $n=\var{2*si[2][0][0]^si[2][0][1]}$ are solutions.')" | |
factmess:"if(abs(si[3][2])=1,'The factorization $\var{m} = 2 \times \var{m1}$ does not lead to any other solutions as $\var{m1}$ is odd',1)" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment