I've been puzzling over how to get a certain function working in Python. The
function, takes positive integers to other positive integers as follows:
Phi_m(n2) = Phi_m(m*n + r) = m*x[n1] + r*(x[n1 + 1] - x[n1])
The above terms are all integer valued and are defined as follows:
n2 = the
On 18 July 2013 00:58, CTSB01 wrote:
> Please let me know if this is unclear. I will certainly continue revising
> until it makes sense to those reading.
Can you summarize what your question is? Leave aside the details of
the function, just explain what thing in particular you aren't able
to do
On Thursday, July 18, 2013 5:12:08 AM UTC-4, Joshua Landau wrote:
> On 18 July 2013 00:58, CTSB01 wrote:
>
> > Please let me know if this is unclear. I will certainly continue revising
> > until it makes sense to those reading.
>
>
>
> Can you summarize what your question is? Leave aside the
On 07/18/2013 02:57 PM, CTSB01 wrote:
On Thursday, July 18, 2013 5:12:08 AM UTC-4, Joshua Landau wrote:
On 18 July 2013 00:58, CTSB01 wrote:
Please let me know if this is unclear. I will certainly continue revising
until it makes sense to those reading.
Can you summarize what your questi
On Thursday, July 18, 2013 6:12:52 PM UTC-4, Gary Herron wrote:
> On 07/18/2013 02:57 PM, CTSB01 wrote:
>
> > On Thursday, July 18, 2013 5:12:08 AM UTC-4, Joshua Landau wrote:
>
> >> On 18 July 2013 00:58, CTSB01 wrote:
>
> >>
>
> >>> Please let me know if this is unclear. I will certainly co
On Jul 18, 2013 4:23 PM, "CTSB01" wrote:
>
> File "", line 2
> ... rtn = []
> ^
The "..." is the continuation prompt from the interactive interpreter, not
part of the code. Don't paste it into Python.
--
http://mail.python.org/mailman/listinfo/python-list
On Thursday, July 18, 2013 6:49:03 PM UTC-4, Ian wrote:
> On Jul 18, 2013 4:23 PM, "CTSB01" wrote:
>
> >
>
> > File "", line 2
>
> > ... rtn = []
>
> > ^
>
> The "..." is the continuation prompt from the interactive interpreter, not
> part of the code. Don't paste it into Python.
On Thu, Jul 18, 2013 at 5:04 PM, CTSB01 wrote:
> Thanks Ian. That worked regarding that issue. Now I have an 'invalid
> syntax' issue unfortunately.
>
>>> def phi_m(x,m):
> rtn = []
> for n2 in range(0, len(x)*m - 2):
> n = n2 / m
> r = n2 - n * m
> rtn.appen
On Thu, Jul 18, 2013 at 5:42 PM, Ian Kelly wrote:
> On Thu, Jul 18, 2013 at 5:04 PM, CTSB01 wrote:
>> Thanks Ian. That worked regarding that issue. Now I have an 'invalid
>> syntax' issue unfortunately.
>>
def phi_m(x,m):
>> rtn = []
>> for n2 in range(0, len(x)*m - 2):
>>
On Fri, 19 Jul 2013 00:04:33 +0100, CTSB01
wrote:
On Thursday, July 18, 2013 6:49:03 PM UTC-4, Ian wrote:
On Jul 18, 2013 4:23 PM, "CTSB01" wrote:
>
> File "", line 2
> ... rtn = []
> ^
The "..." is the continuation prompt from the interactive interpreter,
not part of the
On 07/18/2013 07:04 PM, CTSB01 wrote:
On Thursday, July 18, 2013 6:49:03 PM UTC-4, Ian wrote:
On Jul 18, 2013 4:23 PM, "CTSB01" wrote:
File "", line 2
... rtn = []
^
The "..." is the continuation prompt from the interactive interpreter, not part
of the code. Don't
On Thursday, July 18, 2013 7:45:49 PM UTC-4, Ian wrote:
> On Thu, Jul 18, 2013 at 5:42 PM, Ian Kelly wrote:
>
> > On Thu, Jul 18, 2013 at 5:04 PM, CTSB01 wrote:
>
> >> Thanks Ian. That worked regarding that issue. Now I have an 'invalid
> >> syntax' issue unfortunately.
>
> >>
>
> def
> It's only obvious if you're using Python 3.x. You have forgotten the
>
> parentheses in the call to the print() function.
>
>
> On the other hand, if this is Python 2.x, I have no idea. Next time,
>
> please paste the actual error, not paraphrased. The error message
>
> includes a tra
On 07/18/2013 08:35 PM, CTSB01 wrote:
> It's only obvious if you're using Python 3.x. You have forgotten the
parentheses in the call to the print() function.
On the other hand, if this is Python 2.x, I have no idea. Next time,
please paste the actual error, not paraphrased. The error me
Thanks for the alternative links, I'll use gmane.org as an access point next
time.
>
> Don't paraphrase. Just copy/paste it into your email message. And I'm
>
> assuming you know to run things from the terminal window, and not from
>
> IDLE or something else that messes up the error messag
On 07/18/2013 10:16 PM, CTSB01 wrote:
Does something like
def phi_m(x, m):
rtn = []
for n2 in range(0, len(x) * m - 2):
n = n2 / m
r = n2 - n * m
rtn.append(m * x[n] + r * (x[n + 1] - x[n]))
print ('n2 =', n2, ': n ='
On 19 Jul 2013 03:24, "CTSB01" wrote:
>
> Thanks for the alternative links, I'll use gmane.org as an access point
next time.
>
> >
> > Don't paraphrase. Just copy/paste it into your email message. And I'm
> >
> > assuming you know to run things from the terminal window, and not from
> >
> > IDLE
On Thursday, July 18, 2013 10:48:23 PM UTC-4, Fábio Santos wrote:
> On 19 Jul 2013 03:24, "CTSB01" wrote:
>
> >
>
> > Thanks for the alternative links, I'll use gmane.org as an access point
> > next time.
>
> >
>
> > >
>
> > > Don't paraphrase. Just copy/paste it into your email message. A
On Thursday, July 18, 2013 10:43:11 PM UTC-4, Dave Angel wrote:
> On 07/18/2013 10:16 PM, CTSB01 wrote:
> > Does something like
>
> >
>
> > def phi_m(x, m):
>
> >rtn = []
>
> >for n2 in range(0, len(x) * m - 2):
>
> > n = n2 / m
>
> > r = n2
19 matches
Mail list logo