[Date Index] [Thread Index] [Author Index]
Re: Array problems in Mathematica
>Secondly, using CForm on arrays gives the output in unappropriate form. >i.e. CForm[a] = a(1) and not a >Now try to write a C program splicing in output from Mathematica containing >arrays and the compiler recognises a() as a function, not an array. >Is there a way round this? I really can't understand the logic here, since >both Mathematica and C use  for array arguments, so why should CForm convert >to ()? A C array is more like a Mathematica list, as you can see below: In:= CForm[HoldForm[a[]]] Out//CForm= a In:= CForm[HoldForm[a]] Out//CForm= a(1) Arthur L. Rubin 216-5888 at mcimail.com 70707.453 at compuserve.com arthur at pnet01.cts.com (personal) a_rubin at dsg4.dse.beckman.com (work) Beckman Instruments/Brea My opinions are my own, and do not represent those of my employer.