Csound Csound-dev Csound-tekno Search About

Re: [Cs-dev] array feature wish list (I)

Date2014-04-16 11:23
Fromjohn ffitch
SubjectRe: [Cs-dev] array feature wish list (I)
More after initial testing
Of Joachim's examples the following do not work

;;***    iArr[][] fillarray iArr1, iArr2
;;***   SArr1   slicearray SArr, 0, 4
;;***    copya2ftab giSine, giSine    <===== curious
;;8) minarray, maxarray, sumarray, scalearray not tested

All other lines parse and run

The first of these is in Steve's area.  The second is my area and I
will look at it.  Do not understand the third.  Must test the 8)
versions soon

Nearly time for breakfast

==John ffitch





instr 1
SArr[] fillarray "a", "b", "c"
;;b) not possible to have arrays as arguments, e.g.
    iArr1[] fillarray 1, 2, 3
    iArr2[] fillarray 4, 5, 6
;;***    iArr[][] fillarray iArr1, iArr2

;;2) lenarray
    Sarr[] init 3
    print lenarray(Sarr)

;;3) slicearray
   iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
   iArr1[] init       5
   iArr2[] init       4
iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
;;b) same for S-arrays:
   SArr[]  init       9
   SArr1[] init       5
;;***   SArr1   slicearray SArr, 0, 4

;;4) copyf2array
    giSine  ftgen   0, 0, 8, 10, 1
    iArr[]  init       8
    copyf2array iArr, giSine

;;5) copya2ftab
;;***    copya2ftab giSine, iArr

;;6) +, -, *, / between an array and a number
;;do not work at i-rate. this works:
    kArr1[] fillarray 1, 2, 3
    kArr2[] = kArr1 + 10
;;but this does not:
    iArr1[]  array 1, 2, 3
    iArr2[] = iArr1 + 10

;;7) +, -, *, / between two arrays
;;also missing for i. this works:
    kArr1[] fillarray 1, 2, 3
    kArr2[] fillarray 10, 20, 30
    kArr3[] = kArr1 + kArr2
;;but this does not:
    iArr1[] fillarray 1, 2, 3
    iArr2[] fillarray 10, 20, 30
    iArr3[] = iArr1 + iArr2

;;8) minarray, maxarray, sumarray, scalearray
;;do all miss i-time operations, as far as i see.

;;9) maparray
;;as well:
    iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
    iArrRes[] init  7
;;***    iArrRes maparray iArrSrc, "sqrt"

;;10) =
;;miss i-time operations. this is possible:
    kArr1[] fillarray 1, 2, 3
    kArr2[] = kArr1
;;but this returns "nul opadr":
    iArr1[] fillarray 1, 2, 3
   iArr2[] = iArr1

endin



i1 0 1
e




------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-16 18:49
Fromjoachim heintz
SubjectRe: [Cs-dev] array feature wish list (I)
i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).


i can confirm the three examples you mentioned are not working. the 
third example should read:
***    copya2ftab iArr, giSine
it was a typo in my initial list.


number 6) does not give an error, but the results are wrong:
     iArr1[]  fillarray 1, 2, 3
     iArr2[] = iArr1 + 10
     print iArr1[0], iArr1[1], iArr1[2]
     print iArr2[0], iArr2[1], iArr2[2]
returns:
instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
or sometimes something like:
instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
instr 1:  #i23 = 
7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000 
  #i24 = 
1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000 
  #i25 = 0.000


same for 7):
     iArr1[] fillarray 1, 2, 3
     iArr2[] fillarray 10, 20, 30
     iArr3[] = iArr1 + iArr2
     print iArr3[0], iArr3[1], iArr3[2]
-> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
or some astronomical high numbers.


8): maxarray and scalearray are working for i-arrays; minarray and 
sumarray not.
* minarray:
     iArr[] fillarray 1, 2, 3
     iMin minarray iArr
-> null opadr null opadr %s
* sumarray:
     iArr[] fillarray 1, 2, 3
     iMin sumarray iArr
-> error:  Unable to find opcode entry for 'sumarray' with matching 
argument types:
Found: i sumarray i[]


9) maparray is not working for me:
     iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
     iArrRes[] init  7
     iArrRes maparray iArrSrc, "sqrt"
-> error:  Unable to find opcode entry for 'maparray' with matching 
argument types:
Found: i[] maparray i[]S


10) yes this works now:
     iArr1[] fillarray 1, 2, 3
    iArr2[] = iArr1
great!


best -

	joachim


Am 16.04.2014 12:23, schrieb john ffitch:
> More after initial testing
> Of Joachim's examples the following do not work
>
> ;;***    iArr[][] fillarray iArr1, iArr2
> ;;***   SArr1   slicearray SArr, 0, 4
> ;;***    copya2ftab giSine, giSine    <===== curious
> ;;8) minarray, maxarray, sumarray, scalearray not tested
>
> All other lines parse and run
>
> The first of these is in Steve's area.  The second is my area and I
> will look at it.  Do not understand the third.  Must test the 8)
> versions soon
>
> Nearly time for breakfast
>
> ==John ffitch
>
> 
>
> 
>
> instr 1
> SArr[] fillarray "a", "b", "c"
> ;;b) not possible to have arrays as arguments, e.g.
>      iArr1[] fillarray 1, 2, 3
>      iArr2[] fillarray 4, 5, 6
> ;;***    iArr[][] fillarray iArr1, iArr2
>
> ;;2) lenarray
>      Sarr[] init 3
>      print lenarray(Sarr)
>
> ;;3) slicearray
>     iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>     iArr1[] init       5
>     iArr2[] init       4
> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
> ;;b) same for S-arrays:
>     SArr[]  init       9
>     SArr1[] init       5
> ;;***   SArr1   slicearray SArr, 0, 4
>
> ;;4) copyf2array
>      giSine  ftgen   0, 0, 8, 10, 1
>      iArr[]  init       8
>      copyf2array iArr, giSine
>
> ;;5) copya2ftab
> ;;***    copya2ftab giSine, iArr
>
> ;;6) +, -, *, / between an array and a number
> ;;do not work at i-rate. this works:
>      kArr1[] fillarray 1, 2, 3
>      kArr2[] = kArr1 + 10
> ;;but this does not:
>      iArr1[]  array 1, 2, 3
>      iArr2[] = iArr1 + 10
>
> ;;7) +, -, *, / between two arrays
> ;;also missing for i. this works:
>      kArr1[] fillarray 1, 2, 3
>      kArr2[] fillarray 10, 20, 30
>      kArr3[] = kArr1 + kArr2
> ;;but this does not:
>      iArr1[] fillarray 1, 2, 3
>      iArr2[] fillarray 10, 20, 30
>      iArr3[] = iArr1 + iArr2
>
> ;;8) minarray, maxarray, sumarray, scalearray
> ;;do all miss i-time operations, as far as i see.
>
> ;;9) maparray
> ;;as well:
>      iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>      iArrRes[] init  7
> ;;***    iArrRes maparray iArrSrc, "sqrt"
>
> ;;10) =
> ;;miss i-time operations. this is possible:
>      kArr1[] fillarray 1, 2, 3
>      kArr2[] = kArr1
> ;;but this returns "nul opadr":
>      iArr1[] fillarray 1, 2, 3
>     iArr2[] = iArr1
>
> endin
> 
>
> 
> i1 0 1
> e
> 
>
> 
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-16 19:30
Fromjpff@cs.bath.ac.uk
SubjectRe: [Cs-dev] array feature wish list (I)
AttachmentsNone  

Date2014-04-16 19:39
Fromjoachim heintz
SubjectRe: [Cs-dev] array feature wish list (I)
this is the commit:
commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
Author: John ffitch 
Date:   Wed Apr 16 11:06:25 2014 +0100

did you push after this?


Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
> bizarre -- I do not get those errors/problems.  When did you check it
> out/pull?
> There was a typo in i-array arithmetic, now fixed
>
> Quoting joachim heintz :
>
>> i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>
>>
>> i can confirm the three examples you mentioned are not working. the
>> third example should read:
>> ***    copya2ftab iArr, giSine
>> it was a typo in my initial list.
>>
>>
>> number 6) does not give an error, but the results are wrong:
>>       iArr1[]  fillarray 1, 2, 3
>>       iArr2[] = iArr1 + 10
>>       print iArr1[0], iArr1[1], iArr1[2]
>>       print iArr2[0], iArr2[1], iArr2[2]
>> returns:
>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>> or sometimes something like:
>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>> instr 1:  #i23 =
>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>    #i24 =
>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>    #i25 = 0.000
>>
>>
>> same for 7):
>>       iArr1[] fillarray 1, 2, 3
>>       iArr2[] fillarray 10, 20, 30
>>       iArr3[] = iArr1 + iArr2
>>       print iArr3[0], iArr3[1], iArr3[2]
>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>> or some astronomical high numbers.
>>
>>
>> 8): maxarray and scalearray are working for i-arrays; minarray and
>> sumarray not.
>> * minarray:
>>       iArr[] fillarray 1, 2, 3
>>       iMin minarray iArr
>> -> null opadr null opadr %s
>> * sumarray:
>>       iArr[] fillarray 1, 2, 3
>>       iMin sumarray iArr
>> -> error:  Unable to find opcode entry for 'sumarray' with matching
>> argument types:
>> Found: i sumarray i[]
>>
>>
>> 9) maparray is not working for me:
>>       iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>       iArrRes[] init  7
>>       iArrRes maparray iArrSrc, "sqrt"
>> -> error:  Unable to find opcode entry for 'maparray' with matching
>> argument types:
>> Found: i[] maparray i[]S
>>
>>
>> 10) yes this works now:
>>       iArr1[] fillarray 1, 2, 3
>>      iArr2[] = iArr1
>> great!
>>
>>
>> best -
>>
>> 	joachim
>>
>>
>> Am 16.04.2014 12:23, schrieb john ffitch:
>>> More after initial testing
>>> Of Joachim's examples the following do not work
>>>
>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>> ;;***   SArr1   slicearray SArr, 0, 4
>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>
>>> All other lines parse and run
>>>
>>> The first of these is in Steve's area.  The second is my area and I
>>> will look at it.  Do not understand the third.  Must test the 8)
>>> versions soon
>>>
>>> Nearly time for breakfast
>>>
>>> ==John ffitch
>>>
>>> 
>>>
>>> 
>>>
>>> instr 1
>>> SArr[] fillarray "a", "b", "c"
>>> ;;b) not possible to have arrays as arguments, e.g.
>>>       iArr1[] fillarray 1, 2, 3
>>>       iArr2[] fillarray 4, 5, 6
>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>
>>> ;;2) lenarray
>>>       Sarr[] init 3
>>>       print lenarray(Sarr)
>>>
>>> ;;3) slicearray
>>>      iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>      iArr1[] init       5
>>>      iArr2[] init       4
>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>> ;;b) same for S-arrays:
>>>      SArr[]  init       9
>>>      SArr1[] init       5
>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>
>>> ;;4) copyf2array
>>>       giSine  ftgen   0, 0, 8, 10, 1
>>>       iArr[]  init       8
>>>       copyf2array iArr, giSine
>>>
>>> ;;5) copya2ftab
>>> ;;***    copya2ftab giSine, iArr
>>>
>>> ;;6) +, -, *, / between an array and a number
>>> ;;do not work at i-rate. this works:
>>>       kArr1[] fillarray 1, 2, 3
>>>       kArr2[] = kArr1 + 10
>>> ;;but this does not:
>>>       iArr1[]  array 1, 2, 3
>>>       iArr2[] = iArr1 + 10
>>>
>>> ;;7) +, -, *, / between two arrays
>>> ;;also missing for i. this works:
>>>       kArr1[] fillarray 1, 2, 3
>>>       kArr2[] fillarray 10, 20, 30
>>>       kArr3[] = kArr1 + kArr2
>>> ;;but this does not:
>>>       iArr1[] fillarray 1, 2, 3
>>>       iArr2[] fillarray 10, 20, 30
>>>       iArr3[] = iArr1 + iArr2
>>>
>>> ;;8) minarray, maxarray, sumarray, scalearray
>>> ;;do all miss i-time operations, as far as i see.
>>>
>>> ;;9) maparray
>>> ;;as well:
>>>       iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>       iArrRes[] init  7
>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>
>>> ;;10) =
>>> ;;miss i-time operations. this is possible:
>>>       kArr1[] fillarray 1, 2, 3
>>>       kArr2[] = kArr1
>>> ;;but this returns "nul opadr":
>>>       iArr1[] fillarray 1, 2, 3
>>>      iArr2[] = iArr1
>>>
>>> endin
>>> 
>>>
>>> 
>>> i1 0 1
>>> e
>>> 
>>>
>>> 
>>>
>>> ------------------------------------------------------------------------------
>>> Learn Graph Databases - Download FREE O'Reilly Book
>>> "Graph Databases" is the definitive new guide to graph databases and their
>>> applications. Written by three acclaimed leaders in the field,
>>> this first edition is now available. Download your free book today!
>>> http://p.sf.net/sfu/NeoTech
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>
>>
>> ------------------------------------------------------------------------------
>> Learn Graph Databases - Download FREE O'Reilly Book
>> "Graph Databases" is the definitive new guide to graph databases and their
>> applications. Written by three acclaimed leaders in the field,
>> this first edition is now available. Download your free book today!
>> http://p.sf.net/sfu/NeoTech
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>
>
>
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-16 19:52
Fromjpff@cs.bath.ac.uk
SubjectRe: [Cs-dev] array feature wish list (I)
AttachmentsNone  

Date2014-04-16 20:18
Fromjoachim heintz
SubjectRe: [Cs-dev] array feature wish list (I)
now i got your commit. 6) is ok now, but 7) remains wrong. let me know 
when you want me to test something.

	joachim


Am 16.04.2014 20:52, schrieb jpff@cs.bath.ac.uk:
> Looks as if one of my commits failed.  Version of
> 2014-04-16 19:28:50
> should have many fixes -- no idea how that happened
>
> I *think* most string-array operations are broken but am not sure, or
> f how to check and fix.
>
> Quoting joachim heintz :
>
>> this is the commit:
>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>> Author: John ffitch 
>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>
>> did you push after this?
>>
>>
>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>> bizarre -- I do not get those errors/problems.  When did you check it
>>> out/pull?
>>> There was a typo in i-array arithmetic, now fixed
>>>
>>> Quoting joachim heintz :
>>>
>>>> i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>
>>>>
>>>> i can confirm the three examples you mentioned are not working. the
>>>> third example should read:
>>>> ***    copya2ftab iArr, giSine
>>>> it was a typo in my initial list.
>>>>
>>>>
>>>> number 6) does not give an error, but the results are wrong:
>>>>        iArr1[]  fillarray 1, 2, 3
>>>>        iArr2[] = iArr1 + 10
>>>>        print iArr1[0], iArr1[1], iArr1[2]
>>>>        print iArr2[0], iArr2[1], iArr2[2]
>>>> returns:
>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>> or sometimes something like:
>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>> instr 1:  #i23 =
>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>     #i24 =
>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>     #i25 = 0.000
>>>>
>>>>
>>>> same for 7):
>>>>        iArr1[] fillarray 1, 2, 3
>>>>        iArr2[] fillarray 10, 20, 30
>>>>        iArr3[] = iArr1 + iArr2
>>>>        print iArr3[0], iArr3[1], iArr3[2]
>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>> or some astronomical high numbers.
>>>>
>>>>
>>>> 8): maxarray and scalearray are working for i-arrays; minarray and
>>>> sumarray not.
>>>> * minarray:
>>>>        iArr[] fillarray 1, 2, 3
>>>>        iMin minarray iArr
>>>> -> null opadr null opadr %s
>>>> * sumarray:
>>>>        iArr[] fillarray 1, 2, 3
>>>>        iMin sumarray iArr
>>>> -> error:  Unable to find opcode entry for 'sumarray' with matching
>>>> argument types:
>>>> Found: i sumarray i[]
>>>>
>>>>
>>>> 9) maparray is not working for me:
>>>>        iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>        iArrRes[] init  7
>>>>        iArrRes maparray iArrSrc, "sqrt"
>>>> -> error:  Unable to find opcode entry for 'maparray' with matching
>>>> argument types:
>>>> Found: i[] maparray i[]S
>>>>
>>>>
>>>> 10) yes this works now:
>>>>        iArr1[] fillarray 1, 2, 3
>>>>       iArr2[] = iArr1
>>>> great!
>>>>
>>>>
>>>> best -
>>>>
>>>> 	joachim
>>>>
>>>>
>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>> More after initial testing
>>>>> Of Joachim's examples the following do not work
>>>>>
>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>
>>>>> All other lines parse and run
>>>>>
>>>>> The first of these is in Steve's area.  The second is my area and I
>>>>> will look at it.  Do not understand the third.  Must test the 8)
>>>>> versions soon
>>>>>
>>>>> Nearly time for breakfast
>>>>>
>>>>> ==John ffitch
>>>>>
>>>>> 
>>>>>
>>>>> 
>>>>>
>>>>> instr 1
>>>>> SArr[] fillarray "a", "b", "c"
>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>        iArr2[] fillarray 4, 5, 6
>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>
>>>>> ;;2) lenarray
>>>>>        Sarr[] init 3
>>>>>        print lenarray(Sarr)
>>>>>
>>>>> ;;3) slicearray
>>>>>       iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>       iArr1[] init       5
>>>>>       iArr2[] init       4
>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>> ;;b) same for S-arrays:
>>>>>       SArr[]  init       9
>>>>>       SArr1[] init       5
>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>
>>>>> ;;4) copyf2array
>>>>>        giSine  ftgen   0, 0, 8, 10, 1
>>>>>        iArr[]  init       8
>>>>>        copyf2array iArr, giSine
>>>>>
>>>>> ;;5) copya2ftab
>>>>> ;;***    copya2ftab giSine, iArr
>>>>>
>>>>> ;;6) +, -, *, / between an array and a number
>>>>> ;;do not work at i-rate. this works:
>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>        kArr2[] = kArr1 + 10
>>>>> ;;but this does not:
>>>>>        iArr1[]  array 1, 2, 3
>>>>>        iArr2[] = iArr1 + 10
>>>>>
>>>>> ;;7) +, -, *, / between two arrays
>>>>> ;;also missing for i. this works:
>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>        kArr2[] fillarray 10, 20, 30
>>>>>        kArr3[] = kArr1 + kArr2
>>>>> ;;but this does not:
>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>        iArr2[] fillarray 10, 20, 30
>>>>>        iArr3[] = iArr1 + iArr2
>>>>>
>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>
>>>>> ;;9) maparray
>>>>> ;;as well:
>>>>>        iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>        iArrRes[] init  7
>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>
>>>>> ;;10) =
>>>>> ;;miss i-time operations. this is possible:
>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>        kArr2[] = kArr1
>>>>> ;;but this returns "nul opadr":
>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>       iArr2[] = iArr1
>>>>>
>>>>> endin
>>>>> 
>>>>>
>>>>> 
>>>>> i1 0 1
>>>>> e
>>>>> 
>>>>>
>>>>> 
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>> applications. Written by three acclaimed leaders in the field,
>>>>> this first edition is now available. Download your free book today!
>>>>> http://p.sf.net/sfu/NeoTech
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>> applications. Written by three acclaimed leaders in the field,
>>>> this first edition is now available. Download your free book today!
>>>> http://p.sf.net/sfu/NeoTech
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>
>>>
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Learn Graph Databases - Download FREE O'Reilly Book
>>> "Graph Databases" is the definitive new guide to graph databases and their
>>> applications. Written by three acclaimed leaders in the field,
>>> this first edition is now available. Download your free book today!
>>> http://p.sf.net/sfu/NeoTech
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>
>>
>> ------------------------------------------------------------------------------
>> Learn Graph Databases - Download FREE O'Reilly Book
>> "Graph Databases" is the definitive new guide to graph databases and their
>> applications. Written by three acclaimed leaders in the field,
>> this first edition is now available. Download your free book today!
>> http://p.sf.net/sfu/NeoTech
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>
>
>
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-16 20:59
FromSteven Yi
SubjectRe: [Cs-dev] array feature wish list (I)
I'll take a look at the type system/string stuff later today.

On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
> Looks as if one of my commits failed.  Version of
> 2014-04-16 19:28:50
> should have many fixes -- no idea how that happened
>
> I *think* most string-array operations are broken but am not sure, or
> f how to check and fix.
>
> Quoting joachim heintz :
>
>> this is the commit:
>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>> Author: John ffitch 
>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>
>> did you push after this?
>>
>>
>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>> bizarre -- I do not get those errors/problems.  When did you check it
>>> out/pull?
>>> There was a typo in i-array arithmetic, now fixed
>>>
>>> Quoting joachim heintz :
>>>
>>>> i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>
>>>>
>>>> i can confirm the three examples you mentioned are not working. the
>>>> third example should read:
>>>> ***    copya2ftab iArr, giSine
>>>> it was a typo in my initial list.
>>>>
>>>>
>>>> number 6) does not give an error, but the results are wrong:
>>>>       iArr1[]  fillarray 1, 2, 3
>>>>       iArr2[] = iArr1 + 10
>>>>       print iArr1[0], iArr1[1], iArr1[2]
>>>>       print iArr2[0], iArr2[1], iArr2[2]
>>>> returns:
>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>> or sometimes something like:
>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>> instr 1:  #i23 =
>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>    #i24 =
>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>    #i25 = 0.000
>>>>
>>>>
>>>> same for 7):
>>>>       iArr1[] fillarray 1, 2, 3
>>>>       iArr2[] fillarray 10, 20, 30
>>>>       iArr3[] = iArr1 + iArr2
>>>>       print iArr3[0], iArr3[1], iArr3[2]
>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>> or some astronomical high numbers.
>>>>
>>>>
>>>> 8): maxarray and scalearray are working for i-arrays; minarray and
>>>> sumarray not.
>>>> * minarray:
>>>>       iArr[] fillarray 1, 2, 3
>>>>       iMin minarray iArr
>>>> -> null opadr null opadr %s
>>>> * sumarray:
>>>>       iArr[] fillarray 1, 2, 3
>>>>       iMin sumarray iArr
>>>> -> error:  Unable to find opcode entry for 'sumarray' with matching
>>>> argument types:
>>>> Found: i sumarray i[]
>>>>
>>>>
>>>> 9) maparray is not working for me:
>>>>       iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>       iArrRes[] init  7
>>>>       iArrRes maparray iArrSrc, "sqrt"
>>>> -> error:  Unable to find opcode entry for 'maparray' with matching
>>>> argument types:
>>>> Found: i[] maparray i[]S
>>>>
>>>>
>>>> 10) yes this works now:
>>>>       iArr1[] fillarray 1, 2, 3
>>>>      iArr2[] = iArr1
>>>> great!
>>>>
>>>>
>>>> best -
>>>>
>>>>     joachim
>>>>
>>>>
>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>> More after initial testing
>>>>> Of Joachim's examples the following do not work
>>>>>
>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>
>>>>> All other lines parse and run
>>>>>
>>>>> The first of these is in Steve's area.  The second is my area and I
>>>>> will look at it.  Do not understand the third.  Must test the 8)
>>>>> versions soon
>>>>>
>>>>> Nearly time for breakfast
>>>>>
>>>>> ==John ffitch
>>>>>
>>>>> 
>>>>>
>>>>> 
>>>>>
>>>>> instr 1
>>>>> SArr[] fillarray "a", "b", "c"
>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>       iArr1[] fillarray 1, 2, 3
>>>>>       iArr2[] fillarray 4, 5, 6
>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>
>>>>> ;;2) lenarray
>>>>>       Sarr[] init 3
>>>>>       print lenarray(Sarr)
>>>>>
>>>>> ;;3) slicearray
>>>>>      iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>      iArr1[] init       5
>>>>>      iArr2[] init       4
>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>> ;;b) same for S-arrays:
>>>>>      SArr[]  init       9
>>>>>      SArr1[] init       5
>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>
>>>>> ;;4) copyf2array
>>>>>       giSine  ftgen   0, 0, 8, 10, 1
>>>>>       iArr[]  init       8
>>>>>       copyf2array iArr, giSine
>>>>>
>>>>> ;;5) copya2ftab
>>>>> ;;***    copya2ftab giSine, iArr
>>>>>
>>>>> ;;6) +, -, *, / between an array and a number
>>>>> ;;do not work at i-rate. this works:
>>>>>       kArr1[] fillarray 1, 2, 3
>>>>>       kArr2[] = kArr1 + 10
>>>>> ;;but this does not:
>>>>>       iArr1[]  array 1, 2, 3
>>>>>       iArr2[] = iArr1 + 10
>>>>>
>>>>> ;;7) +, -, *, / between two arrays
>>>>> ;;also missing for i. this works:
>>>>>       kArr1[] fillarray 1, 2, 3
>>>>>       kArr2[] fillarray 10, 20, 30
>>>>>       kArr3[] = kArr1 + kArr2
>>>>> ;;but this does not:
>>>>>       iArr1[] fillarray 1, 2, 3
>>>>>       iArr2[] fillarray 10, 20, 30
>>>>>       iArr3[] = iArr1 + iArr2
>>>>>
>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>
>>>>> ;;9) maparray
>>>>> ;;as well:
>>>>>       iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>       iArrRes[] init  7
>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>
>>>>> ;;10) =
>>>>> ;;miss i-time operations. this is possible:
>>>>>       kArr1[] fillarray 1, 2, 3
>>>>>       kArr2[] = kArr1
>>>>> ;;but this returns "nul opadr":
>>>>>       iArr1[] fillarray 1, 2, 3
>>>>>      iArr2[] = iArr1
>>>>>
>>>>> endin
>>>>> 
>>>>>
>>>>> 
>>>>> i1 0 1
>>>>> e
>>>>> 
>>>>>
>>>>> 
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>> applications. Written by three acclaimed leaders in the field,
>>>>> this first edition is now available. Download your free book today!
>>>>> http://p.sf.net/sfu/NeoTech
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>> applications. Written by three acclaimed leaders in the field,
>>>> this first edition is now available. Download your free book today!
>>>> http://p.sf.net/sfu/NeoTech
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>
>>>
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Learn Graph Databases - Download FREE O'Reilly Book
>>> "Graph Databases" is the definitive new guide to graph databases and their
>>> applications. Written by three acclaimed leaders in the field,
>>> this first edition is now available. Download your free book today!
>>> http://p.sf.net/sfu/NeoTech
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>
>>
>> ------------------------------------------------------------------------------
>> Learn Graph Databases - Download FREE O'Reilly Book
>> "Graph Databases" is the definitive new guide to graph databases and their
>> applications. Written by three acclaimed leaders in the field,
>> this first edition is now available. Download your free book today!
>> http://p.sf.net/sfu/NeoTech
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>
>
>
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-17 16:06
FromSteven Yi
SubjectRe: [Cs-dev] array feature wish list (I)
I think I've made slicearray work generically now for any type.

Joachim: could you pull from develop and try with your various array tests?

On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi  wrote:
> I'll take a look at the type system/string stuff later today.
>
> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>> Looks as if one of my commits failed.  Version of
>> 2014-04-16 19:28:50
>> should have many fixes -- no idea how that happened
>>
>> I *think* most string-array operations are broken but am not sure, or
>> f how to check and fix.
>>
>> Quoting joachim heintz :
>>
>>> this is the commit:
>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>> Author: John ffitch 
>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>
>>> did you push after this?
>>>
>>>
>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>> bizarre -- I do not get those errors/problems.  When did you check it
>>>> out/pull?
>>>> There was a typo in i-array arithmetic, now fixed
>>>>
>>>> Quoting joachim heintz :
>>>>
>>>>> i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>
>>>>>
>>>>> i can confirm the three examples you mentioned are not working. the
>>>>> third example should read:
>>>>> ***    copya2ftab iArr, giSine
>>>>> it was a typo in my initial list.
>>>>>
>>>>>
>>>>> number 6) does not give an error, but the results are wrong:
>>>>>       iArr1[]  fillarray 1, 2, 3
>>>>>       iArr2[] = iArr1 + 10
>>>>>       print iArr1[0], iArr1[1], iArr1[2]
>>>>>       print iArr2[0], iArr2[1], iArr2[2]
>>>>> returns:
>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>> or sometimes something like:
>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>> instr 1:  #i23 =
>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>    #i24 =
>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>    #i25 = 0.000
>>>>>
>>>>>
>>>>> same for 7):
>>>>>       iArr1[] fillarray 1, 2, 3
>>>>>       iArr2[] fillarray 10, 20, 30
>>>>>       iArr3[] = iArr1 + iArr2
>>>>>       print iArr3[0], iArr3[1], iArr3[2]
>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>> or some astronomical high numbers.
>>>>>
>>>>>
>>>>> 8): maxarray and scalearray are working for i-arrays; minarray and
>>>>> sumarray not.
>>>>> * minarray:
>>>>>       iArr[] fillarray 1, 2, 3
>>>>>       iMin minarray iArr
>>>>> -> null opadr null opadr %s
>>>>> * sumarray:
>>>>>       iArr[] fillarray 1, 2, 3
>>>>>       iMin sumarray iArr
>>>>> -> error:  Unable to find opcode entry for 'sumarray' with matching
>>>>> argument types:
>>>>> Found: i sumarray i[]
>>>>>
>>>>>
>>>>> 9) maparray is not working for me:
>>>>>       iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>       iArrRes[] init  7
>>>>>       iArrRes maparray iArrSrc, "sqrt"
>>>>> -> error:  Unable to find opcode entry for 'maparray' with matching
>>>>> argument types:
>>>>> Found: i[] maparray i[]S
>>>>>
>>>>>
>>>>> 10) yes this works now:
>>>>>       iArr1[] fillarray 1, 2, 3
>>>>>      iArr2[] = iArr1
>>>>> great!
>>>>>
>>>>>
>>>>> best -
>>>>>
>>>>>     joachim
>>>>>
>>>>>
>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>> More after initial testing
>>>>>> Of Joachim's examples the following do not work
>>>>>>
>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>
>>>>>> All other lines parse and run
>>>>>>
>>>>>> The first of these is in Steve's area.  The second is my area and I
>>>>>> will look at it.  Do not understand the third.  Must test the 8)
>>>>>> versions soon
>>>>>>
>>>>>> Nearly time for breakfast
>>>>>>
>>>>>> ==John ffitch
>>>>>>
>>>>>> 
>>>>>>
>>>>>> 
>>>>>>
>>>>>> instr 1
>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>       iArr1[] fillarray 1, 2, 3
>>>>>>       iArr2[] fillarray 4, 5, 6
>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>
>>>>>> ;;2) lenarray
>>>>>>       Sarr[] init 3
>>>>>>       print lenarray(Sarr)
>>>>>>
>>>>>> ;;3) slicearray
>>>>>>      iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>      iArr1[] init       5
>>>>>>      iArr2[] init       4
>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>> ;;b) same for S-arrays:
>>>>>>      SArr[]  init       9
>>>>>>      SArr1[] init       5
>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>
>>>>>> ;;4) copyf2array
>>>>>>       giSine  ftgen   0, 0, 8, 10, 1
>>>>>>       iArr[]  init       8
>>>>>>       copyf2array iArr, giSine
>>>>>>
>>>>>> ;;5) copya2ftab
>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>
>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>> ;;do not work at i-rate. this works:
>>>>>>       kArr1[] fillarray 1, 2, 3
>>>>>>       kArr2[] = kArr1 + 10
>>>>>> ;;but this does not:
>>>>>>       iArr1[]  array 1, 2, 3
>>>>>>       iArr2[] = iArr1 + 10
>>>>>>
>>>>>> ;;7) +, -, *, / between two arrays
>>>>>> ;;also missing for i. this works:
>>>>>>       kArr1[] fillarray 1, 2, 3
>>>>>>       kArr2[] fillarray 10, 20, 30
>>>>>>       kArr3[] = kArr1 + kArr2
>>>>>> ;;but this does not:
>>>>>>       iArr1[] fillarray 1, 2, 3
>>>>>>       iArr2[] fillarray 10, 20, 30
>>>>>>       iArr3[] = iArr1 + iArr2
>>>>>>
>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>
>>>>>> ;;9) maparray
>>>>>> ;;as well:
>>>>>>       iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>       iArrRes[] init  7
>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>
>>>>>> ;;10) =
>>>>>> ;;miss i-time operations. this is possible:
>>>>>>       kArr1[] fillarray 1, 2, 3
>>>>>>       kArr2[] = kArr1
>>>>>> ;;but this returns "nul opadr":
>>>>>>       iArr1[] fillarray 1, 2, 3
>>>>>>      iArr2[] = iArr1
>>>>>>
>>>>>> endin
>>>>>> 
>>>>>>
>>>>>> 
>>>>>> i1 0 1
>>>>>> e
>>>>>> 
>>>>>>
>>>>>> 
>>>>>>
>>>>>> ------------------------------------------------------------------------------
>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>> this first edition is now available. Download your free book today!
>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>> _______________________________________________
>>>>>> Csound-devel mailing list
>>>>>> Csound-devel@lists.sourceforge.net
>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>> applications. Written by three acclaimed leaders in the field,
>>>>> this first edition is now available. Download your free book today!
>>>>> http://p.sf.net/sfu/NeoTech
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>>
>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>> applications. Written by three acclaimed leaders in the field,
>>>> this first edition is now available. Download your free book today!
>>>> http://p.sf.net/sfu/NeoTech
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Learn Graph Databases - Download FREE O'Reilly Book
>>> "Graph Databases" is the definitive new guide to graph databases and their
>>> applications. Written by three acclaimed leaders in the field,
>>> this first edition is now available. Download your free book today!
>>> http://p.sf.net/sfu/NeoTech
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>>
>>
>>
>> ------------------------------------------------------------------------------
>> Learn Graph Databases - Download FREE O'Reilly Book
>> "Graph Databases" is the definitive new guide to graph databases and their
>> applications. Written by three acclaimed leaders in the field,
>> this first edition is now available. Download your free book today!
>> http://p.sf.net/sfu/NeoTech
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-17 17:49
FromAndres Cabrera
SubjectRe: [Cs-dev] array feature wish list (I)
AttachmentsNone  None  
Also it might be a good idea to add some of these array csds to the test suite.

Cheers,
Andrés


On Thu, Apr 17, 2014 at 8:06 AM, Steven Yi <stevenyi@gmail.com> wrote:
I think I've made slicearray work generically now for any type.

Joachim: could you pull from develop and try with your various array tests?

On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi <stevenyi@gmail.com> wrote:
> I'll take a look at the type system/string stuff later today.
>
> On Wed, Apr 16, 2014 at 2:52 PM,  <jpff@cs.bath.ac.uk> wrote:
>> Looks as if one of my commits failed.  Version of
>> 2014-04-16 19:28:50
>> should have many fixes -- no idea how that happened
>>
>> I *think* most string-array operations are broken but am not sure, or
>> f how to check and fix.
>>
>> Quoting joachim heintz <jh@joachimheintz.de>:
>>
>>> this is the commit:
>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>> Author: John ffitch <jpff@codemist.co.uk>
>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>
>>> did you push after this?
>>>
>>>
>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>> bizarre -- I do not get those errors/problems.  When did you check it
>>>> out/pull?
>>>> There was a typo in i-array arithmetic, now fixed
>>>>
>>>> Quoting joachim heintz <jh@joachimheintz.de>:
>>>>
>>>>> i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>
>>>>>
>>>>> i can confirm the three examples you mentioned are not working. the
>>>>> third example should read:
>>>>> ***    copya2ftab iArr, giSine
>>>>> it was a typo in my initial list.
>>>>>
>>>>>
>>>>> number 6) does not give an error, but the results are wrong:
>>>>>       iArr1[]  fillarray 1, 2, 3
>>>>>       iArr2[] = iArr1 + 10
>>>>>       print iArr1[0], iArr1[1], iArr1[2]
>>>>>       print iArr2[0], iArr2[1], iArr2[2]
>>>>> returns:
>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>> or sometimes something like:
>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>> instr 1:  #i23 =
>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>    #i24 =
>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>    #i25 = 0.000
>>>>>
>>>>>
>>>>> same for 7):
>>>>>       iArr1[] fillarray 1, 2, 3
>>>>>       iArr2[] fillarray 10, 20, 30
>>>>>       iArr3[] = iArr1 + iArr2
>>>>>       print iArr3[0], iArr3[1], iArr3[2]
>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>> or some astronomical high numbers.
>>>>>
>>>>>
>>>>> 8): maxarray and scalearray are working for i-arrays; minarray and
>>>>> sumarray not.
>>>>> * minarray:
>>>>>       iArr[] fillarray 1, 2, 3
>>>>>       iMin minarray iArr
>>>>> -> null opadr null opadr %s
>>>>> * sumarray:
>>>>>       iArr[] fillarray 1, 2, 3
>>>>>       iMin sumarray iArr
>>>>> -> error:  Unable to find opcode entry for 'sumarray' with matching
>>>>> argument types:
>>>>> Found: i sumarray i[]
>>>>>
>>>>>
>>>>> 9) maparray is not working for me:
>>>>>       iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>       iArrRes[] init  7
>>>>>       iArrRes maparray iArrSrc, "sqrt"
>>>>> -> error:  Unable to find opcode entry for 'maparray' with matching
>>>>> argument types:
>>>>> Found: i[] maparray i[]S
>>>>>
>>>>>
>>>>> 10) yes this works now:
>>>>>       iArr1[] fillarray 1, 2, 3
>>>>>      iArr2[] = iArr1
>>>>> great!
>>>>>
>>>>>
>>>>> best -
>>>>>
>>>>>     joachim
>>>>>
>>>>>
>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>> More after initial testing
>>>>>> Of Joachim's examples the following do not work
>>>>>>
>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>
>>>>>> All other lines parse and run
>>>>>>
>>>>>> The first of these is in Steve's area.  The second is my area and I
>>>>>> will look at it.  Do not understand the third.  Must test the 8)
>>>>>> versions soon
>>>>>>
>>>>>> Nearly time for breakfast
>>>>>>
>>>>>> ==John ffitch
>>>>>>
>>>>>> <CsoundSynthesizer>
>>>>>>
>>>>>> <CsInstruments>
>>>>>>
>>>>>> instr 1
>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>       iArr1[] fillarray 1, 2, 3
>>>>>>       iArr2[] fillarray 4, 5, 6
>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>
>>>>>> ;;2) lenarray
>>>>>>       Sarr[] init 3
>>>>>>       print lenarray(Sarr)
>>>>>>
>>>>>> ;;3) slicearray
>>>>>>      iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>      iArr1[] init       5
>>>>>>      iArr2[] init       4
>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>> ;;b) same for S-arrays:
>>>>>>      SArr[]  init       9
>>>>>>      SArr1[] init       5
>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>
>>>>>> ;;4) copyf2array
>>>>>>       giSine  ftgen   0, 0, 8, 10, 1
>>>>>>       iArr[]  init       8
>>>>>>       copyf2array iArr, giSine
>>>>>>
>>>>>> ;;5) copya2ftab
>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>
>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>> ;;do not work at i-rate. this works:
>>>>>>       kArr1[] fillarray 1, 2, 3
>>>>>>       kArr2[] = kArr1 + 10
>>>>>> ;;but this does not:
>>>>>>       iArr1[]  array 1, 2, 3
>>>>>>       iArr2[] = iArr1 + 10
>>>>>>
>>>>>> ;;7) +, -, *, / between two arrays
>>>>>> ;;also missing for i. this works:
>>>>>>       kArr1[] fillarray 1, 2, 3
>>>>>>       kArr2[] fillarray 10, 20, 30
>>>>>>       kArr3[] = kArr1 + kArr2
>>>>>> ;;but this does not:
>>>>>>       iArr1[] fillarray 1, 2, 3
>>>>>>       iArr2[] fillarray 10, 20, 30
>>>>>>       iArr3[] = iArr1 + iArr2
>>>>>>
>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>
>>>>>> ;;9) maparray
>>>>>> ;;as well:
>>>>>>       iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>       iArrRes[] init  7
>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>
>>>>>> ;;10) =
>>>>>> ;;miss i-time operations. this is possible:
>>>>>>       kArr1[] fillarray 1, 2, 3
>>>>>>       kArr2[] = kArr1
>>>>>> ;;but this returns "nul opadr":
>>>>>>       iArr1[] fillarray 1, 2, 3
>>>>>>      iArr2[] = iArr1
>>>>>>
>>>>>> endin
>>>>>> </CsInstruments>
>>>>>>
>>>>>> <CsScore>
>>>>>> i1 0 1
>>>>>> e
>>>>>> </CsScore>
>>>>>>
>>>>>> </CsoundSynthesizer>
>>>>>>
>>>>>> ------------------------------------------------------------------------------
>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>> this first edition is now available. Download your free book today!
>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>> _______________________________________________
>>>>>> Csound-devel mailing list
>>>>>> Csound-devel@lists.sourceforge.net
>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>> applications. Written by three acclaimed leaders in the field,
>>>>> this first edition is now available. Download your free book today!
>>>>> http://p.sf.net/sfu/NeoTech
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>>
>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>> applications. Written by three acclaimed leaders in the field,
>>>> this first edition is now available. Download your free book today!
>>>> http://p.sf.net/sfu/NeoTech
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Learn Graph Databases - Download FREE O'Reilly Book
>>> "Graph Databases" is the definitive new guide to graph databases and their
>>> applications. Written by three acclaimed leaders in the field,
>>> this first edition is now available. Download your free book today!
>>> http://p.sf.net/sfu/NeoTech
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>>
>>
>>
>> ------------------------------------------------------------------------------
>> Learn Graph Databases - Download FREE O'Reilly Book
>> "Graph Databases" is the definitive new guide to graph databases and their
>> applications. Written by three acclaimed leaders in the field,
>> this first edition is now available. Download your free book today!
>> http://p.sf.net/sfu/NeoTech
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/csound-devel


Date2014-04-17 22:00
Fromjoachim heintz
SubjectRe: [Cs-dev] array feature wish list (I)
yes, slicearray seems to work. while testing, i found that string arrays 
return the wrong value for an index. this is a simple example:

SArr[]     fillarray  "a", "b", "c", "d", "e", "f"
print lenarray(SArr) ;6
printf_i "%s\n", 1, SArr[0] ;a
printf_i "%s\n", 1, SArr[1] ;c!
printf_i "%s\n", 1, SArr[2] ;e!
printf_i "%s\n", 1, SArr[3] ;segfault

probably a simple mistake?

	joachim

Am 17.04.2014 17:06, schrieb Steven Yi:
> I think I've made slicearray work generically now for any type.
>
> Joachim: could you pull from develop and try with your various array tests?
>
> On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi  wrote:
>> I'll take a look at the type system/string stuff later today.
>>
>> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>>> Looks as if one of my commits failed.  Version of
>>> 2014-04-16 19:28:50
>>> should have many fixes -- no idea how that happened
>>>
>>> I *think* most string-array operations are broken but am not sure, or
>>> f how to check and fix.
>>>
>>> Quoting joachim heintz :
>>>
>>>> this is the commit:
>>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>>> Author: John ffitch 
>>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>>
>>>> did you push after this?
>>>>
>>>>
>>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>>> bizarre -- I do not get those errors/problems.  When did you check it
>>>>> out/pull?
>>>>> There was a typo in i-array arithmetic, now fixed
>>>>>
>>>>> Quoting joachim heintz :
>>>>>
>>>>>> i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>>
>>>>>>
>>>>>> i can confirm the three examples you mentioned are not working. the
>>>>>> third example should read:
>>>>>> ***    copya2ftab iArr, giSine
>>>>>> it was a typo in my initial list.
>>>>>>
>>>>>>
>>>>>> number 6) does not give an error, but the results are wrong:
>>>>>>        iArr1[]  fillarray 1, 2, 3
>>>>>>        iArr2[] = iArr1 + 10
>>>>>>        print iArr1[0], iArr1[1], iArr1[2]
>>>>>>        print iArr2[0], iArr2[1], iArr2[2]
>>>>>> returns:
>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>>> or sometimes something like:
>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>> instr 1:  #i23 =
>>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>>     #i24 =
>>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>>     #i25 = 0.000
>>>>>>
>>>>>>
>>>>>> same for 7):
>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>        iArr2[] fillarray 10, 20, 30
>>>>>>        iArr3[] = iArr1 + iArr2
>>>>>>        print iArr3[0], iArr3[1], iArr3[2]
>>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>>> or some astronomical high numbers.
>>>>>>
>>>>>>
>>>>>> 8): maxarray and scalearray are working for i-arrays; minarray and
>>>>>> sumarray not.
>>>>>> * minarray:
>>>>>>        iArr[] fillarray 1, 2, 3
>>>>>>        iMin minarray iArr
>>>>>> -> null opadr null opadr %s
>>>>>> * sumarray:
>>>>>>        iArr[] fillarray 1, 2, 3
>>>>>>        iMin sumarray iArr
>>>>>> -> error:  Unable to find opcode entry for 'sumarray' with matching
>>>>>> argument types:
>>>>>> Found: i sumarray i[]
>>>>>>
>>>>>>
>>>>>> 9) maparray is not working for me:
>>>>>>        iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>        iArrRes[] init  7
>>>>>>        iArrRes maparray iArrSrc, "sqrt"
>>>>>> -> error:  Unable to find opcode entry for 'maparray' with matching
>>>>>> argument types:
>>>>>> Found: i[] maparray i[]S
>>>>>>
>>>>>>
>>>>>> 10) yes this works now:
>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>       iArr2[] = iArr1
>>>>>> great!
>>>>>>
>>>>>>
>>>>>> best -
>>>>>>
>>>>>>      joachim
>>>>>>
>>>>>>
>>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>>> More after initial testing
>>>>>>> Of Joachim's examples the following do not work
>>>>>>>
>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>>
>>>>>>> All other lines parse and run
>>>>>>>
>>>>>>> The first of these is in Steve's area.  The second is my area and I
>>>>>>> will look at it.  Do not understand the third.  Must test the 8)
>>>>>>> versions soon
>>>>>>>
>>>>>>> Nearly time for breakfast
>>>>>>>
>>>>>>> ==John ffitch
>>>>>>>
>>>>>>> 
>>>>>>>
>>>>>>> 
>>>>>>>
>>>>>>> instr 1
>>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>        iArr2[] fillarray 4, 5, 6
>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>
>>>>>>> ;;2) lenarray
>>>>>>>        Sarr[] init 3
>>>>>>>        print lenarray(Sarr)
>>>>>>>
>>>>>>> ;;3) slicearray
>>>>>>>       iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>>       iArr1[] init       5
>>>>>>>       iArr2[] init       4
>>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>>> ;;b) same for S-arrays:
>>>>>>>       SArr[]  init       9
>>>>>>>       SArr1[] init       5
>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>
>>>>>>> ;;4) copyf2array
>>>>>>>        giSine  ftgen   0, 0, 8, 10, 1
>>>>>>>        iArr[]  init       8
>>>>>>>        copyf2array iArr, giSine
>>>>>>>
>>>>>>> ;;5) copya2ftab
>>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>>
>>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>>> ;;do not work at i-rate. this works:
>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>        kArr2[] = kArr1 + 10
>>>>>>> ;;but this does not:
>>>>>>>        iArr1[]  array 1, 2, 3
>>>>>>>        iArr2[] = iArr1 + 10
>>>>>>>
>>>>>>> ;;7) +, -, *, / between two arrays
>>>>>>> ;;also missing for i. this works:
>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>        kArr2[] fillarray 10, 20, 30
>>>>>>>        kArr3[] = kArr1 + kArr2
>>>>>>> ;;but this does not:
>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>        iArr2[] fillarray 10, 20, 30
>>>>>>>        iArr3[] = iArr1 + iArr2
>>>>>>>
>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>>
>>>>>>> ;;9) maparray
>>>>>>> ;;as well:
>>>>>>>        iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>        iArrRes[] init  7
>>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>>
>>>>>>> ;;10) =
>>>>>>> ;;miss i-time operations. this is possible:
>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>        kArr2[] = kArr1
>>>>>>> ;;but this returns "nul opadr":
>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>       iArr2[] = iArr1
>>>>>>>
>>>>>>> endin
>>>>>>> 
>>>>>>>
>>>>>>> 
>>>>>>> i1 0 1
>>>>>>> e
>>>>>>> 
>>>>>>>
>>>>>>> 
>>>>>>>
>>>>>>> ------------------------------------------------------------------------------
>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>> this first edition is now available. Download your free book today!
>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>> _______________________________________________
>>>>>>> Csound-devel mailing list
>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>
>>>>>>
>>>>>> ------------------------------------------------------------------------------
>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>> this first edition is now available. Download your free book today!
>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>> _______________________________________________
>>>>>> Csound-devel mailing list
>>>>>> Csound-devel@lists.sourceforge.net
>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>> applications. Written by three acclaimed leaders in the field,
>>>>> this first edition is now available. Download your free book today!
>>>>> http://p.sf.net/sfu/NeoTech
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>> applications. Written by three acclaimed leaders in the field,
>>>> this first edition is now available. Download your free book today!
>>>> http://p.sf.net/sfu/NeoTech
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>
>>>
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Learn Graph Databases - Download FREE O'Reilly Book
>>> "Graph Databases" is the definitive new guide to graph databases and their
>>> applications. Written by three acclaimed leaders in the field,
>>> this first edition is now available. Download your free book today!
>>> http://p.sf.net/sfu/NeoTech
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-17 22:05
FromRory Walsh
SubjectRe: [Cs-dev] array feature wish list (I)
Could be related to
http://csound.1045644.n5.nabble.com/changed-with-strings-tt5733400.html#a5733424
http://csound.1045644.n5.nabble.com/string-array-assignment-and-loops-tt5733429.html#a5733434
I thought this was fixed?

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-17 22:15
Fromjoachim heintz
SubjectRe: [Cs-dev] array feature wish list (I)
yes, with pleasure. still working on it ...
best -
	j


Am 17.04.2014 18:49, schrieb Andres Cabrera:
> Also it might be a good idea to add some of these array csds to the test
> suite.
>
> Cheers,
> Andrés
>
>
> On Thu, Apr 17, 2014 at 8:06 AM, Steven Yi  > wrote:
>
>     I think I've made slicearray work generically now for any type.
>
>     Joachim: could you pull from develop and try with your various array
>     tests?
>
>     On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi      > wrote:
>      > I'll take a look at the type system/string stuff later today.
>      >
>      > On Wed, Apr 16, 2014 at 2:52 PM,       > wrote:
>      >> Looks as if one of my commits failed.  Version of
>      >> 2014-04-16 19:28:50
>      >> should have many fixes -- no idea how that happened
>      >>
>      >> I *think* most string-array operations are broken but am not
>     sure, or
>      >> f how to check and fix.
>      >>
>      >> Quoting joachim heintz      >:
>      >>
>      >>> this is the commit:
>      >>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>      >>> Author: John ffitch      >
>      >>> Date:   Wed Apr 16 11:06:25 2014 +0100
>      >>>
>      >>> did you push after this?
>      >>>
>      >>>
>      >>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk
>     :
>      >>>> bizarre -- I do not get those errors/problems.  When did you
>     check it
>      >>>> out/pull?
>      >>>> There was a typo in i-array arithmetic, now fixed
>      >>>>
>      >>>> Quoting joachim heintz      >:
>      >>>>
>      >>>>> i tested with recent git (commit
>     3e5567414c8843d7feca6f4315a7a715ed5509c8).
>      >>>>>
>      >>>>>
>      >>>>> i can confirm the three examples you mentioned are not
>     working. the
>      >>>>> third example should read:
>      >>>>> ***    copya2ftab iArr, giSine
>      >>>>> it was a typo in my initial list.
>      >>>>>
>      >>>>>
>      >>>>> number 6) does not give an error, but the results are wrong:
>      >>>>>       iArr1[]  fillarray 1, 2, 3
>      >>>>>       iArr2[] = iArr1 + 10
>      >>>>>       print iArr1[0], iArr1[1], iArr1[2]
>      >>>>>       print iArr2[0], iArr2[1], iArr2[2]
>      >>>>> returns:
>      >>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>      >>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>      >>>>> or sometimes something like:
>      >>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>      >>>>> instr 1:  #i23 =
>      >>>>>
>     7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>      >>>>>    #i24 =
>      >>>>>
>     1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>      >>>>>    #i25 = 0.000
>      >>>>>
>      >>>>>
>      >>>>> same for 7):
>      >>>>>       iArr1[] fillarray 1, 2, 3
>      >>>>>       iArr2[] fillarray 10, 20, 30
>      >>>>>       iArr3[] = iArr1 + iArr2
>      >>>>>       print iArr3[0], iArr3[1], iArr3[2]
>      >>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>      >>>>> or some astronomical high numbers.
>      >>>>>
>      >>>>>
>      >>>>> 8): maxarray and scalearray are working for i-arrays;
>     minarray and
>      >>>>> sumarray not.
>      >>>>> * minarray:
>      >>>>>       iArr[] fillarray 1, 2, 3
>      >>>>>       iMin minarray iArr
>      >>>>> -> null opadr null opadr %s
>      >>>>> * sumarray:
>      >>>>>       iArr[] fillarray 1, 2, 3
>      >>>>>       iMin sumarray iArr
>      >>>>> -> error:  Unable to find opcode entry for 'sumarray' with
>     matching
>      >>>>> argument types:
>      >>>>> Found: i sumarray i[]
>      >>>>>
>      >>>>>
>      >>>>> 9) maparray is not working for me:
>      >>>>>       iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>      >>>>>       iArrRes[] init  7
>      >>>>>       iArrRes maparray iArrSrc, "sqrt"
>      >>>>> -> error:  Unable to find opcode entry for 'maparray' with
>     matching
>      >>>>> argument types:
>      >>>>> Found: i[] maparray i[]S
>      >>>>>
>      >>>>>
>      >>>>> 10) yes this works now:
>      >>>>>       iArr1[] fillarray 1, 2, 3
>      >>>>>      iArr2[] = iArr1
>      >>>>> great!
>      >>>>>
>      >>>>>
>      >>>>> best -
>      >>>>>
>      >>>>>     joachim
>      >>>>>
>      >>>>>
>      >>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>      >>>>>> More after initial testing
>      >>>>>> Of Joachim's examples the following do not work
>      >>>>>>
>      >>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>      >>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>      >>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>      >>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>      >>>>>>
>      >>>>>> All other lines parse and run
>      >>>>>>
>      >>>>>> The first of these is in Steve's area.  The second is my
>     area and I
>      >>>>>> will look at it.  Do not understand the third.  Must test the 8)
>      >>>>>> versions soon
>      >>>>>>
>      >>>>>> Nearly time for breakfast
>      >>>>>>
>      >>>>>> ==John ffitch
>      >>>>>>
>      >>>>>> 
>      >>>>>>
>      >>>>>> 
>      >>>>>>
>      >>>>>> instr 1
>      >>>>>> SArr[] fillarray "a", "b", "c"
>      >>>>>> ;;b) not possible to have arrays as arguments, e.g.
>      >>>>>>       iArr1[] fillarray 1, 2, 3
>      >>>>>>       iArr2[] fillarray 4, 5, 6
>      >>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>      >>>>>>
>      >>>>>> ;;2) lenarray
>      >>>>>>       Sarr[] init 3
>      >>>>>>       print lenarray(Sarr)
>      >>>>>>
>      >>>>>> ;;3) slicearray
>      >>>>>>      iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>      >>>>>>      iArr1[] init       5
>      >>>>>>      iArr2[] init       4
>      >>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>      >>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>      >>>>>> ;;b) same for S-arrays:
>      >>>>>>      SArr[]  init       9
>      >>>>>>      SArr1[] init       5
>      >>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>      >>>>>>
>      >>>>>> ;;4) copyf2array
>      >>>>>>       giSine  ftgen   0, 0, 8, 10, 1
>      >>>>>>       iArr[]  init       8
>      >>>>>>       copyf2array iArr, giSine
>      >>>>>>
>      >>>>>> ;;5) copya2ftab
>      >>>>>> ;;***    copya2ftab giSine, iArr
>      >>>>>>
>      >>>>>> ;;6) +, -, *, / between an array and a number
>      >>>>>> ;;do not work at i-rate. this works:
>      >>>>>>       kArr1[] fillarray 1, 2, 3
>      >>>>>>       kArr2[] = kArr1 + 10
>      >>>>>> ;;but this does not:
>      >>>>>>       iArr1[]  array 1, 2, 3
>      >>>>>>       iArr2[] = iArr1 + 10
>      >>>>>>
>      >>>>>> ;;7) +, -, *, / between two arrays
>      >>>>>> ;;also missing for i. this works:
>      >>>>>>       kArr1[] fillarray 1, 2, 3
>      >>>>>>       kArr2[] fillarray 10, 20, 30
>      >>>>>>       kArr3[] = kArr1 + kArr2
>      >>>>>> ;;but this does not:
>      >>>>>>       iArr1[] fillarray 1, 2, 3
>      >>>>>>       iArr2[] fillarray 10, 20, 30
>      >>>>>>       iArr3[] = iArr1 + iArr2
>      >>>>>>
>      >>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>      >>>>>> ;;do all miss i-time operations, as far as i see.
>      >>>>>>
>      >>>>>> ;;9) maparray
>      >>>>>> ;;as well:
>      >>>>>>       iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>      >>>>>>       iArrRes[] init  7
>      >>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>      >>>>>>
>      >>>>>> ;;10) =
>      >>>>>> ;;miss i-time operations. this is possible:
>      >>>>>>       kArr1[] fillarray 1, 2, 3
>      >>>>>>       kArr2[] = kArr1
>      >>>>>> ;;but this returns "nul opadr":
>      >>>>>>       iArr1[] fillarray 1, 2, 3
>      >>>>>>      iArr2[] = iArr1
>      >>>>>>
>      >>>>>> endin
>      >>>>>> 
>      >>>>>>
>      >>>>>> 
>      >>>>>> i1 0 1
>      >>>>>> e
>      >>>>>> 
>      >>>>>>
>      >>>>>> 
>      >>>>>>
>      >>>>>>
>     ------------------------------------------------------------------------------
>      >>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>      >>>>>> "Graph Databases" is the definitive new guide to graph
>     databases and their
>      >>>>>> applications. Written by three acclaimed leaders in the field,
>      >>>>>> this first edition is now available. Download your free book
>     today!
>      >>>>>> http://p.sf.net/sfu/NeoTech
>      >>>>>> _______________________________________________
>      >>>>>> Csound-devel mailing list
>      >>>>>> Csound-devel@lists.sourceforge.net
>     
>      >>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>      >>>>>>
>      >>>>>
>      >>>>>
>     ------------------------------------------------------------------------------
>      >>>>> Learn Graph Databases - Download FREE O'Reilly Book
>      >>>>> "Graph Databases" is the definitive new guide to graph
>     databases and their
>      >>>>> applications. Written by three acclaimed leaders in the field,
>      >>>>> this first edition is now available. Download your free book
>     today!
>      >>>>> http://p.sf.net/sfu/NeoTech
>      >>>>> _______________________________________________
>      >>>>> Csound-devel mailing list
>      >>>>> Csound-devel@lists.sourceforge.net
>     
>      >>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>      >>>>
>      >>>>
>      >>>>
>      >>>>
>      >>>>
>     ------------------------------------------------------------------------------
>      >>>> Learn Graph Databases - Download FREE O'Reilly Book
>      >>>> "Graph Databases" is the definitive new guide to graph
>     databases and their
>      >>>> applications. Written by three acclaimed leaders in the field,
>      >>>> this first edition is now available. Download your free book
>     today!
>      >>>> http://p.sf.net/sfu/NeoTech
>      >>>> _______________________________________________
>      >>>> Csound-devel mailing list
>      >>>> Csound-devel@lists.sourceforge.net
>     
>      >>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>      >>>>
>      >>>
>      >>>
>     ------------------------------------------------------------------------------
>      >>> Learn Graph Databases - Download FREE O'Reilly Book
>      >>> "Graph Databases" is the definitive new guide to graph
>     databases and their
>      >>> applications. Written by three acclaimed leaders in the field,
>      >>> this first edition is now available. Download your free book today!
>      >>> http://p.sf.net/sfu/NeoTech
>      >>> _______________________________________________
>      >>> Csound-devel mailing list
>      >>> Csound-devel@lists.sourceforge.net
>     
>      >>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>      >>
>      >>
>      >>
>      >>
>      >>
>     ------------------------------------------------------------------------------
>      >> Learn Graph Databases - Download FREE O'Reilly Book
>      >> "Graph Databases" is the definitive new guide to graph databases
>     and their
>      >> applications. Written by three acclaimed leaders in the field,
>      >> this first edition is now available. Download your free book today!
>      >> http://p.sf.net/sfu/NeoTech
>      >> _______________________________________________
>      >> Csound-devel mailing list
>      >> Csound-devel@lists.sourceforge.net
>     
>      >> https://lists.sourceforge.net/lists/listinfo/csound-devel
>
>     ------------------------------------------------------------------------------
>     Learn Graph Databases - Download FREE O'Reilly Book
>     "Graph Databases" is the definitive new guide to graph databases and
>     their
>     applications. Written by three acclaimed leaders in the field,
>     this first edition is now available. Download your free book today!
>     http://p.sf.net/sfu/NeoTech
>     _______________________________________________
>     Csound-devel mailing list
>     Csound-devel@lists.sourceforge.net
>     
>     https://lists.sourceforge.net/lists/listinfo/csound-devel
>
>
>
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
>
>
>
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/

Date2014-04-17 22:40
FromSteven Yi
SubjectRe: [Cs-dev] array feature wish list (I)
I'm getting:

instr 1:  #i0 = 6.000
a
b
c
d

Though sometimes I also get:

instr 1:  #i0 = 6.000
(null)
(null)
(null)
(null)

which makes this very odd. I'll check futher.

On Thu, Apr 17, 2014 at 5:00 PM, joachim heintz  wrote:
> yes, slicearray seems to work. while testing, i found that string arrays
> return the wrong value for an index. this is a simple example:
>
> SArr[]     fillarray  "a", "b", "c", "d", "e", "f"
> print lenarray(SArr) ;6
> printf_i "%s\n", 1, SArr[0] ;a
> printf_i "%s\n", 1, SArr[1] ;c!
> printf_i "%s\n", 1, SArr[2] ;e!
> printf_i "%s\n", 1, SArr[3] ;segfault
>
> probably a simple mistake?
>
>         joachim
>
> Am 17.04.2014 17:06, schrieb Steven Yi:
>> I think I've made slicearray work generically now for any type.
>>
>> Joachim: could you pull from develop and try with your various array tests?
>>
>> On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi  wrote:
>>> I'll take a look at the type system/string stuff later today.
>>>
>>> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>>>> Looks as if one of my commits failed.  Version of
>>>> 2014-04-16 19:28:50
>>>> should have many fixes -- no idea how that happened
>>>>
>>>> I *think* most string-array operations are broken but am not sure, or
>>>> f how to check and fix.
>>>>
>>>> Quoting joachim heintz :
>>>>
>>>>> this is the commit:
>>>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>>>> Author: John ffitch 
>>>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>>>
>>>>> did you push after this?
>>>>>
>>>>>
>>>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>>>> bizarre -- I do not get those errors/problems.  When did you check it
>>>>>> out/pull?
>>>>>> There was a typo in i-array arithmetic, now fixed
>>>>>>
>>>>>> Quoting joachim heintz :
>>>>>>
>>>>>>> i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>>>
>>>>>>>
>>>>>>> i can confirm the three examples you mentioned are not working. the
>>>>>>> third example should read:
>>>>>>> ***    copya2ftab iArr, giSine
>>>>>>> it was a typo in my initial list.
>>>>>>>
>>>>>>>
>>>>>>> number 6) does not give an error, but the results are wrong:
>>>>>>>        iArr1[]  fillarray 1, 2, 3
>>>>>>>        iArr2[] = iArr1 + 10
>>>>>>>        print iArr1[0], iArr1[1], iArr1[2]
>>>>>>>        print iArr2[0], iArr2[1], iArr2[2]
>>>>>>> returns:
>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>>>> or sometimes something like:
>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>> instr 1:  #i23 =
>>>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>>>     #i24 =
>>>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>>>     #i25 = 0.000
>>>>>>>
>>>>>>>
>>>>>>> same for 7):
>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>        iArr2[] fillarray 10, 20, 30
>>>>>>>        iArr3[] = iArr1 + iArr2
>>>>>>>        print iArr3[0], iArr3[1], iArr3[2]
>>>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>>>> or some astronomical high numbers.
>>>>>>>
>>>>>>>
>>>>>>> 8): maxarray and scalearray are working for i-arrays; minarray and
>>>>>>> sumarray not.
>>>>>>> * minarray:
>>>>>>>        iArr[] fillarray 1, 2, 3
>>>>>>>        iMin minarray iArr
>>>>>>> -> null opadr null opadr %s
>>>>>>> * sumarray:
>>>>>>>        iArr[] fillarray 1, 2, 3
>>>>>>>        iMin sumarray iArr
>>>>>>> -> error:  Unable to find opcode entry for 'sumarray' with matching
>>>>>>> argument types:
>>>>>>> Found: i sumarray i[]
>>>>>>>
>>>>>>>
>>>>>>> 9) maparray is not working for me:
>>>>>>>        iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>        iArrRes[] init  7
>>>>>>>        iArrRes maparray iArrSrc, "sqrt"
>>>>>>> -> error:  Unable to find opcode entry for 'maparray' with matching
>>>>>>> argument types:
>>>>>>> Found: i[] maparray i[]S
>>>>>>>
>>>>>>>
>>>>>>> 10) yes this works now:
>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>       iArr2[] = iArr1
>>>>>>> great!
>>>>>>>
>>>>>>>
>>>>>>> best -
>>>>>>>
>>>>>>>      joachim
>>>>>>>
>>>>>>>
>>>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>>>> More after initial testing
>>>>>>>> Of Joachim's examples the following do not work
>>>>>>>>
>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>>>
>>>>>>>> All other lines parse and run
>>>>>>>>
>>>>>>>> The first of these is in Steve's area.  The second is my area and I
>>>>>>>> will look at it.  Do not understand the third.  Must test the 8)
>>>>>>>> versions soon
>>>>>>>>
>>>>>>>> Nearly time for breakfast
>>>>>>>>
>>>>>>>> ==John ffitch
>>>>>>>>
>>>>>>>> 
>>>>>>>>
>>>>>>>> 
>>>>>>>>
>>>>>>>> instr 1
>>>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>        iArr2[] fillarray 4, 5, 6
>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>
>>>>>>>> ;;2) lenarray
>>>>>>>>        Sarr[] init 3
>>>>>>>>        print lenarray(Sarr)
>>>>>>>>
>>>>>>>> ;;3) slicearray
>>>>>>>>       iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>>>       iArr1[] init       5
>>>>>>>>       iArr2[] init       4
>>>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>>>> ;;b) same for S-arrays:
>>>>>>>>       SArr[]  init       9
>>>>>>>>       SArr1[] init       5
>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>
>>>>>>>> ;;4) copyf2array
>>>>>>>>        giSine  ftgen   0, 0, 8, 10, 1
>>>>>>>>        iArr[]  init       8
>>>>>>>>        copyf2array iArr, giSine
>>>>>>>>
>>>>>>>> ;;5) copya2ftab
>>>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>>>
>>>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>>>> ;;do not work at i-rate. this works:
>>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>>        kArr2[] = kArr1 + 10
>>>>>>>> ;;but this does not:
>>>>>>>>        iArr1[]  array 1, 2, 3
>>>>>>>>        iArr2[] = iArr1 + 10
>>>>>>>>
>>>>>>>> ;;7) +, -, *, / between two arrays
>>>>>>>> ;;also missing for i. this works:
>>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>>        kArr2[] fillarray 10, 20, 30
>>>>>>>>        kArr3[] = kArr1 + kArr2
>>>>>>>> ;;but this does not:
>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>        iArr2[] fillarray 10, 20, 30
>>>>>>>>        iArr3[] = iArr1 + iArr2
>>>>>>>>
>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>>>
>>>>>>>> ;;9) maparray
>>>>>>>> ;;as well:
>>>>>>>>        iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>>        iArrRes[] init  7
>>>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>
>>>>>>>> ;;10) =
>>>>>>>> ;;miss i-time operations. this is possible:
>>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>>        kArr2[] = kArr1
>>>>>>>> ;;but this returns "nul opadr":
>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>       iArr2[] = iArr1
>>>>>>>>
>>>>>>>> endin
>>>>>>>> 
>>>>>>>>
>>>>>>>> 
>>>>>>>> i1 0 1
>>>>>>>> e
>>>>>>>> 
>>>>>>>>
>>>>>>>> 
>>>>>>>>
>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>> _______________________________________________
>>>>>>>> Csound-devel mailing list
>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>
>>>>>>>
>>>>>>> ------------------------------------------------------------------------------
>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>> this first edition is now available. Download your free book today!
>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>> _______________________________________________
>>>>>>> Csound-devel mailing list
>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> ------------------------------------------------------------------------------
>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>> this first edition is now available. Download your free book today!
>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>> _______________________________________________
>>>>>> Csound-devel mailing list
>>>>>> Csound-devel@lists.sourceforge.net
>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>> applications. Written by three acclaimed leaders in the field,
>>>>> this first edition is now available. Download your free book today!
>>>>> http://p.sf.net/sfu/NeoTech
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>>
>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>> applications. Written by three acclaimed leaders in the field,
>>>> this first edition is now available. Download your free book today!
>>>> http://p.sf.net/sfu/NeoTech
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>> ------------------------------------------------------------------------------
>> Learn Graph Databases - Download FREE O'Reilly Book
>> "Graph Databases" is the definitive new guide to graph databases and their
>> applications. Written by three acclaimed leaders in the field,
>> this first edition is now available. Download your free book today!
>> http://p.sf.net/sfu/NeoTech
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-17 22:44
FromSteven Yi
SubjectRe: [Cs-dev] array feature wish list (I)
Okay, now I'm getting a,c,e, and crash too. At least it's matching behavior. :)

On Thu, Apr 17, 2014 at 5:40 PM, Steven Yi  wrote:
> I'm getting:
>
> instr 1:  #i0 = 6.000
> a
> b
> c
> d
>
> Though sometimes I also get:
>
> instr 1:  #i0 = 6.000
> (null)
> (null)
> (null)
> (null)
>
> which makes this very odd. I'll check futher.
>
> On Thu, Apr 17, 2014 at 5:00 PM, joachim heintz  wrote:
>> yes, slicearray seems to work. while testing, i found that string arrays
>> return the wrong value for an index. this is a simple example:
>>
>> SArr[]     fillarray  "a", "b", "c", "d", "e", "f"
>> print lenarray(SArr) ;6
>> printf_i "%s\n", 1, SArr[0] ;a
>> printf_i "%s\n", 1, SArr[1] ;c!
>> printf_i "%s\n", 1, SArr[2] ;e!
>> printf_i "%s\n", 1, SArr[3] ;segfault
>>
>> probably a simple mistake?
>>
>>         joachim
>>
>> Am 17.04.2014 17:06, schrieb Steven Yi:
>>> I think I've made slicearray work generically now for any type.
>>>
>>> Joachim: could you pull from develop and try with your various array tests?
>>>
>>> On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi  wrote:
>>>> I'll take a look at the type system/string stuff later today.
>>>>
>>>> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>>>>> Looks as if one of my commits failed.  Version of
>>>>> 2014-04-16 19:28:50
>>>>> should have many fixes -- no idea how that happened
>>>>>
>>>>> I *think* most string-array operations are broken but am not sure, or
>>>>> f how to check and fix.
>>>>>
>>>>> Quoting joachim heintz :
>>>>>
>>>>>> this is the commit:
>>>>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>>>>> Author: John ffitch 
>>>>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>>>>
>>>>>> did you push after this?
>>>>>>
>>>>>>
>>>>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>>>>> bizarre -- I do not get those errors/problems.  When did you check it
>>>>>>> out/pull?
>>>>>>> There was a typo in i-array arithmetic, now fixed
>>>>>>>
>>>>>>> Quoting joachim heintz :
>>>>>>>
>>>>>>>> i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>>>>
>>>>>>>>
>>>>>>>> i can confirm the three examples you mentioned are not working. the
>>>>>>>> third example should read:
>>>>>>>> ***    copya2ftab iArr, giSine
>>>>>>>> it was a typo in my initial list.
>>>>>>>>
>>>>>>>>
>>>>>>>> number 6) does not give an error, but the results are wrong:
>>>>>>>>        iArr1[]  fillarray 1, 2, 3
>>>>>>>>        iArr2[] = iArr1 + 10
>>>>>>>>        print iArr1[0], iArr1[1], iArr1[2]
>>>>>>>>        print iArr2[0], iArr2[1], iArr2[2]
>>>>>>>> returns:
>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>>>>> or sometimes something like:
>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>> instr 1:  #i23 =
>>>>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>>>>     #i24 =
>>>>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>>>>     #i25 = 0.000
>>>>>>>>
>>>>>>>>
>>>>>>>> same for 7):
>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>        iArr2[] fillarray 10, 20, 30
>>>>>>>>        iArr3[] = iArr1 + iArr2
>>>>>>>>        print iArr3[0], iArr3[1], iArr3[2]
>>>>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>>>>> or some astronomical high numbers.
>>>>>>>>
>>>>>>>>
>>>>>>>> 8): maxarray and scalearray are working for i-arrays; minarray and
>>>>>>>> sumarray not.
>>>>>>>> * minarray:
>>>>>>>>        iArr[] fillarray 1, 2, 3
>>>>>>>>        iMin minarray iArr
>>>>>>>> -> null opadr null opadr %s
>>>>>>>> * sumarray:
>>>>>>>>        iArr[] fillarray 1, 2, 3
>>>>>>>>        iMin sumarray iArr
>>>>>>>> -> error:  Unable to find opcode entry for 'sumarray' with matching
>>>>>>>> argument types:
>>>>>>>> Found: i sumarray i[]
>>>>>>>>
>>>>>>>>
>>>>>>>> 9) maparray is not working for me:
>>>>>>>>        iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>>        iArrRes[] init  7
>>>>>>>>        iArrRes maparray iArrSrc, "sqrt"
>>>>>>>> -> error:  Unable to find opcode entry for 'maparray' with matching
>>>>>>>> argument types:
>>>>>>>> Found: i[] maparray i[]S
>>>>>>>>
>>>>>>>>
>>>>>>>> 10) yes this works now:
>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>       iArr2[] = iArr1
>>>>>>>> great!
>>>>>>>>
>>>>>>>>
>>>>>>>> best -
>>>>>>>>
>>>>>>>>      joachim
>>>>>>>>
>>>>>>>>
>>>>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>>>>> More after initial testing
>>>>>>>>> Of Joachim's examples the following do not work
>>>>>>>>>
>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>>>>
>>>>>>>>> All other lines parse and run
>>>>>>>>>
>>>>>>>>> The first of these is in Steve's area.  The second is my area and I
>>>>>>>>> will look at it.  Do not understand the third.  Must test the 8)
>>>>>>>>> versions soon
>>>>>>>>>
>>>>>>>>> Nearly time for breakfast
>>>>>>>>>
>>>>>>>>> ==John ffitch
>>>>>>>>>
>>>>>>>>> 
>>>>>>>>>
>>>>>>>>> 
>>>>>>>>>
>>>>>>>>> instr 1
>>>>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>>        iArr2[] fillarray 4, 5, 6
>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>
>>>>>>>>> ;;2) lenarray
>>>>>>>>>        Sarr[] init 3
>>>>>>>>>        print lenarray(Sarr)
>>>>>>>>>
>>>>>>>>> ;;3) slicearray
>>>>>>>>>       iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>>>>       iArr1[] init       5
>>>>>>>>>       iArr2[] init       4
>>>>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>>>>> ;;b) same for S-arrays:
>>>>>>>>>       SArr[]  init       9
>>>>>>>>>       SArr1[] init       5
>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>
>>>>>>>>> ;;4) copyf2array
>>>>>>>>>        giSine  ftgen   0, 0, 8, 10, 1
>>>>>>>>>        iArr[]  init       8
>>>>>>>>>        copyf2array iArr, giSine
>>>>>>>>>
>>>>>>>>> ;;5) copya2ftab
>>>>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>>>>
>>>>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>>>>> ;;do not work at i-rate. this works:
>>>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>>>        kArr2[] = kArr1 + 10
>>>>>>>>> ;;but this does not:
>>>>>>>>>        iArr1[]  array 1, 2, 3
>>>>>>>>>        iArr2[] = iArr1 + 10
>>>>>>>>>
>>>>>>>>> ;;7) +, -, *, / between two arrays
>>>>>>>>> ;;also missing for i. this works:
>>>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>>>        kArr2[] fillarray 10, 20, 30
>>>>>>>>>        kArr3[] = kArr1 + kArr2
>>>>>>>>> ;;but this does not:
>>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>>        iArr2[] fillarray 10, 20, 30
>>>>>>>>>        iArr3[] = iArr1 + iArr2
>>>>>>>>>
>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>>>>
>>>>>>>>> ;;9) maparray
>>>>>>>>> ;;as well:
>>>>>>>>>        iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>>>        iArrRes[] init  7
>>>>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>
>>>>>>>>> ;;10) =
>>>>>>>>> ;;miss i-time operations. this is possible:
>>>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>>>        kArr2[] = kArr1
>>>>>>>>> ;;but this returns "nul opadr":
>>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>>       iArr2[] = iArr1
>>>>>>>>>
>>>>>>>>> endin
>>>>>>>>> 
>>>>>>>>>
>>>>>>>>> 
>>>>>>>>> i1 0 1
>>>>>>>>> e
>>>>>>>>> 
>>>>>>>>>
>>>>>>>>> 
>>>>>>>>>
>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>> _______________________________________________
>>>>>>>>> Csound-devel mailing list
>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>
>>>>>>>>
>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>> _______________________________________________
>>>>>>>> Csound-devel mailing list
>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ------------------------------------------------------------------------------
>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>> this first edition is now available. Download your free book today!
>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>> _______________________________________________
>>>>>>> Csound-devel mailing list
>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>
>>>>>>
>>>>>> ------------------------------------------------------------------------------
>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>> this first edition is now available. Download your free book today!
>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>> _______________________________________________
>>>>>> Csound-devel mailing list
>>>>>> Csound-devel@lists.sourceforge.net
>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>> applications. Written by three acclaimed leaders in the field,
>>>>> this first edition is now available. Download your free book today!
>>>>> http://p.sf.net/sfu/NeoTech
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>
>>> ------------------------------------------------------------------------------
>>> Learn Graph Databases - Download FREE O'Reilly Book
>>> "Graph Databases" is the definitive new guide to graph databases and their
>>> applications. Written by three acclaimed leaders in the field,
>>> this first edition is now available. Download your free book today!
>>> http://p.sf.net/sfu/NeoTech
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>
>>
>> ------------------------------------------------------------------------------
>> Learn Graph Databases - Download FREE O'Reilly Book
>> "Graph Databases" is the definitive new guide to graph databases and their
>> applications. Written by three acclaimed leaders in the field,
>> this first edition is now available. Download your free book today!
>> http://p.sf.net/sfu/NeoTech
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-17 22:52
FromSteven Yi
SubjectRe: [Cs-dev] array feature wish list (I)
Oh I didn't pick up at first, this is an issue with fillarray, which I
hadn't touched. I see the issue, I'll have something in a moment.

On Thu, Apr 17, 2014 at 5:44 PM, Steven Yi  wrote:
> Okay, now I'm getting a,c,e, and crash too. At least it's matching behavior. :)
>
> On Thu, Apr 17, 2014 at 5:40 PM, Steven Yi  wrote:
>> I'm getting:
>>
>> instr 1:  #i0 = 6.000
>> a
>> b
>> c
>> d
>>
>> Though sometimes I also get:
>>
>> instr 1:  #i0 = 6.000
>> (null)
>> (null)
>> (null)
>> (null)
>>
>> which makes this very odd. I'll check futher.
>>
>> On Thu, Apr 17, 2014 at 5:00 PM, joachim heintz  wrote:
>>> yes, slicearray seems to work. while testing, i found that string arrays
>>> return the wrong value for an index. this is a simple example:
>>>
>>> SArr[]     fillarray  "a", "b", "c", "d", "e", "f"
>>> print lenarray(SArr) ;6
>>> printf_i "%s\n", 1, SArr[0] ;a
>>> printf_i "%s\n", 1, SArr[1] ;c!
>>> printf_i "%s\n", 1, SArr[2] ;e!
>>> printf_i "%s\n", 1, SArr[3] ;segfault
>>>
>>> probably a simple mistake?
>>>
>>>         joachim
>>>
>>> Am 17.04.2014 17:06, schrieb Steven Yi:
>>>> I think I've made slicearray work generically now for any type.
>>>>
>>>> Joachim: could you pull from develop and try with your various array tests?
>>>>
>>>> On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi  wrote:
>>>>> I'll take a look at the type system/string stuff later today.
>>>>>
>>>>> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>>>>>> Looks as if one of my commits failed.  Version of
>>>>>> 2014-04-16 19:28:50
>>>>>> should have many fixes -- no idea how that happened
>>>>>>
>>>>>> I *think* most string-array operations are broken but am not sure, or
>>>>>> f how to check and fix.
>>>>>>
>>>>>> Quoting joachim heintz :
>>>>>>
>>>>>>> this is the commit:
>>>>>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>>>>>> Author: John ffitch 
>>>>>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>>>>>
>>>>>>> did you push after this?
>>>>>>>
>>>>>>>
>>>>>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>>>>>> bizarre -- I do not get those errors/problems.  When did you check it
>>>>>>>> out/pull?
>>>>>>>> There was a typo in i-array arithmetic, now fixed
>>>>>>>>
>>>>>>>> Quoting joachim heintz :
>>>>>>>>
>>>>>>>>> i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> i can confirm the three examples you mentioned are not working. the
>>>>>>>>> third example should read:
>>>>>>>>> ***    copya2ftab iArr, giSine
>>>>>>>>> it was a typo in my initial list.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> number 6) does not give an error, but the results are wrong:
>>>>>>>>>        iArr1[]  fillarray 1, 2, 3
>>>>>>>>>        iArr2[] = iArr1 + 10
>>>>>>>>>        print iArr1[0], iArr1[1], iArr1[2]
>>>>>>>>>        print iArr2[0], iArr2[1], iArr2[2]
>>>>>>>>> returns:
>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>>>>>> or sometimes something like:
>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>> instr 1:  #i23 =
>>>>>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>>>>>     #i24 =
>>>>>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>>>>>     #i25 = 0.000
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> same for 7):
>>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>>        iArr2[] fillarray 10, 20, 30
>>>>>>>>>        iArr3[] = iArr1 + iArr2
>>>>>>>>>        print iArr3[0], iArr3[1], iArr3[2]
>>>>>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>>>>>> or some astronomical high numbers.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> 8): maxarray and scalearray are working for i-arrays; minarray and
>>>>>>>>> sumarray not.
>>>>>>>>> * minarray:
>>>>>>>>>        iArr[] fillarray 1, 2, 3
>>>>>>>>>        iMin minarray iArr
>>>>>>>>> -> null opadr null opadr %s
>>>>>>>>> * sumarray:
>>>>>>>>>        iArr[] fillarray 1, 2, 3
>>>>>>>>>        iMin sumarray iArr
>>>>>>>>> -> error:  Unable to find opcode entry for 'sumarray' with matching
>>>>>>>>> argument types:
>>>>>>>>> Found: i sumarray i[]
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> 9) maparray is not working for me:
>>>>>>>>>        iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>>>        iArrRes[] init  7
>>>>>>>>>        iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>> -> error:  Unable to find opcode entry for 'maparray' with matching
>>>>>>>>> argument types:
>>>>>>>>> Found: i[] maparray i[]S
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> 10) yes this works now:
>>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>>       iArr2[] = iArr1
>>>>>>>>> great!
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> best -
>>>>>>>>>
>>>>>>>>>      joachim
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>>>>>> More after initial testing
>>>>>>>>>> Of Joachim's examples the following do not work
>>>>>>>>>>
>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>>>>>
>>>>>>>>>> All other lines parse and run
>>>>>>>>>>
>>>>>>>>>> The first of these is in Steve's area.  The second is my area and I
>>>>>>>>>> will look at it.  Do not understand the third.  Must test the 8)
>>>>>>>>>> versions soon
>>>>>>>>>>
>>>>>>>>>> Nearly time for breakfast
>>>>>>>>>>
>>>>>>>>>> ==John ffitch
>>>>>>>>>>
>>>>>>>>>> 
>>>>>>>>>>
>>>>>>>>>> 
>>>>>>>>>>
>>>>>>>>>> instr 1
>>>>>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>>>        iArr2[] fillarray 4, 5, 6
>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>
>>>>>>>>>> ;;2) lenarray
>>>>>>>>>>        Sarr[] init 3
>>>>>>>>>>        print lenarray(Sarr)
>>>>>>>>>>
>>>>>>>>>> ;;3) slicearray
>>>>>>>>>>       iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>>>>>       iArr1[] init       5
>>>>>>>>>>       iArr2[] init       4
>>>>>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>>>>>> ;;b) same for S-arrays:
>>>>>>>>>>       SArr[]  init       9
>>>>>>>>>>       SArr1[] init       5
>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>
>>>>>>>>>> ;;4) copyf2array
>>>>>>>>>>        giSine  ftgen   0, 0, 8, 10, 1
>>>>>>>>>>        iArr[]  init       8
>>>>>>>>>>        copyf2array iArr, giSine
>>>>>>>>>>
>>>>>>>>>> ;;5) copya2ftab
>>>>>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>>>>>
>>>>>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>>>>>> ;;do not work at i-rate. this works:
>>>>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>>>>        kArr2[] = kArr1 + 10
>>>>>>>>>> ;;but this does not:
>>>>>>>>>>        iArr1[]  array 1, 2, 3
>>>>>>>>>>        iArr2[] = iArr1 + 10
>>>>>>>>>>
>>>>>>>>>> ;;7) +, -, *, / between two arrays
>>>>>>>>>> ;;also missing for i. this works:
>>>>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>>>>        kArr2[] fillarray 10, 20, 30
>>>>>>>>>>        kArr3[] = kArr1 + kArr2
>>>>>>>>>> ;;but this does not:
>>>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>>>        iArr2[] fillarray 10, 20, 30
>>>>>>>>>>        iArr3[] = iArr1 + iArr2
>>>>>>>>>>
>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>>>>>
>>>>>>>>>> ;;9) maparray
>>>>>>>>>> ;;as well:
>>>>>>>>>>        iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>>>>        iArrRes[] init  7
>>>>>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>
>>>>>>>>>> ;;10) =
>>>>>>>>>> ;;miss i-time operations. this is possible:
>>>>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>>>>        kArr2[] = kArr1
>>>>>>>>>> ;;but this returns "nul opadr":
>>>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>>>       iArr2[] = iArr1
>>>>>>>>>>
>>>>>>>>>> endin
>>>>>>>>>> 
>>>>>>>>>>
>>>>>>>>>> 
>>>>>>>>>> i1 0 1
>>>>>>>>>> e
>>>>>>>>>> 
>>>>>>>>>>
>>>>>>>>>> 
>>>>>>>>>>
>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>> _______________________________________________
>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>> _______________________________________________
>>>>>>>>> Csound-devel mailing list
>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>> _______________________________________________
>>>>>>>> Csound-devel mailing list
>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>
>>>>>>>
>>>>>>> ------------------------------------------------------------------------------
>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>> this first edition is now available. Download your free book today!
>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>> _______________________________________________
>>>>>>> Csound-devel mailing list
>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> ------------------------------------------------------------------------------
>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>> this first edition is now available. Download your free book today!
>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>> _______________________________________________
>>>>>> Csound-devel mailing list
>>>>>> Csound-devel@lists.sourceforge.net
>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>> applications. Written by three acclaimed leaders in the field,
>>>> this first edition is now available. Download your free book today!
>>>> http://p.sf.net/sfu/NeoTech
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Learn Graph Databases - Download FREE O'Reilly Book
>>> "Graph Databases" is the definitive new guide to graph databases and their
>>> applications. Written by three acclaimed leaders in the field,
>>> this first edition is now available. Download your free book today!
>>> http://p.sf.net/sfu/NeoTech
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-17 23:02
FromSteven Yi
SubjectRe: [Cs-dev] array feature wish list (I)
Okay, fillarray should be working now for strings. :)

On Thu, Apr 17, 2014 at 5:52 PM, Steven Yi  wrote:
> Oh I didn't pick up at first, this is an issue with fillarray, which I
> hadn't touched. I see the issue, I'll have something in a moment.
>
> On Thu, Apr 17, 2014 at 5:44 PM, Steven Yi  wrote:
>> Okay, now I'm getting a,c,e, and crash too. At least it's matching behavior. :)
>>
>> On Thu, Apr 17, 2014 at 5:40 PM, Steven Yi  wrote:
>>> I'm getting:
>>>
>>> instr 1:  #i0 = 6.000
>>> a
>>> b
>>> c
>>> d
>>>
>>> Though sometimes I also get:
>>>
>>> instr 1:  #i0 = 6.000
>>> (null)
>>> (null)
>>> (null)
>>> (null)
>>>
>>> which makes this very odd. I'll check futher.
>>>
>>> On Thu, Apr 17, 2014 at 5:00 PM, joachim heintz  wrote:
>>>> yes, slicearray seems to work. while testing, i found that string arrays
>>>> return the wrong value for an index. this is a simple example:
>>>>
>>>> SArr[]     fillarray  "a", "b", "c", "d", "e", "f"
>>>> print lenarray(SArr) ;6
>>>> printf_i "%s\n", 1, SArr[0] ;a
>>>> printf_i "%s\n", 1, SArr[1] ;c!
>>>> printf_i "%s\n", 1, SArr[2] ;e!
>>>> printf_i "%s\n", 1, SArr[3] ;segfault
>>>>
>>>> probably a simple mistake?
>>>>
>>>>         joachim
>>>>
>>>> Am 17.04.2014 17:06, schrieb Steven Yi:
>>>>> I think I've made slicearray work generically now for any type.
>>>>>
>>>>> Joachim: could you pull from develop and try with your various array tests?
>>>>>
>>>>> On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi  wrote:
>>>>>> I'll take a look at the type system/string stuff later today.
>>>>>>
>>>>>> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>>>>>>> Looks as if one of my commits failed.  Version of
>>>>>>> 2014-04-16 19:28:50
>>>>>>> should have many fixes -- no idea how that happened
>>>>>>>
>>>>>>> I *think* most string-array operations are broken but am not sure, or
>>>>>>> f how to check and fix.
>>>>>>>
>>>>>>> Quoting joachim heintz :
>>>>>>>
>>>>>>>> this is the commit:
>>>>>>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>>>>>>> Author: John ffitch 
>>>>>>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>>>>>>
>>>>>>>> did you push after this?
>>>>>>>>
>>>>>>>>
>>>>>>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>>>>>>> bizarre -- I do not get those errors/problems.  When did you check it
>>>>>>>>> out/pull?
>>>>>>>>> There was a typo in i-array arithmetic, now fixed
>>>>>>>>>
>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>
>>>>>>>>>> i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> i can confirm the three examples you mentioned are not working. the
>>>>>>>>>> third example should read:
>>>>>>>>>> ***    copya2ftab iArr, giSine
>>>>>>>>>> it was a typo in my initial list.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> number 6) does not give an error, but the results are wrong:
>>>>>>>>>>        iArr1[]  fillarray 1, 2, 3
>>>>>>>>>>        iArr2[] = iArr1 + 10
>>>>>>>>>>        print iArr1[0], iArr1[1], iArr1[2]
>>>>>>>>>>        print iArr2[0], iArr2[1], iArr2[2]
>>>>>>>>>> returns:
>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>>>>>>> or sometimes something like:
>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>> instr 1:  #i23 =
>>>>>>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>>>>>>     #i24 =
>>>>>>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>>>>>>     #i25 = 0.000
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> same for 7):
>>>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>>>        iArr2[] fillarray 10, 20, 30
>>>>>>>>>>        iArr3[] = iArr1 + iArr2
>>>>>>>>>>        print iArr3[0], iArr3[1], iArr3[2]
>>>>>>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>>>>>>> or some astronomical high numbers.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> 8): maxarray and scalearray are working for i-arrays; minarray and
>>>>>>>>>> sumarray not.
>>>>>>>>>> * minarray:
>>>>>>>>>>        iArr[] fillarray 1, 2, 3
>>>>>>>>>>        iMin minarray iArr
>>>>>>>>>> -> null opadr null opadr %s
>>>>>>>>>> * sumarray:
>>>>>>>>>>        iArr[] fillarray 1, 2, 3
>>>>>>>>>>        iMin sumarray iArr
>>>>>>>>>> -> error:  Unable to find opcode entry for 'sumarray' with matching
>>>>>>>>>> argument types:
>>>>>>>>>> Found: i sumarray i[]
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> 9) maparray is not working for me:
>>>>>>>>>>        iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>>>>        iArrRes[] init  7
>>>>>>>>>>        iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>> -> error:  Unable to find opcode entry for 'maparray' with matching
>>>>>>>>>> argument types:
>>>>>>>>>> Found: i[] maparray i[]S
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> 10) yes this works now:
>>>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>>>       iArr2[] = iArr1
>>>>>>>>>> great!
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> best -
>>>>>>>>>>
>>>>>>>>>>      joachim
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>>>>>>> More after initial testing
>>>>>>>>>>> Of Joachim's examples the following do not work
>>>>>>>>>>>
>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>>>>>>
>>>>>>>>>>> All other lines parse and run
>>>>>>>>>>>
>>>>>>>>>>> The first of these is in Steve's area.  The second is my area and I
>>>>>>>>>>> will look at it.  Do not understand the third.  Must test the 8)
>>>>>>>>>>> versions soon
>>>>>>>>>>>
>>>>>>>>>>> Nearly time for breakfast
>>>>>>>>>>>
>>>>>>>>>>> ==John ffitch
>>>>>>>>>>>
>>>>>>>>>>> 
>>>>>>>>>>>
>>>>>>>>>>> 
>>>>>>>>>>>
>>>>>>>>>>> instr 1
>>>>>>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>        iArr2[] fillarray 4, 5, 6
>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>
>>>>>>>>>>> ;;2) lenarray
>>>>>>>>>>>        Sarr[] init 3
>>>>>>>>>>>        print lenarray(Sarr)
>>>>>>>>>>>
>>>>>>>>>>> ;;3) slicearray
>>>>>>>>>>>       iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>>>>>>       iArr1[] init       5
>>>>>>>>>>>       iArr2[] init       4
>>>>>>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>>>>>>> ;;b) same for S-arrays:
>>>>>>>>>>>       SArr[]  init       9
>>>>>>>>>>>       SArr1[] init       5
>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>
>>>>>>>>>>> ;;4) copyf2array
>>>>>>>>>>>        giSine  ftgen   0, 0, 8, 10, 1
>>>>>>>>>>>        iArr[]  init       8
>>>>>>>>>>>        copyf2array iArr, giSine
>>>>>>>>>>>
>>>>>>>>>>> ;;5) copya2ftab
>>>>>>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>>>>>>
>>>>>>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>>>>>>> ;;do not work at i-rate. this works:
>>>>>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>        kArr2[] = kArr1 + 10
>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>        iArr1[]  array 1, 2, 3
>>>>>>>>>>>        iArr2[] = iArr1 + 10
>>>>>>>>>>>
>>>>>>>>>>> ;;7) +, -, *, / between two arrays
>>>>>>>>>>> ;;also missing for i. this works:
>>>>>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>        kArr2[] fillarray 10, 20, 30
>>>>>>>>>>>        kArr3[] = kArr1 + kArr2
>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>        iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>        iArr3[] = iArr1 + iArr2
>>>>>>>>>>>
>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>>>>>>
>>>>>>>>>>> ;;9) maparray
>>>>>>>>>>> ;;as well:
>>>>>>>>>>>        iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>>>>>        iArrRes[] init  7
>>>>>>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>
>>>>>>>>>>> ;;10) =
>>>>>>>>>>> ;;miss i-time operations. this is possible:
>>>>>>>>>>>        kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>        kArr2[] = kArr1
>>>>>>>>>>> ;;but this returns "nul opadr":
>>>>>>>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>       iArr2[] = iArr1
>>>>>>>>>>>
>>>>>>>>>>> endin
>>>>>>>>>>> 
>>>>>>>>>>>
>>>>>>>>>>> 
>>>>>>>>>>> i1 0 1
>>>>>>>>>>> e
>>>>>>>>>>> 
>>>>>>>>>>>
>>>>>>>>>>> 
>>>>>>>>>>>
>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>> _______________________________________________
>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>> _______________________________________________
>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>> _______________________________________________
>>>>>>>>> Csound-devel mailing list
>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>
>>>>>>>>
>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>> _______________________________________________
>>>>>>>> Csound-devel mailing list
>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ------------------------------------------------------------------------------
>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>> this first edition is now available. Download your free book today!
>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>> _______________________________________________
>>>>>>> Csound-devel mailing list
>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>> applications. Written by three acclaimed leaders in the field,
>>>>> this first edition is now available. Download your free book today!
>>>>> http://p.sf.net/sfu/NeoTech
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>> applications. Written by three acclaimed leaders in the field,
>>>> this first edition is now available. Download your free book today!
>>>> http://p.sf.net/sfu/NeoTech
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-18 08:56
Fromjoachim heintz
SubjectRe: [Cs-dev] array feature wish list (I)
it does. now abcd is abcd, and it's probably better for us all if the 
alphabet is happy (or at least at its place).
((or perhaps not; not sure the more i think about it.))
for any case: thanks for the quick fix!

	joachim


Am 18.04.2014 00:02, schrieb Steven Yi:
> Okay, fillarray should be working now for strings. :)
>
> On Thu, Apr 17, 2014 at 5:52 PM, Steven Yi  wrote:
>> Oh I didn't pick up at first, this is an issue with fillarray, which I
>> hadn't touched. I see the issue, I'll have something in a moment.
>>
>> On Thu, Apr 17, 2014 at 5:44 PM, Steven Yi  wrote:
>>> Okay, now I'm getting a,c,e, and crash too. At least it's matching behavior. :)
>>>
>>> On Thu, Apr 17, 2014 at 5:40 PM, Steven Yi  wrote:
>>>> I'm getting:
>>>>
>>>> instr 1:  #i0 = 6.000
>>>> a
>>>> b
>>>> c
>>>> d
>>>>
>>>> Though sometimes I also get:
>>>>
>>>> instr 1:  #i0 = 6.000
>>>> (null)
>>>> (null)
>>>> (null)
>>>> (null)
>>>>
>>>> which makes this very odd. I'll check futher.
>>>>
>>>> On Thu, Apr 17, 2014 at 5:00 PM, joachim heintz  wrote:
>>>>> yes, slicearray seems to work. while testing, i found that string arrays
>>>>> return the wrong value for an index. this is a simple example:
>>>>>
>>>>> SArr[]     fillarray  "a", "b", "c", "d", "e", "f"
>>>>> print lenarray(SArr) ;6
>>>>> printf_i "%s\n", 1, SArr[0] ;a
>>>>> printf_i "%s\n", 1, SArr[1] ;c!
>>>>> printf_i "%s\n", 1, SArr[2] ;e!
>>>>> printf_i "%s\n", 1, SArr[3] ;segfault
>>>>>
>>>>> probably a simple mistake?
>>>>>
>>>>>          joachim
>>>>>
>>>>> Am 17.04.2014 17:06, schrieb Steven Yi:
>>>>>> I think I've made slicearray work generically now for any type.
>>>>>>
>>>>>> Joachim: could you pull from develop and try with your various array tests?
>>>>>>
>>>>>> On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi  wrote:
>>>>>>> I'll take a look at the type system/string stuff later today.
>>>>>>>
>>>>>>> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>>>>>>>> Looks as if one of my commits failed.  Version of
>>>>>>>> 2014-04-16 19:28:50
>>>>>>>> should have many fixes -- no idea how that happened
>>>>>>>>
>>>>>>>> I *think* most string-array operations are broken but am not sure, or
>>>>>>>> f how to check and fix.
>>>>>>>>
>>>>>>>> Quoting joachim heintz :
>>>>>>>>
>>>>>>>>> this is the commit:
>>>>>>>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>>>>>>>> Author: John ffitch 
>>>>>>>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>>>>>>>
>>>>>>>>> did you push after this?
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>>>>>>>> bizarre -- I do not get those errors/problems.  When did you check it
>>>>>>>>>> out/pull?
>>>>>>>>>> There was a typo in i-array arithmetic, now fixed
>>>>>>>>>>
>>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>>
>>>>>>>>>>> i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> i can confirm the three examples you mentioned are not working. the
>>>>>>>>>>> third example should read:
>>>>>>>>>>> ***    copya2ftab iArr, giSine
>>>>>>>>>>> it was a typo in my initial list.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> number 6) does not give an error, but the results are wrong:
>>>>>>>>>>>         iArr1[]  fillarray 1, 2, 3
>>>>>>>>>>>         iArr2[] = iArr1 + 10
>>>>>>>>>>>         print iArr1[0], iArr1[1], iArr1[2]
>>>>>>>>>>>         print iArr2[0], iArr2[1], iArr2[2]
>>>>>>>>>>> returns:
>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>>>>>>>> or sometimes something like:
>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>> instr 1:  #i23 =
>>>>>>>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>>>>>>>      #i24 =
>>>>>>>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>>>>>>>      #i25 = 0.000
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> same for 7):
>>>>>>>>>>>         iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>         iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>         iArr3[] = iArr1 + iArr2
>>>>>>>>>>>         print iArr3[0], iArr3[1], iArr3[2]
>>>>>>>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>>>>>>>> or some astronomical high numbers.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> 8): maxarray and scalearray are working for i-arrays; minarray and
>>>>>>>>>>> sumarray not.
>>>>>>>>>>> * minarray:
>>>>>>>>>>>         iArr[] fillarray 1, 2, 3
>>>>>>>>>>>         iMin minarray iArr
>>>>>>>>>>> -> null opadr null opadr %s
>>>>>>>>>>> * sumarray:
>>>>>>>>>>>         iArr[] fillarray 1, 2, 3
>>>>>>>>>>>         iMin sumarray iArr
>>>>>>>>>>> -> error:  Unable to find opcode entry for 'sumarray' with matching
>>>>>>>>>>> argument types:
>>>>>>>>>>> Found: i sumarray i[]
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> 9) maparray is not working for me:
>>>>>>>>>>>         iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>>>>>         iArrRes[] init  7
>>>>>>>>>>>         iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>> -> error:  Unable to find opcode entry for 'maparray' with matching
>>>>>>>>>>> argument types:
>>>>>>>>>>> Found: i[] maparray i[]S
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> 10) yes this works now:
>>>>>>>>>>>         iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>        iArr2[] = iArr1
>>>>>>>>>>> great!
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> best -
>>>>>>>>>>>
>>>>>>>>>>>       joachim
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>>>>>>>> More after initial testing
>>>>>>>>>>>> Of Joachim's examples the following do not work
>>>>>>>>>>>>
>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>>>>>>>
>>>>>>>>>>>> All other lines parse and run
>>>>>>>>>>>>
>>>>>>>>>>>> The first of these is in Steve's area.  The second is my area and I
>>>>>>>>>>>> will look at it.  Do not understand the third.  Must test the 8)
>>>>>>>>>>>> versions soon
>>>>>>>>>>>>
>>>>>>>>>>>> Nearly time for breakfast
>>>>>>>>>>>>
>>>>>>>>>>>> ==John ffitch
>>>>>>>>>>>>
>>>>>>>>>>>> 
>>>>>>>>>>>>
>>>>>>>>>>>> 
>>>>>>>>>>>>
>>>>>>>>>>>> instr 1
>>>>>>>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>>>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>>>>>>>         iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>         iArr2[] fillarray 4, 5, 6
>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>
>>>>>>>>>>>> ;;2) lenarray
>>>>>>>>>>>>         Sarr[] init 3
>>>>>>>>>>>>         print lenarray(Sarr)
>>>>>>>>>>>>
>>>>>>>>>>>> ;;3) slicearray
>>>>>>>>>>>>        iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>>>>>>>        iArr1[] init       5
>>>>>>>>>>>>        iArr2[] init       4
>>>>>>>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>>>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>>>>>>>> ;;b) same for S-arrays:
>>>>>>>>>>>>        SArr[]  init       9
>>>>>>>>>>>>        SArr1[] init       5
>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>
>>>>>>>>>>>> ;;4) copyf2array
>>>>>>>>>>>>         giSine  ftgen   0, 0, 8, 10, 1
>>>>>>>>>>>>         iArr[]  init       8
>>>>>>>>>>>>         copyf2array iArr, giSine
>>>>>>>>>>>>
>>>>>>>>>>>> ;;5) copya2ftab
>>>>>>>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>>>>>>>
>>>>>>>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>>>>>>>> ;;do not work at i-rate. this works:
>>>>>>>>>>>>         kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>         kArr2[] = kArr1 + 10
>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>         iArr1[]  array 1, 2, 3
>>>>>>>>>>>>         iArr2[] = iArr1 + 10
>>>>>>>>>>>>
>>>>>>>>>>>> ;;7) +, -, *, / between two arrays
>>>>>>>>>>>> ;;also missing for i. this works:
>>>>>>>>>>>>         kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>         kArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>         kArr3[] = kArr1 + kArr2
>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>         iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>         iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>         iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>
>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>>>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>>>>>>>
>>>>>>>>>>>> ;;9) maparray
>>>>>>>>>>>> ;;as well:
>>>>>>>>>>>>         iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>>>>>>         iArrRes[] init  7
>>>>>>>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>>
>>>>>>>>>>>> ;;10) =
>>>>>>>>>>>> ;;miss i-time operations. this is possible:
>>>>>>>>>>>>         kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>         kArr2[] = kArr1
>>>>>>>>>>>> ;;but this returns "nul opadr":
>>>>>>>>>>>>         iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>        iArr2[] = iArr1
>>>>>>>>>>>>
>>>>>>>>>>>> endin
>>>>>>>>>>>> 
>>>>>>>>>>>>
>>>>>>>>>>>> 
>>>>>>>>>>>> i1 0 1
>>>>>>>>>>>> e
>>>>>>>>>>>> 
>>>>>>>>>>>>
>>>>>>>>>>>> 
>>>>>>>>>>>>
>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>> _______________________________________________
>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>> _______________________________________________
>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>> _______________________________________________
>>>>>>>>> Csound-devel mailing list
>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>> _______________________________________________
>>>>>>>> Csound-devel mailing list
>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>
>>>>>> ------------------------------------------------------------------------------
>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>> this first edition is now available. Download your free book today!
>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>> _______________________________________________
>>>>>> Csound-devel mailing list
>>>>>> Csound-devel@lists.sourceforge.net
>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>> applications. Written by three acclaimed leaders in the field,
>>>>> this first edition is now available. Download your free book today!
>>>>> http://p.sf.net/sfu/NeoTech
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-18 16:00
FromSteven Yi
SubjectRe: [Cs-dev] array feature wish list (I)
Sure thing!  BTW: I am uncertain as to where we are now with this list
of items.  Could you maybe update the github issue with a note of what
is working and what remains to be fixed?

On Fri, Apr 18, 2014 at 3:56 AM, joachim heintz  wrote:
> it does. now abcd is abcd, and it's probably better for us all if the
> alphabet is happy (or at least at its place).
> ((or perhaps not; not sure the more i think about it.))
> for any case: thanks for the quick fix!
>
>         joachim
>
>
> Am 18.04.2014 00:02, schrieb Steven Yi:
>> Okay, fillarray should be working now for strings. :)
>>
>> On Thu, Apr 17, 2014 at 5:52 PM, Steven Yi  wrote:
>>> Oh I didn't pick up at first, this is an issue with fillarray, which I
>>> hadn't touched. I see the issue, I'll have something in a moment.
>>>
>>> On Thu, Apr 17, 2014 at 5:44 PM, Steven Yi  wrote:
>>>> Okay, now I'm getting a,c,e, and crash too. At least it's matching behavior. :)
>>>>
>>>> On Thu, Apr 17, 2014 at 5:40 PM, Steven Yi  wrote:
>>>>> I'm getting:
>>>>>
>>>>> instr 1:  #i0 = 6.000
>>>>> a
>>>>> b
>>>>> c
>>>>> d
>>>>>
>>>>> Though sometimes I also get:
>>>>>
>>>>> instr 1:  #i0 = 6.000
>>>>> (null)
>>>>> (null)
>>>>> (null)
>>>>> (null)
>>>>>
>>>>> which makes this very odd. I'll check futher.
>>>>>
>>>>> On Thu, Apr 17, 2014 at 5:00 PM, joachim heintz  wrote:
>>>>>> yes, slicearray seems to work. while testing, i found that string arrays
>>>>>> return the wrong value for an index. this is a simple example:
>>>>>>
>>>>>> SArr[]     fillarray  "a", "b", "c", "d", "e", "f"
>>>>>> print lenarray(SArr) ;6
>>>>>> printf_i "%s\n", 1, SArr[0] ;a
>>>>>> printf_i "%s\n", 1, SArr[1] ;c!
>>>>>> printf_i "%s\n", 1, SArr[2] ;e!
>>>>>> printf_i "%s\n", 1, SArr[3] ;segfault
>>>>>>
>>>>>> probably a simple mistake?
>>>>>>
>>>>>>          joachim
>>>>>>
>>>>>> Am 17.04.2014 17:06, schrieb Steven Yi:
>>>>>>> I think I've made slicearray work generically now for any type.
>>>>>>>
>>>>>>> Joachim: could you pull from develop and try with your various array tests?
>>>>>>>
>>>>>>> On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi  wrote:
>>>>>>>> I'll take a look at the type system/string stuff later today.
>>>>>>>>
>>>>>>>> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>>>>>>>>> Looks as if one of my commits failed.  Version of
>>>>>>>>> 2014-04-16 19:28:50
>>>>>>>>> should have many fixes -- no idea how that happened
>>>>>>>>>
>>>>>>>>> I *think* most string-array operations are broken but am not sure, or
>>>>>>>>> f how to check and fix.
>>>>>>>>>
>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>
>>>>>>>>>> this is the commit:
>>>>>>>>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>>>>>>>>> Author: John ffitch 
>>>>>>>>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>>>>>>>>
>>>>>>>>>> did you push after this?
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>>>>>>>>> bizarre -- I do not get those errors/problems.  When did you check it
>>>>>>>>>>> out/pull?
>>>>>>>>>>> There was a typo in i-array arithmetic, now fixed
>>>>>>>>>>>
>>>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>>>
>>>>>>>>>>>> i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> i can confirm the three examples you mentioned are not working. the
>>>>>>>>>>>> third example should read:
>>>>>>>>>>>> ***    copya2ftab iArr, giSine
>>>>>>>>>>>> it was a typo in my initial list.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> number 6) does not give an error, but the results are wrong:
>>>>>>>>>>>>         iArr1[]  fillarray 1, 2, 3
>>>>>>>>>>>>         iArr2[] = iArr1 + 10
>>>>>>>>>>>>         print iArr1[0], iArr1[1], iArr1[2]
>>>>>>>>>>>>         print iArr2[0], iArr2[1], iArr2[2]
>>>>>>>>>>>> returns:
>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>>>>>>>>> or sometimes something like:
>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>> instr 1:  #i23 =
>>>>>>>>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>>>>>>>>      #i24 =
>>>>>>>>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>>>>>>>>      #i25 = 0.000
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> same for 7):
>>>>>>>>>>>>         iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>         iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>         iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>         print iArr3[0], iArr3[1], iArr3[2]
>>>>>>>>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>>>>>>>>> or some astronomical high numbers.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> 8): maxarray and scalearray are working for i-arrays; minarray and
>>>>>>>>>>>> sumarray not.
>>>>>>>>>>>> * minarray:
>>>>>>>>>>>>         iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>         iMin minarray iArr
>>>>>>>>>>>> -> null opadr null opadr %s
>>>>>>>>>>>> * sumarray:
>>>>>>>>>>>>         iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>         iMin sumarray iArr
>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'sumarray' with matching
>>>>>>>>>>>> argument types:
>>>>>>>>>>>> Found: i sumarray i[]
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> 9) maparray is not working for me:
>>>>>>>>>>>>         iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>>>>>>         iArrRes[] init  7
>>>>>>>>>>>>         iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'maparray' with matching
>>>>>>>>>>>> argument types:
>>>>>>>>>>>> Found: i[] maparray i[]S
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> 10) yes this works now:
>>>>>>>>>>>>         iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>        iArr2[] = iArr1
>>>>>>>>>>>> great!
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> best -
>>>>>>>>>>>>
>>>>>>>>>>>>       joachim
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>>>>>>>>> More after initial testing
>>>>>>>>>>>>> Of Joachim's examples the following do not work
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>>>>>>>>
>>>>>>>>>>>>> All other lines parse and run
>>>>>>>>>>>>>
>>>>>>>>>>>>> The first of these is in Steve's area.  The second is my area and I
>>>>>>>>>>>>> will look at it.  Do not understand the third.  Must test the 8)
>>>>>>>>>>>>> versions soon
>>>>>>>>>>>>>
>>>>>>>>>>>>> Nearly time for breakfast
>>>>>>>>>>>>>
>>>>>>>>>>>>> ==John ffitch
>>>>>>>>>>>>>
>>>>>>>>>>>>> 
>>>>>>>>>>>>>
>>>>>>>>>>>>> 
>>>>>>>>>>>>>
>>>>>>>>>>>>> instr 1
>>>>>>>>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>>>>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>>>>>>>>         iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>         iArr2[] fillarray 4, 5, 6
>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;2) lenarray
>>>>>>>>>>>>>         Sarr[] init 3
>>>>>>>>>>>>>         print lenarray(Sarr)
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;3) slicearray
>>>>>>>>>>>>>        iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>>>>>>>>        iArr1[] init       5
>>>>>>>>>>>>>        iArr2[] init       4
>>>>>>>>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>>>>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>>>>>>>>> ;;b) same for S-arrays:
>>>>>>>>>>>>>        SArr[]  init       9
>>>>>>>>>>>>>        SArr1[] init       5
>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;4) copyf2array
>>>>>>>>>>>>>         giSine  ftgen   0, 0, 8, 10, 1
>>>>>>>>>>>>>         iArr[]  init       8
>>>>>>>>>>>>>         copyf2array iArr, giSine
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;5) copya2ftab
>>>>>>>>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>>>>>>>>> ;;do not work at i-rate. this works:
>>>>>>>>>>>>>         kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>         kArr2[] = kArr1 + 10
>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>         iArr1[]  array 1, 2, 3
>>>>>>>>>>>>>         iArr2[] = iArr1 + 10
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;7) +, -, *, / between two arrays
>>>>>>>>>>>>> ;;also missing for i. this works:
>>>>>>>>>>>>>         kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>         kArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>         kArr3[] = kArr1 + kArr2
>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>         iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>         iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>         iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>>>>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;9) maparray
>>>>>>>>>>>>> ;;as well:
>>>>>>>>>>>>>         iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>>>>>>>         iArrRes[] init  7
>>>>>>>>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;10) =
>>>>>>>>>>>>> ;;miss i-time operations. this is possible:
>>>>>>>>>>>>>         kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>         kArr2[] = kArr1
>>>>>>>>>>>>> ;;but this returns "nul opadr":
>>>>>>>>>>>>>         iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>        iArr2[] = iArr1
>>>>>>>>>>>>>
>>>>>>>>>>>>> endin
>>>>>>>>>>>>> 
>>>>>>>>>>>>>
>>>>>>>>>>>>> 
>>>>>>>>>>>>> i1 0 1
>>>>>>>>>>>>> e
>>>>>>>>>>>>> 
>>>>>>>>>>>>>
>>>>>>>>>>>>> 
>>>>>>>>>>>>>
>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>> _______________________________________________
>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>> _______________________________________________
>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>> _______________________________________________
>>>>>>>>> Csound-devel mailing list
>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>
>>>>>>> ------------------------------------------------------------------------------
>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>> this first edition is now available. Download your free book today!
>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>> _______________________________________________
>>>>>>> Csound-devel mailing list
>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>
>>>>>>
>>>>>> ------------------------------------------------------------------------------
>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>> this first edition is now available. Download your free book today!
>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>> _______________________________________________
>>>>>> Csound-devel mailing list
>>>>>> Csound-devel@lists.sourceforge.net
>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>> ------------------------------------------------------------------------------
>> Learn Graph Databases - Download FREE O'Reilly Book
>> "Graph Databases" is the definitive new guide to graph databases and their
>> applications. Written by three acclaimed leaders in the field,
>> this first edition is now available. Download your free book today!
>> http://p.sf.net/sfu/NeoTech
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-18 16:06
Fromjoachim heintz
SubjectRe: [Cs-dev] array feature wish list (I)
Attachmentstest_array_operations.csd  None  None  
i have finished now my array feature test suite (attached -- will add it 
to the tests) and i am very excited to see everything working perfectly. 
great work!!!

only two features i do still miss:

1) the assignment via = does not work for string arrays:
     Sarr1[] fillarray "is", "this", "really", "possible", "?"
     Sarr2[] = Sarr1

2) it is not possible to create a two-dimensional array in this way:
      iArr1[] fillarray 1, 2, 3
     iArr2[] fillarray 4, 5, 6
     iArrcmb[][] fillarray iArr1, iArr2

not sure how easy / hard this might be.

best -

	joachim



Am 18.04.2014 09:56, schrieb joachim heintz:
> it does. now abcd is abcd, and it's probably better for us all if the
> alphabet is happy (or at least at its place).
> ((or perhaps not; not sure the more i think about it.))
> for any case: thanks for the quick fix!
>
> 	joachim
>
>
> Am 18.04.2014 00:02, schrieb Steven Yi:
>> Okay, fillarray should be working now for strings. :)
>>
>> On Thu, Apr 17, 2014 at 5:52 PM, Steven Yi  wrote:
>>> Oh I didn't pick up at first, this is an issue with fillarray, which I
>>> hadn't touched. I see the issue, I'll have something in a moment.
>>>
>>> On Thu, Apr 17, 2014 at 5:44 PM, Steven Yi  wrote:
>>>> Okay, now I'm getting a,c,e, and crash too. At least it's matching behavior. :)
>>>>
>>>> On Thu, Apr 17, 2014 at 5:40 PM, Steven Yi  wrote:
>>>>> I'm getting:
>>>>>
>>>>> instr 1:  #i0 = 6.000
>>>>> a
>>>>> b
>>>>> c
>>>>> d
>>>>>
>>>>> Though sometimes I also get:
>>>>>
>>>>> instr 1:  #i0 = 6.000
>>>>> (null)
>>>>> (null)
>>>>> (null)
>>>>> (null)
>>>>>
>>>>> which makes this very odd. I'll check futher.
>>>>>
>>>>> On Thu, Apr 17, 2014 at 5:00 PM, joachim heintz  wrote:
>>>>>> yes, slicearray seems to work. while testing, i found that string arrays
>>>>>> return the wrong value for an index. this is a simple example:
>>>>>>
>>>>>> SArr[]     fillarray  "a", "b", "c", "d", "e", "f"
>>>>>> print lenarray(SArr) ;6
>>>>>> printf_i "%s\n", 1, SArr[0] ;a
>>>>>> printf_i "%s\n", 1, SArr[1] ;c!
>>>>>> printf_i "%s\n", 1, SArr[2] ;e!
>>>>>> printf_i "%s\n", 1, SArr[3] ;segfault
>>>>>>
>>>>>> probably a simple mistake?
>>>>>>
>>>>>>           joachim
>>>>>>
>>>>>> Am 17.04.2014 17:06, schrieb Steven Yi:
>>>>>>> I think I've made slicearray work generically now for any type.
>>>>>>>
>>>>>>> Joachim: could you pull from develop and try with your various array tests?
>>>>>>>
>>>>>>> On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi  wrote:
>>>>>>>> I'll take a look at the type system/string stuff later today.
>>>>>>>>
>>>>>>>> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>>>>>>>>> Looks as if one of my commits failed.  Version of
>>>>>>>>> 2014-04-16 19:28:50
>>>>>>>>> should have many fixes -- no idea how that happened
>>>>>>>>>
>>>>>>>>> I *think* most string-array operations are broken but am not sure, or
>>>>>>>>> f how to check and fix.
>>>>>>>>>
>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>
>>>>>>>>>> this is the commit:
>>>>>>>>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>>>>>>>>> Author: John ffitch 
>>>>>>>>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>>>>>>>>
>>>>>>>>>> did you push after this?
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>>>>>>>>> bizarre -- I do not get those errors/problems.  When did you check it
>>>>>>>>>>> out/pull?
>>>>>>>>>>> There was a typo in i-array arithmetic, now fixed
>>>>>>>>>>>
>>>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>>>
>>>>>>>>>>>> i tested with recent git (commit 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> i can confirm the three examples you mentioned are not working. the
>>>>>>>>>>>> third example should read:
>>>>>>>>>>>> ***    copya2ftab iArr, giSine
>>>>>>>>>>>> it was a typo in my initial list.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> number 6) does not give an error, but the results are wrong:
>>>>>>>>>>>>          iArr1[]  fillarray 1, 2, 3
>>>>>>>>>>>>          iArr2[] = iArr1 + 10
>>>>>>>>>>>>          print iArr1[0], iArr1[1], iArr1[2]
>>>>>>>>>>>>          print iArr2[0], iArr2[1], iArr2[2]
>>>>>>>>>>>> returns:
>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>>>>>>>>> or sometimes something like:
>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>> instr 1:  #i23 =
>>>>>>>>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>>>>>>>>       #i24 =
>>>>>>>>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>>>>>>>>       #i25 = 0.000
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> same for 7):
>>>>>>>>>>>>          iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>          iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>          iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>          print iArr3[0], iArr3[1], iArr3[2]
>>>>>>>>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>>>>>>>>> or some astronomical high numbers.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> 8): maxarray and scalearray are working for i-arrays; minarray and
>>>>>>>>>>>> sumarray not.
>>>>>>>>>>>> * minarray:
>>>>>>>>>>>>          iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>          iMin minarray iArr
>>>>>>>>>>>> -> null opadr null opadr %s
>>>>>>>>>>>> * sumarray:
>>>>>>>>>>>>          iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>          iMin sumarray iArr
>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'sumarray' with matching
>>>>>>>>>>>> argument types:
>>>>>>>>>>>> Found: i sumarray i[]
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> 9) maparray is not working for me:
>>>>>>>>>>>>          iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>>>>>>          iArrRes[] init  7
>>>>>>>>>>>>          iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'maparray' with matching
>>>>>>>>>>>> argument types:
>>>>>>>>>>>> Found: i[] maparray i[]S
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> 10) yes this works now:
>>>>>>>>>>>>          iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>         iArr2[] = iArr1
>>>>>>>>>>>> great!
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> best -
>>>>>>>>>>>>
>>>>>>>>>>>>        joachim
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>>>>>>>>> More after initial testing
>>>>>>>>>>>>> Of Joachim's examples the following do not work
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>>>>>>>>
>>>>>>>>>>>>> All other lines parse and run
>>>>>>>>>>>>>
>>>>>>>>>>>>> The first of these is in Steve's area.  The second is my area and I
>>>>>>>>>>>>> will look at it.  Do not understand the third.  Must test the 8)
>>>>>>>>>>>>> versions soon
>>>>>>>>>>>>>
>>>>>>>>>>>>> Nearly time for breakfast
>>>>>>>>>>>>>
>>>>>>>>>>>>> ==John ffitch
>>>>>>>>>>>>>
>>>>>>>>>>>>> 
>>>>>>>>>>>>>
>>>>>>>>>>>>> 
>>>>>>>>>>>>>
>>>>>>>>>>>>> instr 1
>>>>>>>>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>>>>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>>>>>>>>          iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>          iArr2[] fillarray 4, 5, 6
>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;2) lenarray
>>>>>>>>>>>>>          Sarr[] init 3
>>>>>>>>>>>>>          print lenarray(Sarr)
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;3) slicearray
>>>>>>>>>>>>>         iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>>>>>>>>         iArr1[] init       5
>>>>>>>>>>>>>         iArr2[] init       4
>>>>>>>>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>>>>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>>>>>>>>> ;;b) same for S-arrays:
>>>>>>>>>>>>>         SArr[]  init       9
>>>>>>>>>>>>>         SArr1[] init       5
>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;4) copyf2array
>>>>>>>>>>>>>          giSine  ftgen   0, 0, 8, 10, 1
>>>>>>>>>>>>>          iArr[]  init       8
>>>>>>>>>>>>>          copyf2array iArr, giSine
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;5) copya2ftab
>>>>>>>>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>>>>>>>>> ;;do not work at i-rate. this works:
>>>>>>>>>>>>>          kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>          kArr2[] = kArr1 + 10
>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>          iArr1[]  array 1, 2, 3
>>>>>>>>>>>>>          iArr2[] = iArr1 + 10
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;7) +, -, *, / between two arrays
>>>>>>>>>>>>> ;;also missing for i. this works:
>>>>>>>>>>>>>          kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>          kArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>          kArr3[] = kArr1 + kArr2
>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>          iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>          iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>          iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>>>>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;9) maparray
>>>>>>>>>>>>> ;;as well:
>>>>>>>>>>>>>          iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13, 7.21
>>>>>>>>>>>>>          iArrRes[] init  7
>>>>>>>>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>>>
>>>>>>>>>>>>> ;;10) =
>>>>>>>>>>>>> ;;miss i-time operations. this is possible:
>>>>>>>>>>>>>          kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>          kArr2[] = kArr1
>>>>>>>>>>>>> ;;but this returns "nul opadr":
>>>>>>>>>>>>>          iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>         iArr2[] = iArr1
>>>>>>>>>>>>>
>>>>>>>>>>>>> endin
>>>>>>>>>>>>> 
>>>>>>>>>>>>>
>>>>>>>>>>>>> 
>>>>>>>>>>>>> i1 0 1
>>>>>>>>>>>>> e
>>>>>>>>>>>>> 
>>>>>>>>>>>>>
>>>>>>>>>>>>> 
>>>>>>>>>>>>>
>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>> _______________________________________________
>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>> _______________________________________________
>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>> _______________________________________________
>>>>>>>>> Csound-devel mailing list
>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>
>>>>>>> ------------------------------------------------------------------------------
>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>> this first edition is now available. Download your free book today!
>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>> _______________________________________________
>>>>>>> Csound-devel mailing list
>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>
>>>>>>
>>>>>> ------------------------------------------------------------------------------
>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>> this first edition is now available. Download your free book today!
>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>> _______________________________________________
>>>>>> Csound-devel mailing list
>>>>>> Csound-devel@lists.sourceforge.net
>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>> ------------------------------------------------------------------------------
>> Learn Graph Databases - Download FREE O'Reilly Book
>> "Graph Databases" is the definitive new guide to graph databases and their
>> applications. Written by three acclaimed leaders in the field,
>> this first edition is now available. Download your free book today!
>> http://p.sf.net/sfu/NeoTech
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>

Date2014-04-18 16:35
FromSteven Yi
SubjectRe: [Cs-dev] array feature wish list (I)
Thanks for sorting these items out. I think I can write something
quick for both of these items.  I'll take a stab at it now and will
reply shortly.

On Fri, Apr 18, 2014 at 11:06 AM, joachim heintz  wrote:
> i have finished now my array feature test suite (attached -- will add it to
> the tests) and i am very excited to see everything working perfectly. great
> work!!!
>
> only two features i do still miss:
>
> 1) the assignment via = does not work for string arrays:
>     Sarr1[] fillarray "is", "this", "really", "possible", "?"
>     Sarr2[] = Sarr1
>
> 2) it is not possible to create a two-dimensional array in this way:
>
>      iArr1[] fillarray 1, 2, 3
>     iArr2[] fillarray 4, 5, 6
>     iArrcmb[][] fillarray iArr1, iArr2
>
> not sure how easy / hard this might be.
>
> best -
>
>         joachim
>
>
>
> Am 18.04.2014 09:56, schrieb joachim heintz:
>
>> it does. now abcd is abcd, and it's probably better for us all if the
>> alphabet is happy (or at least at its place).
>> ((or perhaps not; not sure the more i think about it.))
>> for any case: thanks for the quick fix!
>>
>>         joachim
>>
>>
>> Am 18.04.2014 00:02, schrieb Steven Yi:
>>>
>>> Okay, fillarray should be working now for strings. :)
>>>
>>> On Thu, Apr 17, 2014 at 5:52 PM, Steven Yi  wrote:
>>>>
>>>> Oh I didn't pick up at first, this is an issue with fillarray, which I
>>>> hadn't touched. I see the issue, I'll have something in a moment.
>>>>
>>>> On Thu, Apr 17, 2014 at 5:44 PM, Steven Yi  wrote:
>>>>>
>>>>> Okay, now I'm getting a,c,e, and crash too. At least it's matching
>>>>> behavior. :)
>>>>>
>>>>> On Thu, Apr 17, 2014 at 5:40 PM, Steven Yi  wrote:
>>>>>>
>>>>>> I'm getting:
>>>>>>
>>>>>> instr 1:  #i0 = 6.000
>>>>>> a
>>>>>> b
>>>>>> c
>>>>>> d
>>>>>>
>>>>>> Though sometimes I also get:
>>>>>>
>>>>>> instr 1:  #i0 = 6.000
>>>>>> (null)
>>>>>> (null)
>>>>>> (null)
>>>>>> (null)
>>>>>>
>>>>>> which makes this very odd. I'll check futher.
>>>>>>
>>>>>> On Thu, Apr 17, 2014 at 5:00 PM, joachim heintz 
>>>>>> wrote:
>>>>>>>
>>>>>>> yes, slicearray seems to work. while testing, i found that string
>>>>>>> arrays
>>>>>>> return the wrong value for an index. this is a simple example:
>>>>>>>
>>>>>>> SArr[]     fillarray  "a", "b", "c", "d", "e", "f"
>>>>>>> print lenarray(SArr) ;6
>>>>>>> printf_i "%s\n", 1, SArr[0] ;a
>>>>>>> printf_i "%s\n", 1, SArr[1] ;c!
>>>>>>> printf_i "%s\n", 1, SArr[2] ;e!
>>>>>>> printf_i "%s\n", 1, SArr[3] ;segfault
>>>>>>>
>>>>>>> probably a simple mistake?
>>>>>>>
>>>>>>>           joachim
>>>>>>>
>>>>>>> Am 17.04.2014 17:06, schrieb Steven Yi:
>>>>>>>>
>>>>>>>> I think I've made slicearray work generically now for any type.
>>>>>>>>
>>>>>>>> Joachim: could you pull from develop and try with your various array
>>>>>>>> tests?
>>>>>>>>
>>>>>>>> On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi 
>>>>>>>> wrote:
>>>>>>>>>
>>>>>>>>> I'll take a look at the type system/string stuff later today.
>>>>>>>>>
>>>>>>>>> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>>>>>>>>>>
>>>>>>>>>> Looks as if one of my commits failed.  Version of
>>>>>>>>>> 2014-04-16 19:28:50
>>>>>>>>>> should have many fixes -- no idea how that happened
>>>>>>>>>>
>>>>>>>>>> I *think* most string-array operations are broken but am not sure,
>>>>>>>>>> or
>>>>>>>>>> f how to check and fix.
>>>>>>>>>>
>>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>>
>>>>>>>>>>> this is the commit:
>>>>>>>>>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>>>>>>>>>> Author: John ffitch 
>>>>>>>>>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>>>>>>>>>
>>>>>>>>>>> did you push after this?
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>>>>>>>>>>
>>>>>>>>>>>> bizarre -- I do not get those errors/problems.  When did you
>>>>>>>>>>>> check it
>>>>>>>>>>>> out/pull?
>>>>>>>>>>>> There was a typo in i-array arithmetic, now fixed
>>>>>>>>>>>>
>>>>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>>>>
>>>>>>>>>>>>> i tested with recent git (commit
>>>>>>>>>>>>> 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> i can confirm the three examples you mentioned are not working.
>>>>>>>>>>>>> the
>>>>>>>>>>>>> third example should read:
>>>>>>>>>>>>> ***    copya2ftab iArr, giSine
>>>>>>>>>>>>> it was a typo in my initial list.
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> number 6) does not give an error, but the results are wrong:
>>>>>>>>>>>>>          iArr1[]  fillarray 1, 2, 3
>>>>>>>>>>>>>          iArr2[] = iArr1 + 10
>>>>>>>>>>>>>          print iArr1[0], iArr1[1], iArr1[2]
>>>>>>>>>>>>>          print iArr2[0], iArr2[1], iArr2[2]
>>>>>>>>>>>>> returns:
>>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>>>>>>>>>> or sometimes something like:
>>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>>> instr 1:  #i23 =
>>>>>>>>>>>>>
>>>>>>>>>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>>>>>>>>>       #i24 =
>>>>>>>>>>>>>
>>>>>>>>>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>>>>>>>>>       #i25 = 0.000
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> same for 7):
>>>>>>>>>>>>>          iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>          iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>          iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>>          print iArr3[0], iArr3[1], iArr3[2]
>>>>>>>>>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>>>>>>>>>> or some astronomical high numbers.
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> 8): maxarray and scalearray are working for i-arrays; minarray
>>>>>>>>>>>>> and
>>>>>>>>>>>>> sumarray not.
>>>>>>>>>>>>> * minarray:
>>>>>>>>>>>>>          iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>>          iMin minarray iArr
>>>>>>>>>>>>> -> null opadr null opadr %s
>>>>>>>>>>>>> * sumarray:
>>>>>>>>>>>>>          iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>>          iMin sumarray iArr
>>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'sumarray' with
>>>>>>>>>>>>> matching
>>>>>>>>>>>>> argument types:
>>>>>>>>>>>>> Found: i sumarray i[]
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> 9) maparray is not working for me:
>>>>>>>>>>>>>          iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13,
>>>>>>>>>>>>> 7.21
>>>>>>>>>>>>>          iArrRes[] init  7
>>>>>>>>>>>>>          iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'maparray' with
>>>>>>>>>>>>> matching
>>>>>>>>>>>>> argument types:
>>>>>>>>>>>>> Found: i[] maparray i[]S
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> 10) yes this works now:
>>>>>>>>>>>>>          iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>         iArr2[] = iArr1
>>>>>>>>>>>>> great!
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> best -
>>>>>>>>>>>>>
>>>>>>>>>>>>>        joachim
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> More after initial testing
>>>>>>>>>>>>>> Of Joachim's examples the following do not work
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> All other lines parse and run
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> The first of these is in Steve's area.  The second is my area
>>>>>>>>>>>>>> and I
>>>>>>>>>>>>>> will look at it.  Do not understand the third.  Must test the
>>>>>>>>>>>>>> 8)
>>>>>>>>>>>>>> versions soon
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Nearly time for breakfast
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ==John ffitch
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> instr 1
>>>>>>>>>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>>>>>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>>>>>>>>>          iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>          iArr2[] fillarray 4, 5, 6
>>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ;;2) lenarray
>>>>>>>>>>>>>>          Sarr[] init 3
>>>>>>>>>>>>>>          print lenarray(Sarr)
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ;;3) slicearray
>>>>>>>>>>>>>>         iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>>>>>>>>>         iArr1[] init       5
>>>>>>>>>>>>>>         iArr2[] init       4
>>>>>>>>>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>>>>>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>>>>>>>>>> ;;b) same for S-arrays:
>>>>>>>>>>>>>>         SArr[]  init       9
>>>>>>>>>>>>>>         SArr1[] init       5
>>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ;;4) copyf2array
>>>>>>>>>>>>>>          giSine  ftgen   0, 0, 8, 10, 1
>>>>>>>>>>>>>>          iArr[]  init       8
>>>>>>>>>>>>>>          copyf2array iArr, giSine
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ;;5) copya2ftab
>>>>>>>>>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>>>>>>>>>> ;;do not work at i-rate. this works:
>>>>>>>>>>>>>>          kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>          kArr2[] = kArr1 + 10
>>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>>          iArr1[]  array 1, 2, 3
>>>>>>>>>>>>>>          iArr2[] = iArr1 + 10
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ;;7) +, -, *, / between two arrays
>>>>>>>>>>>>>> ;;also missing for i. this works:
>>>>>>>>>>>>>>          kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>          kArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>          kArr3[] = kArr1 + kArr2
>>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>>          iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>          iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>          iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>>>>>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ;;9) maparray
>>>>>>>>>>>>>> ;;as well:
>>>>>>>>>>>>>>          iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13,
>>>>>>>>>>>>>> 7.21
>>>>>>>>>>>>>>          iArrRes[] init  7
>>>>>>>>>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ;;10) =
>>>>>>>>>>>>>> ;;miss i-time operations. this is possible:
>>>>>>>>>>>>>>          kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>          kArr2[] = kArr1
>>>>>>>>>>>>>> ;;but this returns "nul opadr":
>>>>>>>>>>>>>>          iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>         iArr2[] = iArr1
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> endin
>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> 
>>>>>>>>>>>>>> i1 0 1
>>>>>>>>>>>>>> e
>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph
>>>>>>>>>>>>>> databases and their
>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph
>>>>>>>>>>>>> databases and their
>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>> today!
>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>>> and their
>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>> today!
>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>> and their
>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>> today!
>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>> _______________________________________________
>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>> and their
>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>> today!
>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>> _______________________________________________
>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>>>>>> their
>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>> _______________________________________________
>>>>>>>> Csound-devel mailing list
>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ------------------------------------------------------------------------------
>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>>>>> their
>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>> this first edition is now available. Download your free book today!
>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>> _______________________________________________
>>>>>>> Csound-devel mailing list
>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Learn Graph Databases - Download FREE O'Reilly Book
>>> "Graph Databases" is the definitive new guide to graph databases and
>>> their
>>> applications. Written by three acclaimed leaders in the field,
>>> this first edition is now available. Download your free book today!
>>> http://p.sf.net/sfu/NeoTech
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>
>>
>>
>> ------------------------------------------------------------------------------
>> Learn Graph Databases - Download FREE O'Reilly Book
>> "Graph Databases" is the definitive new guide to graph databases and their
>> applications. Written by three acclaimed leaders in the field,
>> this first edition is now available. Download your free book today!
>> http://p.sf.net/sfu/NeoTech
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-18 17:54
Fromjoachim heintz
SubjectRe: [Cs-dev] array feature wish list (I)
super -- i will close the github ticket; all mentioned there is working =)
	j


Am 18.04.2014 17:35, schrieb Steven Yi:
> Thanks for sorting these items out. I think I can write something
> quick for both of these items.  I'll take a stab at it now and will
> reply shortly.
>
> On Fri, Apr 18, 2014 at 11:06 AM, joachim heintz  wrote:
>> i have finished now my array feature test suite (attached -- will add it to
>> the tests) and i am very excited to see everything working perfectly. great
>> work!!!
>>
>> only two features i do still miss:
>>
>> 1) the assignment via = does not work for string arrays:
>>      Sarr1[] fillarray "is", "this", "really", "possible", "?"
>>      Sarr2[] = Sarr1
>>
>> 2) it is not possible to create a two-dimensional array in this way:
>>
>>       iArr1[] fillarray 1, 2, 3
>>      iArr2[] fillarray 4, 5, 6
>>      iArrcmb[][] fillarray iArr1, iArr2
>>
>> not sure how easy / hard this might be.
>>
>> best -
>>
>>          joachim
>>
>>
>>
>> Am 18.04.2014 09:56, schrieb joachim heintz:
>>
>>> it does. now abcd is abcd, and it's probably better for us all if the
>>> alphabet is happy (or at least at its place).
>>> ((or perhaps not; not sure the more i think about it.))
>>> for any case: thanks for the quick fix!
>>>
>>>          joachim
>>>
>>>
>>> Am 18.04.2014 00:02, schrieb Steven Yi:
>>>>
>>>> Okay, fillarray should be working now for strings. :)
>>>>
>>>> On Thu, Apr 17, 2014 at 5:52 PM, Steven Yi  wrote:
>>>>>
>>>>> Oh I didn't pick up at first, this is an issue with fillarray, which I
>>>>> hadn't touched. I see the issue, I'll have something in a moment.
>>>>>
>>>>> On Thu, Apr 17, 2014 at 5:44 PM, Steven Yi  wrote:
>>>>>>
>>>>>> Okay, now I'm getting a,c,e, and crash too. At least it's matching
>>>>>> behavior. :)
>>>>>>
>>>>>> On Thu, Apr 17, 2014 at 5:40 PM, Steven Yi  wrote:
>>>>>>>
>>>>>>> I'm getting:
>>>>>>>
>>>>>>> instr 1:  #i0 = 6.000
>>>>>>> a
>>>>>>> b
>>>>>>> c
>>>>>>> d
>>>>>>>
>>>>>>> Though sometimes I also get:
>>>>>>>
>>>>>>> instr 1:  #i0 = 6.000
>>>>>>> (null)
>>>>>>> (null)
>>>>>>> (null)
>>>>>>> (null)
>>>>>>>
>>>>>>> which makes this very odd. I'll check futher.
>>>>>>>
>>>>>>> On Thu, Apr 17, 2014 at 5:00 PM, joachim heintz 
>>>>>>> wrote:
>>>>>>>>
>>>>>>>> yes, slicearray seems to work. while testing, i found that string
>>>>>>>> arrays
>>>>>>>> return the wrong value for an index. this is a simple example:
>>>>>>>>
>>>>>>>> SArr[]     fillarray  "a", "b", "c", "d", "e", "f"
>>>>>>>> print lenarray(SArr) ;6
>>>>>>>> printf_i "%s\n", 1, SArr[0] ;a
>>>>>>>> printf_i "%s\n", 1, SArr[1] ;c!
>>>>>>>> printf_i "%s\n", 1, SArr[2] ;e!
>>>>>>>> printf_i "%s\n", 1, SArr[3] ;segfault
>>>>>>>>
>>>>>>>> probably a simple mistake?
>>>>>>>>
>>>>>>>>            joachim
>>>>>>>>
>>>>>>>> Am 17.04.2014 17:06, schrieb Steven Yi:
>>>>>>>>>
>>>>>>>>> I think I've made slicearray work generically now for any type.
>>>>>>>>>
>>>>>>>>> Joachim: could you pull from develop and try with your various array
>>>>>>>>> tests?
>>>>>>>>>
>>>>>>>>> On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi 
>>>>>>>>> wrote:
>>>>>>>>>>
>>>>>>>>>> I'll take a look at the type system/string stuff later today.
>>>>>>>>>>
>>>>>>>>>> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>>>>>>>>>>>
>>>>>>>>>>> Looks as if one of my commits failed.  Version of
>>>>>>>>>>> 2014-04-16 19:28:50
>>>>>>>>>>> should have many fixes -- no idea how that happened
>>>>>>>>>>>
>>>>>>>>>>> I *think* most string-array operations are broken but am not sure,
>>>>>>>>>>> or
>>>>>>>>>>> f how to check and fix.
>>>>>>>>>>>
>>>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>>>
>>>>>>>>>>>> this is the commit:
>>>>>>>>>>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>>>>>>>>>>> Author: John ffitch 
>>>>>>>>>>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>>>>>>>>>>
>>>>>>>>>>>> did you push after this?
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>>>>>>>>>>>
>>>>>>>>>>>>> bizarre -- I do not get those errors/problems.  When did you
>>>>>>>>>>>>> check it
>>>>>>>>>>>>> out/pull?
>>>>>>>>>>>>> There was a typo in i-array arithmetic, now fixed
>>>>>>>>>>>>>
>>>>>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>>>>>
>>>>>>>>>>>>>> i tested with recent git (commit
>>>>>>>>>>>>>> 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> i can confirm the three examples you mentioned are not working.
>>>>>>>>>>>>>> the
>>>>>>>>>>>>>> third example should read:
>>>>>>>>>>>>>> ***    copya2ftab iArr, giSine
>>>>>>>>>>>>>> it was a typo in my initial list.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> number 6) does not give an error, but the results are wrong:
>>>>>>>>>>>>>>           iArr1[]  fillarray 1, 2, 3
>>>>>>>>>>>>>>           iArr2[] = iArr1 + 10
>>>>>>>>>>>>>>           print iArr1[0], iArr1[1], iArr1[2]
>>>>>>>>>>>>>>           print iArr2[0], iArr2[1], iArr2[2]
>>>>>>>>>>>>>> returns:
>>>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>>>>>>>>>>> or sometimes something like:
>>>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>>>> instr 1:  #i23 =
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>>>>>>>>>>        #i24 =
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>>>>>>>>>>        #i25 = 0.000
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> same for 7):
>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>           iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>           iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>>>           print iArr3[0], iArr3[1], iArr3[2]
>>>>>>>>>>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>>>>>>>>>>> or some astronomical high numbers.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> 8): maxarray and scalearray are working for i-arrays; minarray
>>>>>>>>>>>>>> and
>>>>>>>>>>>>>> sumarray not.
>>>>>>>>>>>>>> * minarray:
>>>>>>>>>>>>>>           iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>>>           iMin minarray iArr
>>>>>>>>>>>>>> -> null opadr null opadr %s
>>>>>>>>>>>>>> * sumarray:
>>>>>>>>>>>>>>           iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>>>           iMin sumarray iArr
>>>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'sumarray' with
>>>>>>>>>>>>>> matching
>>>>>>>>>>>>>> argument types:
>>>>>>>>>>>>>> Found: i sumarray i[]
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> 9) maparray is not working for me:
>>>>>>>>>>>>>>           iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13,
>>>>>>>>>>>>>> 7.21
>>>>>>>>>>>>>>           iArrRes[] init  7
>>>>>>>>>>>>>>           iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'maparray' with
>>>>>>>>>>>>>> matching
>>>>>>>>>>>>>> argument types:
>>>>>>>>>>>>>> Found: i[] maparray i[]S
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> 10) yes this works now:
>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>          iArr2[] = iArr1
>>>>>>>>>>>>>> great!
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> best -
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>         joachim
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> More after initial testing
>>>>>>>>>>>>>>> Of Joachim's examples the following do not work
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> All other lines parse and run
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> The first of these is in Steve's area.  The second is my area
>>>>>>>>>>>>>>> and I
>>>>>>>>>>>>>>> will look at it.  Do not understand the third.  Must test the
>>>>>>>>>>>>>>> 8)
>>>>>>>>>>>>>>> versions soon
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Nearly time for breakfast
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ==John ffitch
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> instr 1
>>>>>>>>>>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>>>>>>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>           iArr2[] fillarray 4, 5, 6
>>>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ;;2) lenarray
>>>>>>>>>>>>>>>           Sarr[] init 3
>>>>>>>>>>>>>>>           print lenarray(Sarr)
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ;;3) slicearray
>>>>>>>>>>>>>>>          iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>>>>>>>>>>          iArr1[] init       5
>>>>>>>>>>>>>>>          iArr2[] init       4
>>>>>>>>>>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>>>>>>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>>>>>>>>>>> ;;b) same for S-arrays:
>>>>>>>>>>>>>>>          SArr[]  init       9
>>>>>>>>>>>>>>>          SArr1[] init       5
>>>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ;;4) copyf2array
>>>>>>>>>>>>>>>           giSine  ftgen   0, 0, 8, 10, 1
>>>>>>>>>>>>>>>           iArr[]  init       8
>>>>>>>>>>>>>>>           copyf2array iArr, giSine
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ;;5) copya2ftab
>>>>>>>>>>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>>>>>>>>>>> ;;do not work at i-rate. this works:
>>>>>>>>>>>>>>>           kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>           kArr2[] = kArr1 + 10
>>>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>>>           iArr1[]  array 1, 2, 3
>>>>>>>>>>>>>>>           iArr2[] = iArr1 + 10
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ;;7) +, -, *, / between two arrays
>>>>>>>>>>>>>>> ;;also missing for i. this works:
>>>>>>>>>>>>>>>           kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>           kArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>>           kArr3[] = kArr1 + kArr2
>>>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>           iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>>           iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>>>>>>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ;;9) maparray
>>>>>>>>>>>>>>> ;;as well:
>>>>>>>>>>>>>>>           iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13,
>>>>>>>>>>>>>>> 7.21
>>>>>>>>>>>>>>>           iArrRes[] init  7
>>>>>>>>>>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ;;10) =
>>>>>>>>>>>>>>> ;;miss i-time operations. this is possible:
>>>>>>>>>>>>>>>           kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>           kArr2[] = kArr1
>>>>>>>>>>>>>>> ;;but this returns "nul opadr":
>>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>          iArr2[] = iArr1
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> endin
>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>> i1 0 1
>>>>>>>>>>>>>>> e
>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph
>>>>>>>>>>>>>>> databases and their
>>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph
>>>>>>>>>>>>>> databases and their
>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>>>> and their
>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>> today!
>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>>> and their
>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>> today!
>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>> and their
>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>> today!
>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>> _______________________________________________
>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>>>>>>> their
>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>> _______________________________________________
>>>>>>>>> Csound-devel mailing list
>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>>>>>> their
>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>> _______________________________________________
>>>>>>>> Csound-devel mailing list
>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>> their
>>>> applications. Written by three acclaimed leaders in the field,
>>>> this first edition is now available. Download your free book today!
>>>> http://p.sf.net/sfu/NeoTech
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Learn Graph Databases - Download FREE O'Reilly Book
>>> "Graph Databases" is the definitive new guide to graph databases and their
>>> applications. Written by three acclaimed leaders in the field,
>>> this first edition is now available. Download your free book today!
>>> http://p.sf.net/sfu/NeoTech
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>
>>
>> ------------------------------------------------------------------------------
>> Learn Graph Databases - Download FREE O'Reilly Book
>> "Graph Databases" is the definitive new guide to graph databases and their
>> applications. Written by three acclaimed leaders in the field,
>> this first edition is now available. Download your free book today!
>> http://p.sf.net/sfu/NeoTech
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-18 18:04
FromSteven Yi
SubjectRe: [Cs-dev] array feature wish list (I)
Oh maybe hold off, the second issue trying to pack two arrays into a
i[][] multidimensional array is a bit tricky. We don't have a var-arg
array type yet which would be required for a fillarray.  Also, the =
issue with arrays has proven a little tricky too, but I'm working
through it now.

In general, we don't have clear semantics for multidimensional arrays
too.  I need to check what happens in other languages for this.

On Fri, Apr 18, 2014 at 12:54 PM, joachim heintz  wrote:
> super -- i will close the github ticket; all mentioned there is working =)
>         j
>
>
> Am 18.04.2014 17:35, schrieb Steven Yi:
>> Thanks for sorting these items out. I think I can write something
>> quick for both of these items.  I'll take a stab at it now and will
>> reply shortly.
>>
>> On Fri, Apr 18, 2014 at 11:06 AM, joachim heintz  wrote:
>>> i have finished now my array feature test suite (attached -- will add it to
>>> the tests) and i am very excited to see everything working perfectly. great
>>> work!!!
>>>
>>> only two features i do still miss:
>>>
>>> 1) the assignment via = does not work for string arrays:
>>>      Sarr1[] fillarray "is", "this", "really", "possible", "?"
>>>      Sarr2[] = Sarr1
>>>
>>> 2) it is not possible to create a two-dimensional array in this way:
>>>
>>>       iArr1[] fillarray 1, 2, 3
>>>      iArr2[] fillarray 4, 5, 6
>>>      iArrcmb[][] fillarray iArr1, iArr2
>>>
>>> not sure how easy / hard this might be.
>>>
>>> best -
>>>
>>>          joachim
>>>
>>>
>>>
>>> Am 18.04.2014 09:56, schrieb joachim heintz:
>>>
>>>> it does. now abcd is abcd, and it's probably better for us all if the
>>>> alphabet is happy (or at least at its place).
>>>> ((or perhaps not; not sure the more i think about it.))
>>>> for any case: thanks for the quick fix!
>>>>
>>>>          joachim
>>>>
>>>>
>>>> Am 18.04.2014 00:02, schrieb Steven Yi:
>>>>>
>>>>> Okay, fillarray should be working now for strings. :)
>>>>>
>>>>> On Thu, Apr 17, 2014 at 5:52 PM, Steven Yi  wrote:
>>>>>>
>>>>>> Oh I didn't pick up at first, this is an issue with fillarray, which I
>>>>>> hadn't touched. I see the issue, I'll have something in a moment.
>>>>>>
>>>>>> On Thu, Apr 17, 2014 at 5:44 PM, Steven Yi  wrote:
>>>>>>>
>>>>>>> Okay, now I'm getting a,c,e, and crash too. At least it's matching
>>>>>>> behavior. :)
>>>>>>>
>>>>>>> On Thu, Apr 17, 2014 at 5:40 PM, Steven Yi  wrote:
>>>>>>>>
>>>>>>>> I'm getting:
>>>>>>>>
>>>>>>>> instr 1:  #i0 = 6.000
>>>>>>>> a
>>>>>>>> b
>>>>>>>> c
>>>>>>>> d
>>>>>>>>
>>>>>>>> Though sometimes I also get:
>>>>>>>>
>>>>>>>> instr 1:  #i0 = 6.000
>>>>>>>> (null)
>>>>>>>> (null)
>>>>>>>> (null)
>>>>>>>> (null)
>>>>>>>>
>>>>>>>> which makes this very odd. I'll check futher.
>>>>>>>>
>>>>>>>> On Thu, Apr 17, 2014 at 5:00 PM, joachim heintz 
>>>>>>>> wrote:
>>>>>>>>>
>>>>>>>>> yes, slicearray seems to work. while testing, i found that string
>>>>>>>>> arrays
>>>>>>>>> return the wrong value for an index. this is a simple example:
>>>>>>>>>
>>>>>>>>> SArr[]     fillarray  "a", "b", "c", "d", "e", "f"
>>>>>>>>> print lenarray(SArr) ;6
>>>>>>>>> printf_i "%s\n", 1, SArr[0] ;a
>>>>>>>>> printf_i "%s\n", 1, SArr[1] ;c!
>>>>>>>>> printf_i "%s\n", 1, SArr[2] ;e!
>>>>>>>>> printf_i "%s\n", 1, SArr[3] ;segfault
>>>>>>>>>
>>>>>>>>> probably a simple mistake?
>>>>>>>>>
>>>>>>>>>            joachim
>>>>>>>>>
>>>>>>>>> Am 17.04.2014 17:06, schrieb Steven Yi:
>>>>>>>>>>
>>>>>>>>>> I think I've made slicearray work generically now for any type.
>>>>>>>>>>
>>>>>>>>>> Joachim: could you pull from develop and try with your various array
>>>>>>>>>> tests?
>>>>>>>>>>
>>>>>>>>>> On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi 
>>>>>>>>>> wrote:
>>>>>>>>>>>
>>>>>>>>>>> I'll take a look at the type system/string stuff later today.
>>>>>>>>>>>
>>>>>>>>>>> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> Looks as if one of my commits failed.  Version of
>>>>>>>>>>>> 2014-04-16 19:28:50
>>>>>>>>>>>> should have many fixes -- no idea how that happened
>>>>>>>>>>>>
>>>>>>>>>>>> I *think* most string-array operations are broken but am not sure,
>>>>>>>>>>>> or
>>>>>>>>>>>> f how to check and fix.
>>>>>>>>>>>>
>>>>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>>>>
>>>>>>>>>>>>> this is the commit:
>>>>>>>>>>>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>>>>>>>>>>>> Author: John ffitch 
>>>>>>>>>>>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>>>>>>>>>>>
>>>>>>>>>>>>> did you push after this?
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> bizarre -- I do not get those errors/problems.  When did you
>>>>>>>>>>>>>> check it
>>>>>>>>>>>>>> out/pull?
>>>>>>>>>>>>>> There was a typo in i-array arithmetic, now fixed
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> i tested with recent git (commit
>>>>>>>>>>>>>>> 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> i can confirm the three examples you mentioned are not working.
>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>> third example should read:
>>>>>>>>>>>>>>> ***    copya2ftab iArr, giSine
>>>>>>>>>>>>>>> it was a typo in my initial list.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> number 6) does not give an error, but the results are wrong:
>>>>>>>>>>>>>>>           iArr1[]  fillarray 1, 2, 3
>>>>>>>>>>>>>>>           iArr2[] = iArr1 + 10
>>>>>>>>>>>>>>>           print iArr1[0], iArr1[1], iArr1[2]
>>>>>>>>>>>>>>>           print iArr2[0], iArr2[1], iArr2[2]
>>>>>>>>>>>>>>> returns:
>>>>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>>>>>>>>>>>> or sometimes something like:
>>>>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>>>>> instr 1:  #i23 =
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>>>>>>>>>>>        #i24 =
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>>>>>>>>>>>        #i25 = 0.000
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> same for 7):
>>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>           iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>>           iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>>>>           print iArr3[0], iArr3[1], iArr3[2]
>>>>>>>>>>>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>>>>>>>>>>>> or some astronomical high numbers.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> 8): maxarray and scalearray are working for i-arrays; minarray
>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>> sumarray not.
>>>>>>>>>>>>>>> * minarray:
>>>>>>>>>>>>>>>           iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>           iMin minarray iArr
>>>>>>>>>>>>>>> -> null opadr null opadr %s
>>>>>>>>>>>>>>> * sumarray:
>>>>>>>>>>>>>>>           iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>           iMin sumarray iArr
>>>>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'sumarray' with
>>>>>>>>>>>>>>> matching
>>>>>>>>>>>>>>> argument types:
>>>>>>>>>>>>>>> Found: i sumarray i[]
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> 9) maparray is not working for me:
>>>>>>>>>>>>>>>           iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13,
>>>>>>>>>>>>>>> 7.21
>>>>>>>>>>>>>>>           iArrRes[] init  7
>>>>>>>>>>>>>>>           iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'maparray' with
>>>>>>>>>>>>>>> matching
>>>>>>>>>>>>>>> argument types:
>>>>>>>>>>>>>>> Found: i[] maparray i[]S
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> 10) yes this works now:
>>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>          iArr2[] = iArr1
>>>>>>>>>>>>>>> great!
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> best -
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>         joachim
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> More after initial testing
>>>>>>>>>>>>>>>> Of Joachim's examples the following do not work
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> All other lines parse and run
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> The first of these is in Steve's area.  The second is my area
>>>>>>>>>>>>>>>> and I
>>>>>>>>>>>>>>>> will look at it.  Do not understand the third.  Must test the
>>>>>>>>>>>>>>>> 8)
>>>>>>>>>>>>>>>> versions soon
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Nearly time for breakfast
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ==John ffitch
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> instr 1
>>>>>>>>>>>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>>>>>>>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>           iArr2[] fillarray 4, 5, 6
>>>>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ;;2) lenarray
>>>>>>>>>>>>>>>>           Sarr[] init 3
>>>>>>>>>>>>>>>>           print lenarray(Sarr)
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ;;3) slicearray
>>>>>>>>>>>>>>>>          iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>>>>>>>>>>>          iArr1[] init       5
>>>>>>>>>>>>>>>>          iArr2[] init       4
>>>>>>>>>>>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>>>>>>>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>>>>>>>>>>>> ;;b) same for S-arrays:
>>>>>>>>>>>>>>>>          SArr[]  init       9
>>>>>>>>>>>>>>>>          SArr1[] init       5
>>>>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ;;4) copyf2array
>>>>>>>>>>>>>>>>           giSine  ftgen   0, 0, 8, 10, 1
>>>>>>>>>>>>>>>>           iArr[]  init       8
>>>>>>>>>>>>>>>>           copyf2array iArr, giSine
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ;;5) copya2ftab
>>>>>>>>>>>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>>>>>>>>>>>> ;;do not work at i-rate. this works:
>>>>>>>>>>>>>>>>           kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>           kArr2[] = kArr1 + 10
>>>>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>>>>           iArr1[]  array 1, 2, 3
>>>>>>>>>>>>>>>>           iArr2[] = iArr1 + 10
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ;;7) +, -, *, / between two arrays
>>>>>>>>>>>>>>>> ;;also missing for i. this works:
>>>>>>>>>>>>>>>>           kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>           kArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>>>           kArr3[] = kArr1 + kArr2
>>>>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>           iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>>>           iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>>>>>>>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ;;9) maparray
>>>>>>>>>>>>>>>> ;;as well:
>>>>>>>>>>>>>>>>           iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13,
>>>>>>>>>>>>>>>> 7.21
>>>>>>>>>>>>>>>>           iArrRes[] init  7
>>>>>>>>>>>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ;;10) =
>>>>>>>>>>>>>>>> ;;miss i-time operations. this is possible:
>>>>>>>>>>>>>>>>           kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>           kArr2[] = kArr1
>>>>>>>>>>>>>>>> ;;but this returns "nul opadr":
>>>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>          iArr2[] = iArr1
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> endin
>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>> i1 0 1
>>>>>>>>>>>>>>>> e
>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph
>>>>>>>>>>>>>>>> databases and their
>>>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph
>>>>>>>>>>>>>>> databases and their
>>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>>>>> and their
>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>>>> and their
>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>> today!
>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>>> and their
>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>> today!
>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>>>>>>>> their
>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>> _______________________________________________
>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>>>>>>> their
>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>> _______________________________________________
>>>>>>>>> Csound-devel mailing list
>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>>> their
>>>>> applications. Written by three acclaimed leaders in the field,
>>>>> this first edition is now available. Download your free book today!
>>>>> http://p.sf.net/sfu/NeoTech
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>> applications. Written by three acclaimed leaders in the field,
>>>> this first edition is now available. Download your free book today!
>>>> http://p.sf.net/sfu/NeoTech
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Learn Graph Databases - Download FREE O'Reilly Book
>>> "Graph Databases" is the definitive new guide to graph databases and their
>>> applications. Written by three acclaimed leaders in the field,
>>> this first edition is now available. Download your free book today!
>>> http://p.sf.net/sfu/NeoTech
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>
>>
>> ------------------------------------------------------------------------------
>> Learn Graph Databases - Download FREE O'Reilly Book
>> "Graph Databases" is the definitive new guide to graph databases and their
>> applications. Written by three acclaimed leaders in the field,
>> this first edition is now available. Download your free book today!
>> http://p.sf.net/sfu/NeoTech
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-18 20:59
FromSteven Yi
SubjectRe: [Cs-dev] array feature wish list (I)
Update: I have the array assignment working. It should work now for
all array types.  The S[] example from the CSD is working here now.  I
also fixed up an issue with array value copying when calling UDO's.

I think the fillarray issue is all that's left.

On Fri, Apr 18, 2014 at 1:04 PM, Steven Yi  wrote:
> Oh maybe hold off, the second issue trying to pack two arrays into a
> i[][] multidimensional array is a bit tricky. We don't have a var-arg
> array type yet which would be required for a fillarray.  Also, the =
> issue with arrays has proven a little tricky too, but I'm working
> through it now.
>
> In general, we don't have clear semantics for multidimensional arrays
> too.  I need to check what happens in other languages for this.
>
> On Fri, Apr 18, 2014 at 12:54 PM, joachim heintz  wrote:
>> super -- i will close the github ticket; all mentioned there is working =)
>>         j
>>
>>
>> Am 18.04.2014 17:35, schrieb Steven Yi:
>>> Thanks for sorting these items out. I think I can write something
>>> quick for both of these items.  I'll take a stab at it now and will
>>> reply shortly.
>>>
>>> On Fri, Apr 18, 2014 at 11:06 AM, joachim heintz  wrote:
>>>> i have finished now my array feature test suite (attached -- will add it to
>>>> the tests) and i am very excited to see everything working perfectly. great
>>>> work!!!
>>>>
>>>> only two features i do still miss:
>>>>
>>>> 1) the assignment via = does not work for string arrays:
>>>>      Sarr1[] fillarray "is", "this", "really", "possible", "?"
>>>>      Sarr2[] = Sarr1
>>>>
>>>> 2) it is not possible to create a two-dimensional array in this way:
>>>>
>>>>       iArr1[] fillarray 1, 2, 3
>>>>      iArr2[] fillarray 4, 5, 6
>>>>      iArrcmb[][] fillarray iArr1, iArr2
>>>>
>>>> not sure how easy / hard this might be.
>>>>
>>>> best -
>>>>
>>>>          joachim
>>>>
>>>>
>>>>
>>>> Am 18.04.2014 09:56, schrieb joachim heintz:
>>>>
>>>>> it does. now abcd is abcd, and it's probably better for us all if the
>>>>> alphabet is happy (or at least at its place).
>>>>> ((or perhaps not; not sure the more i think about it.))
>>>>> for any case: thanks for the quick fix!
>>>>>
>>>>>          joachim
>>>>>
>>>>>
>>>>> Am 18.04.2014 00:02, schrieb Steven Yi:
>>>>>>
>>>>>> Okay, fillarray should be working now for strings. :)
>>>>>>
>>>>>> On Thu, Apr 17, 2014 at 5:52 PM, Steven Yi  wrote:
>>>>>>>
>>>>>>> Oh I didn't pick up at first, this is an issue with fillarray, which I
>>>>>>> hadn't touched. I see the issue, I'll have something in a moment.
>>>>>>>
>>>>>>> On Thu, Apr 17, 2014 at 5:44 PM, Steven Yi  wrote:
>>>>>>>>
>>>>>>>> Okay, now I'm getting a,c,e, and crash too. At least it's matching
>>>>>>>> behavior. :)
>>>>>>>>
>>>>>>>> On Thu, Apr 17, 2014 at 5:40 PM, Steven Yi  wrote:
>>>>>>>>>
>>>>>>>>> I'm getting:
>>>>>>>>>
>>>>>>>>> instr 1:  #i0 = 6.000
>>>>>>>>> a
>>>>>>>>> b
>>>>>>>>> c
>>>>>>>>> d
>>>>>>>>>
>>>>>>>>> Though sometimes I also get:
>>>>>>>>>
>>>>>>>>> instr 1:  #i0 = 6.000
>>>>>>>>> (null)
>>>>>>>>> (null)
>>>>>>>>> (null)
>>>>>>>>> (null)
>>>>>>>>>
>>>>>>>>> which makes this very odd. I'll check futher.
>>>>>>>>>
>>>>>>>>> On Thu, Apr 17, 2014 at 5:00 PM, joachim heintz 
>>>>>>>>> wrote:
>>>>>>>>>>
>>>>>>>>>> yes, slicearray seems to work. while testing, i found that string
>>>>>>>>>> arrays
>>>>>>>>>> return the wrong value for an index. this is a simple example:
>>>>>>>>>>
>>>>>>>>>> SArr[]     fillarray  "a", "b", "c", "d", "e", "f"
>>>>>>>>>> print lenarray(SArr) ;6
>>>>>>>>>> printf_i "%s\n", 1, SArr[0] ;a
>>>>>>>>>> printf_i "%s\n", 1, SArr[1] ;c!
>>>>>>>>>> printf_i "%s\n", 1, SArr[2] ;e!
>>>>>>>>>> printf_i "%s\n", 1, SArr[3] ;segfault
>>>>>>>>>>
>>>>>>>>>> probably a simple mistake?
>>>>>>>>>>
>>>>>>>>>>            joachim
>>>>>>>>>>
>>>>>>>>>> Am 17.04.2014 17:06, schrieb Steven Yi:
>>>>>>>>>>>
>>>>>>>>>>> I think I've made slicearray work generically now for any type.
>>>>>>>>>>>
>>>>>>>>>>> Joachim: could you pull from develop and try with your various array
>>>>>>>>>>> tests?
>>>>>>>>>>>
>>>>>>>>>>> On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi 
>>>>>>>>>>> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> I'll take a look at the type system/string stuff later today.
>>>>>>>>>>>>
>>>>>>>>>>>> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>> Looks as if one of my commits failed.  Version of
>>>>>>>>>>>>> 2014-04-16 19:28:50
>>>>>>>>>>>>> should have many fixes -- no idea how that happened
>>>>>>>>>>>>>
>>>>>>>>>>>>> I *think* most string-array operations are broken but am not sure,
>>>>>>>>>>>>> or
>>>>>>>>>>>>> f how to check and fix.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>>>>>
>>>>>>>>>>>>>> this is the commit:
>>>>>>>>>>>>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>>>>>>>>>>>>> Author: John ffitch 
>>>>>>>>>>>>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> did you push after this?
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> bizarre -- I do not get those errors/problems.  When did you
>>>>>>>>>>>>>>> check it
>>>>>>>>>>>>>>> out/pull?
>>>>>>>>>>>>>>> There was a typo in i-array arithmetic, now fixed
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> i tested with recent git (commit
>>>>>>>>>>>>>>>> 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> i can confirm the three examples you mentioned are not working.
>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>> third example should read:
>>>>>>>>>>>>>>>> ***    copya2ftab iArr, giSine
>>>>>>>>>>>>>>>> it was a typo in my initial list.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> number 6) does not give an error, but the results are wrong:
>>>>>>>>>>>>>>>>           iArr1[]  fillarray 1, 2, 3
>>>>>>>>>>>>>>>>           iArr2[] = iArr1 + 10
>>>>>>>>>>>>>>>>           print iArr1[0], iArr1[1], iArr1[2]
>>>>>>>>>>>>>>>>           print iArr2[0], iArr2[1], iArr2[2]
>>>>>>>>>>>>>>>> returns:
>>>>>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>>>>>>>>>>>>> or sometimes something like:
>>>>>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>>>>>> instr 1:  #i23 =
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>>>>>>>>>>>>        #i24 =
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>>>>>>>>>>>>        #i25 = 0.000
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> same for 7):
>>>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>           iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>>>           iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>>>>>           print iArr3[0], iArr3[1], iArr3[2]
>>>>>>>>>>>>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>>>>>>>>>>>>> or some astronomical high numbers.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> 8): maxarray and scalearray are working for i-arrays; minarray
>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>> sumarray not.
>>>>>>>>>>>>>>>> * minarray:
>>>>>>>>>>>>>>>>           iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>           iMin minarray iArr
>>>>>>>>>>>>>>>> -> null opadr null opadr %s
>>>>>>>>>>>>>>>> * sumarray:
>>>>>>>>>>>>>>>>           iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>           iMin sumarray iArr
>>>>>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'sumarray' with
>>>>>>>>>>>>>>>> matching
>>>>>>>>>>>>>>>> argument types:
>>>>>>>>>>>>>>>> Found: i sumarray i[]
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> 9) maparray is not working for me:
>>>>>>>>>>>>>>>>           iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13,
>>>>>>>>>>>>>>>> 7.21
>>>>>>>>>>>>>>>>           iArrRes[] init  7
>>>>>>>>>>>>>>>>           iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'maparray' with
>>>>>>>>>>>>>>>> matching
>>>>>>>>>>>>>>>> argument types:
>>>>>>>>>>>>>>>> Found: i[] maparray i[]S
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> 10) yes this works now:
>>>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>          iArr2[] = iArr1
>>>>>>>>>>>>>>>> great!
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> best -
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>         joachim
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> More after initial testing
>>>>>>>>>>>>>>>>> Of Joachim's examples the following do not work
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> All other lines parse and run
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> The first of these is in Steve's area.  The second is my area
>>>>>>>>>>>>>>>>> and I
>>>>>>>>>>>>>>>>> will look at it.  Do not understand the third.  Must test the
>>>>>>>>>>>>>>>>> 8)
>>>>>>>>>>>>>>>>> versions soon
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Nearly time for breakfast
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ==John ffitch
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> instr 1
>>>>>>>>>>>>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>>>>>>>>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>           iArr2[] fillarray 4, 5, 6
>>>>>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ;;2) lenarray
>>>>>>>>>>>>>>>>>           Sarr[] init 3
>>>>>>>>>>>>>>>>>           print lenarray(Sarr)
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ;;3) slicearray
>>>>>>>>>>>>>>>>>          iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>>>>>>>>>>>>          iArr1[] init       5
>>>>>>>>>>>>>>>>>          iArr2[] init       4
>>>>>>>>>>>>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>>>>>>>>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>>>>>>>>>>>>> ;;b) same for S-arrays:
>>>>>>>>>>>>>>>>>          SArr[]  init       9
>>>>>>>>>>>>>>>>>          SArr1[] init       5
>>>>>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ;;4) copyf2array
>>>>>>>>>>>>>>>>>           giSine  ftgen   0, 0, 8, 10, 1
>>>>>>>>>>>>>>>>>           iArr[]  init       8
>>>>>>>>>>>>>>>>>           copyf2array iArr, giSine
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ;;5) copya2ftab
>>>>>>>>>>>>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>>>>>>>>>>>>> ;;do not work at i-rate. this works:
>>>>>>>>>>>>>>>>>           kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>           kArr2[] = kArr1 + 10
>>>>>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>>>>>           iArr1[]  array 1, 2, 3
>>>>>>>>>>>>>>>>>           iArr2[] = iArr1 + 10
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ;;7) +, -, *, / between two arrays
>>>>>>>>>>>>>>>>> ;;also missing for i. this works:
>>>>>>>>>>>>>>>>>           kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>           kArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>>>>           kArr3[] = kArr1 + kArr2
>>>>>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>           iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>>>>           iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>>>>>>>>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ;;9) maparray
>>>>>>>>>>>>>>>>> ;;as well:
>>>>>>>>>>>>>>>>>           iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13,
>>>>>>>>>>>>>>>>> 7.21
>>>>>>>>>>>>>>>>>           iArrRes[] init  7
>>>>>>>>>>>>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ;;10) =
>>>>>>>>>>>>>>>>> ;;miss i-time operations. this is possible:
>>>>>>>>>>>>>>>>>           kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>           kArr2[] = kArr1
>>>>>>>>>>>>>>>>> ;;but this returns "nul opadr":
>>>>>>>>>>>>>>>>>           iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>          iArr2[] = iArr1
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> endin
>>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>> i1 0 1
>>>>>>>>>>>>>>>>> e
>>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph
>>>>>>>>>>>>>>>>> databases and their
>>>>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph
>>>>>>>>>>>>>>>> databases and their
>>>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>>>>>> and their
>>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>>>>> and their
>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>>>> and their
>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>> today!
>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>>>>>>>>> their
>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>> _______________________________________________
>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>>>>>>>> their
>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>> _______________________________________________
>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>
>>>>>>
>>>>>>
>>>>>> ------------------------------------------------------------------------------
>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>>>> their
>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>> this first edition is now available. Download your free book today!
>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>> _______________________________________________
>>>>>> Csound-devel mailing list
>>>>>> Csound-devel@lists.sourceforge.net
>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>
>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>> applications. Written by three acclaimed leaders in the field,
>>>>> this first edition is now available. Download your free book today!
>>>>> http://p.sf.net/sfu/NeoTech
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>> applications. Written by three acclaimed leaders in the field,
>>>> this first edition is now available. Download your free book today!
>>>> http://p.sf.net/sfu/NeoTech
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Learn Graph Databases - Download FREE O'Reilly Book
>>> "Graph Databases" is the definitive new guide to graph databases and their
>>> applications. Written by three acclaimed leaders in the field,
>>> this first edition is now available. Download your free book today!
>>> http://p.sf.net/sfu/NeoTech
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>
>>
>> ------------------------------------------------------------------------------
>> Learn Graph Databases - Download FREE O'Reilly Book
>> "Graph Databases" is the definitive new guide to graph databases and their
>> applications. Written by three acclaimed leaders in the field,
>> this first edition is now available. Download your free book today!
>> http://p.sf.net/sfu/NeoTech
>> _______________________________________________
>> Csound-devel mailing list
>> Csound-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/csound-devel

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net

Date2014-04-18 21:11
Fromjoachim heintz
SubjectRe: [Cs-dev] array feature wish list (I)
yes:
     Sarr1[] fillarray "is", "this", "really", "possible", "?"
     Sarr2[] = Sarr1
     PrtArr1S Sarr2
-> [is, this, really, possible, ?]

=)
	j

Am 18.04.2014 21:59, schrieb Steven Yi:
> Update: I have the array assignment working. It should work now for
> all array types.  The S[] example from the CSD is working here now.  I
> also fixed up an issue with array value copying when calling UDO's.
>
> I think the fillarray issue is all that's left.
>
> On Fri, Apr 18, 2014 at 1:04 PM, Steven Yi  wrote:
>> Oh maybe hold off, the second issue trying to pack two arrays into a
>> i[][] multidimensional array is a bit tricky. We don't have a var-arg
>> array type yet which would be required for a fillarray.  Also, the =
>> issue with arrays has proven a little tricky too, but I'm working
>> through it now.
>>
>> In general, we don't have clear semantics for multidimensional arrays
>> too.  I need to check what happens in other languages for this.
>>
>> On Fri, Apr 18, 2014 at 12:54 PM, joachim heintz  wrote:
>>> super -- i will close the github ticket; all mentioned there is working =)
>>>          j
>>>
>>>
>>> Am 18.04.2014 17:35, schrieb Steven Yi:
>>>> Thanks for sorting these items out. I think I can write something
>>>> quick for both of these items.  I'll take a stab at it now and will
>>>> reply shortly.
>>>>
>>>> On Fri, Apr 18, 2014 at 11:06 AM, joachim heintz  wrote:
>>>>> i have finished now my array feature test suite (attached -- will add it to
>>>>> the tests) and i am very excited to see everything working perfectly. great
>>>>> work!!!
>>>>>
>>>>> only two features i do still miss:
>>>>>
>>>>> 1) the assignment via = does not work for string arrays:
>>>>>       Sarr1[] fillarray "is", "this", "really", "possible", "?"
>>>>>       Sarr2[] = Sarr1
>>>>>
>>>>> 2) it is not possible to create a two-dimensional array in this way:
>>>>>
>>>>>        iArr1[] fillarray 1, 2, 3
>>>>>       iArr2[] fillarray 4, 5, 6
>>>>>       iArrcmb[][] fillarray iArr1, iArr2
>>>>>
>>>>> not sure how easy / hard this might be.
>>>>>
>>>>> best -
>>>>>
>>>>>           joachim
>>>>>
>>>>>
>>>>>
>>>>> Am 18.04.2014 09:56, schrieb joachim heintz:
>>>>>
>>>>>> it does. now abcd is abcd, and it's probably better for us all if the
>>>>>> alphabet is happy (or at least at its place).
>>>>>> ((or perhaps not; not sure the more i think about it.))
>>>>>> for any case: thanks for the quick fix!
>>>>>>
>>>>>>           joachim
>>>>>>
>>>>>>
>>>>>> Am 18.04.2014 00:02, schrieb Steven Yi:
>>>>>>>
>>>>>>> Okay, fillarray should be working now for strings. :)
>>>>>>>
>>>>>>> On Thu, Apr 17, 2014 at 5:52 PM, Steven Yi  wrote:
>>>>>>>>
>>>>>>>> Oh I didn't pick up at first, this is an issue with fillarray, which I
>>>>>>>> hadn't touched. I see the issue, I'll have something in a moment.
>>>>>>>>
>>>>>>>> On Thu, Apr 17, 2014 at 5:44 PM, Steven Yi  wrote:
>>>>>>>>>
>>>>>>>>> Okay, now I'm getting a,c,e, and crash too. At least it's matching
>>>>>>>>> behavior. :)
>>>>>>>>>
>>>>>>>>> On Thu, Apr 17, 2014 at 5:40 PM, Steven Yi  wrote:
>>>>>>>>>>
>>>>>>>>>> I'm getting:
>>>>>>>>>>
>>>>>>>>>> instr 1:  #i0 = 6.000
>>>>>>>>>> a
>>>>>>>>>> b
>>>>>>>>>> c
>>>>>>>>>> d
>>>>>>>>>>
>>>>>>>>>> Though sometimes I also get:
>>>>>>>>>>
>>>>>>>>>> instr 1:  #i0 = 6.000
>>>>>>>>>> (null)
>>>>>>>>>> (null)
>>>>>>>>>> (null)
>>>>>>>>>> (null)
>>>>>>>>>>
>>>>>>>>>> which makes this very odd. I'll check futher.
>>>>>>>>>>
>>>>>>>>>> On Thu, Apr 17, 2014 at 5:00 PM, joachim heintz 
>>>>>>>>>> wrote:
>>>>>>>>>>>
>>>>>>>>>>> yes, slicearray seems to work. while testing, i found that string
>>>>>>>>>>> arrays
>>>>>>>>>>> return the wrong value for an index. this is a simple example:
>>>>>>>>>>>
>>>>>>>>>>> SArr[]     fillarray  "a", "b", "c", "d", "e", "f"
>>>>>>>>>>> print lenarray(SArr) ;6
>>>>>>>>>>> printf_i "%s\n", 1, SArr[0] ;a
>>>>>>>>>>> printf_i "%s\n", 1, SArr[1] ;c!
>>>>>>>>>>> printf_i "%s\n", 1, SArr[2] ;e!
>>>>>>>>>>> printf_i "%s\n", 1, SArr[3] ;segfault
>>>>>>>>>>>
>>>>>>>>>>> probably a simple mistake?
>>>>>>>>>>>
>>>>>>>>>>>             joachim
>>>>>>>>>>>
>>>>>>>>>>> Am 17.04.2014 17:06, schrieb Steven Yi:
>>>>>>>>>>>>
>>>>>>>>>>>> I think I've made slicearray work generically now for any type.
>>>>>>>>>>>>
>>>>>>>>>>>> Joachim: could you pull from develop and try with your various array
>>>>>>>>>>>> tests?
>>>>>>>>>>>>
>>>>>>>>>>>> On Wed, Apr 16, 2014 at 3:59 PM, Steven Yi 
>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>> I'll take a look at the type system/string stuff later today.
>>>>>>>>>>>>>
>>>>>>>>>>>>> On Wed, Apr 16, 2014 at 2:52 PM,   wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Looks as if one of my commits failed.  Version of
>>>>>>>>>>>>>> 2014-04-16 19:28:50
>>>>>>>>>>>>>> should have many fixes -- no idea how that happened
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> I *think* most string-array operations are broken but am not sure,
>>>>>>>>>>>>>> or
>>>>>>>>>>>>>> f how to check and fix.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> this is the commit:
>>>>>>>>>>>>>>> commit 3e5567414c8843d7feca6f4315a7a715ed5509c8
>>>>>>>>>>>>>>> Author: John ffitch 
>>>>>>>>>>>>>>> Date:   Wed Apr 16 11:06:25 2014 +0100
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> did you push after this?
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Am 16.04.2014 20:30, schrieb jpff@cs.bath.ac.uk:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> bizarre -- I do not get those errors/problems.  When did you
>>>>>>>>>>>>>>>> check it
>>>>>>>>>>>>>>>> out/pull?
>>>>>>>>>>>>>>>> There was a typo in i-array arithmetic, now fixed
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Quoting joachim heintz :
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> i tested with recent git (commit
>>>>>>>>>>>>>>>>> 3e5567414c8843d7feca6f4315a7a715ed5509c8).
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> i can confirm the three examples you mentioned are not working.
>>>>>>>>>>>>>>>>> the
>>>>>>>>>>>>>>>>> third example should read:
>>>>>>>>>>>>>>>>> ***    copya2ftab iArr, giSine
>>>>>>>>>>>>>>>>> it was a typo in my initial list.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> number 6) does not give an error, but the results are wrong:
>>>>>>>>>>>>>>>>>            iArr1[]  fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>            iArr2[] = iArr1 + 10
>>>>>>>>>>>>>>>>>            print iArr1[0], iArr1[1], iArr1[2]
>>>>>>>>>>>>>>>>>            print iArr2[0], iArr2[1], iArr2[2]
>>>>>>>>>>>>>>>>> returns:
>>>>>>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>>>>>>> instr 1:  #i23 = 0.000  #i24 = 0.000  #i25 = 0.000
>>>>>>>>>>>>>>>>> or sometimes something like:
>>>>>>>>>>>>>>>>> instr 1:  #i20 = 1.000  #i21 = 2.000  #i22 = 3.000
>>>>>>>>>>>>>>>>> instr 1:  #i23 =
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> 7896072310099349162906429574043227461358208562244071576930073937753031657820141316759147187252869466600045210819649939617293601769692355161046355279872.000
>>>>>>>>>>>>>>>>>         #i24 =
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> 1387031846154320490435473578089028700715223909848818692804087895876990638304924374329687277568.000
>>>>>>>>>>>>>>>>>         #i25 = 0.000
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> same for 7):
>>>>>>>>>>>>>>>>>            iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>            iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>>>>            iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>>>>>>            print iArr3[0], iArr3[1], iArr3[2]
>>>>>>>>>>>>>>>>> -> instr 1:  #i20 = 0.000  #i21 = 0.000  #i22 = 0.000
>>>>>>>>>>>>>>>>> or some astronomical high numbers.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> 8): maxarray and scalearray are working for i-arrays; minarray
>>>>>>>>>>>>>>>>> and
>>>>>>>>>>>>>>>>> sumarray not.
>>>>>>>>>>>>>>>>> * minarray:
>>>>>>>>>>>>>>>>>            iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>            iMin minarray iArr
>>>>>>>>>>>>>>>>> -> null opadr null opadr %s
>>>>>>>>>>>>>>>>> * sumarray:
>>>>>>>>>>>>>>>>>            iArr[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>            iMin sumarray iArr
>>>>>>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'sumarray' with
>>>>>>>>>>>>>>>>> matching
>>>>>>>>>>>>>>>>> argument types:
>>>>>>>>>>>>>>>>> Found: i sumarray i[]
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> 9) maparray is not working for me:
>>>>>>>>>>>>>>>>>            iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13,
>>>>>>>>>>>>>>>>> 7.21
>>>>>>>>>>>>>>>>>            iArrRes[] init  7
>>>>>>>>>>>>>>>>>            iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>>>>>>> -> error:  Unable to find opcode entry for 'maparray' with
>>>>>>>>>>>>>>>>> matching
>>>>>>>>>>>>>>>>> argument types:
>>>>>>>>>>>>>>>>> Found: i[] maparray i[]S
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> 10) yes this works now:
>>>>>>>>>>>>>>>>>            iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>           iArr2[] = iArr1
>>>>>>>>>>>>>>>>> great!
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> best -
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>          joachim
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Am 16.04.2014 12:23, schrieb john ffitch:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> More after initial testing
>>>>>>>>>>>>>>>>>> Of Joachim's examples the following do not work
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>>>>>>> ;;***    copya2ftab giSine, giSine    <===== curious
>>>>>>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray not tested
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> All other lines parse and run
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> The first of these is in Steve's area.  The second is my area
>>>>>>>>>>>>>>>>>> and I
>>>>>>>>>>>>>>>>>> will look at it.  Do not understand the third.  Must test the
>>>>>>>>>>>>>>>>>> 8)
>>>>>>>>>>>>>>>>>> versions soon
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Nearly time for breakfast
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ==John ffitch
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> instr 1
>>>>>>>>>>>>>>>>>> SArr[] fillarray "a", "b", "c"
>>>>>>>>>>>>>>>>>> ;;b) not possible to have arrays as arguments, e.g.
>>>>>>>>>>>>>>>>>>            iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>>            iArr2[] fillarray 4, 5, 6
>>>>>>>>>>>>>>>>>> ;;***    iArr[][] fillarray iArr1, iArr2
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ;;2) lenarray
>>>>>>>>>>>>>>>>>>            Sarr[] init 3
>>>>>>>>>>>>>>>>>>            print lenarray(Sarr)
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ;;3) slicearray
>>>>>>>>>>>>>>>>>>           iArr[]  fillarray  1, 2, 3, 4, 5, 6, 7, 8, 9
>>>>>>>>>>>>>>>>>>           iArr1[] init       5
>>>>>>>>>>>>>>>>>>           iArr2[] init       4
>>>>>>>>>>>>>>>>>> iArr1   slicearray iArr, 0, 4        ;[1, 2, 3, 4, 5]
>>>>>>>>>>>>>>>>>> iArr2   slicearray iArr, 5, 8        ;[6, 7, 8, 9]
>>>>>>>>>>>>>>>>>> ;;b) same for S-arrays:
>>>>>>>>>>>>>>>>>>           SArr[]  init       9
>>>>>>>>>>>>>>>>>>           SArr1[] init       5
>>>>>>>>>>>>>>>>>> ;;***   SArr1   slicearray SArr, 0, 4
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ;;4) copyf2array
>>>>>>>>>>>>>>>>>>            giSine  ftgen   0, 0, 8, 10, 1
>>>>>>>>>>>>>>>>>>            iArr[]  init       8
>>>>>>>>>>>>>>>>>>            copyf2array iArr, giSine
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ;;5) copya2ftab
>>>>>>>>>>>>>>>>>> ;;***    copya2ftab giSine, iArr
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ;;6) +, -, *, / between an array and a number
>>>>>>>>>>>>>>>>>> ;;do not work at i-rate. this works:
>>>>>>>>>>>>>>>>>>            kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>>            kArr2[] = kArr1 + 10
>>>>>>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>>>>>>            iArr1[]  array 1, 2, 3
>>>>>>>>>>>>>>>>>>            iArr2[] = iArr1 + 10
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ;;7) +, -, *, / between two arrays
>>>>>>>>>>>>>>>>>> ;;also missing for i. this works:
>>>>>>>>>>>>>>>>>>            kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>>            kArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>>>>>            kArr3[] = kArr1 + kArr2
>>>>>>>>>>>>>>>>>> ;;but this does not:
>>>>>>>>>>>>>>>>>>            iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>>            iArr2[] fillarray 10, 20, 30
>>>>>>>>>>>>>>>>>>            iArr3[] = iArr1 + iArr2
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ;;8) minarray, maxarray, sumarray, scalearray
>>>>>>>>>>>>>>>>>> ;;do all miss i-time operations, as far as i see.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ;;9) maparray
>>>>>>>>>>>>>>>>>> ;;as well:
>>>>>>>>>>>>>>>>>>            iArrSrc[] array 1.01, 2.02, 3.03, 4.05, 5.08, 6.13,
>>>>>>>>>>>>>>>>>> 7.21
>>>>>>>>>>>>>>>>>>            iArrRes[] init  7
>>>>>>>>>>>>>>>>>> ;;***    iArrRes maparray iArrSrc, "sqrt"
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ;;10) =
>>>>>>>>>>>>>>>>>> ;;miss i-time operations. this is possible:
>>>>>>>>>>>>>>>>>>            kArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>>            kArr2[] = kArr1
>>>>>>>>>>>>>>>>>> ;;but this returns "nul opadr":
>>>>>>>>>>>>>>>>>>            iArr1[] fillarray 1, 2, 3
>>>>>>>>>>>>>>>>>>           iArr2[] = iArr1
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> endin
>>>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>>> i1 0 1
>>>>>>>>>>>>>>>>>> e
>>>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> 
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph
>>>>>>>>>>>>>>>>>> databases and their
>>>>>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph
>>>>>>>>>>>>>>>>> databases and their
>>>>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>>>>>>> and their
>>>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>>>>>> and their
>>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases
>>>>>>>>>>>>>> and their
>>>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>>>> this first edition is now available. Download your free book
>>>>>>>>>>>>>> today!
>>>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>>>>>>>>>> their
>>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>>>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>>>>>>>>> their
>>>>>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>>>>>> this first edition is now available. Download your free book today!
>>>>>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>>>>>> _______________________________________________
>>>>>>>>>>> Csound-devel mailing list
>>>>>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ------------------------------------------------------------------------------
>>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>>> "Graph Databases" is the definitive new guide to graph databases and
>>>>>>> their
>>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>>> this first edition is now available. Download your free book today!
>>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>>> _______________________________________________
>>>>>>> Csound-devel mailing list
>>>>>>> Csound-devel@lists.sourceforge.net
>>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>>
>>>>>>
>>>>>>
>>>>>> ------------------------------------------------------------------------------
>>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>>> applications. Written by three acclaimed leaders in the field,
>>>>>> this first edition is now available. Download your free book today!
>>>>>> http://p.sf.net/sfu/NeoTech
>>>>>> _______________________________________________
>>>>>> Csound-devel mailing list
>>>>>> Csound-devel@lists.sourceforge.net
>>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>>
>>>>>
>>>>> ------------------------------------------------------------------------------
>>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>>> applications. Written by three acclaimed leaders in the field,
>>>>> this first edition is now available. Download your free book today!
>>>>> http://p.sf.net/sfu/NeoTech
>>>>> _______________________________________________
>>>>> Csound-devel mailing list
>>>>> Csound-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Learn Graph Databases - Download FREE O'Reilly Book
>>>> "Graph Databases" is the definitive new guide to graph databases and their
>>>> applications. Written by three acclaimed leaders in the field,
>>>> this first edition is now available. Download your free book today!
>>>> http://p.sf.net/sfu/NeoTech
>>>> _______________________________________________
>>>> Csound-devel mailing list
>>>> Csound-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Learn Graph Databases - Download FREE O'Reilly Book
>>> "Graph Databases" is the definitive new guide to graph databases and their
>>> applications. Written by three acclaimed leaders in the field,
>>> this first edition is now available. Download your free book today!
>>> http://p.sf.net/sfu/NeoTech
>>> _______________________________________________
>>> Csound-devel mailing list
>>> Csound-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/csound-devel
>
> ------------------------------------------------------------------------------
> Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and their
> applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/NeoTech
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel
>

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net