[R] Memory errors when using QCA package

Allan Engelhardt allane at cybaea.com
Wed Jul 22 15:16:35 CEST 2009


It is a little stupid, but the length of a vector is limited to 2^31-1 
entries on any platform.  A matrix is stored as a vector, so the product 
of all dimensions is also limited to 2^31-1.

Allan.

Matthew Gwynne wrote:
> Hi,
>
> I have been using the QCA package, in particular the "eqmcc" function
> and I am having some issues when trying to use this to minimise a
> particular boolean function.
>
> The  boolean function in question has 16 variables, and I am providing
> the full truth table for the function (65536 with 256 true entries),
> in the following way :
>
> library(QCA)
>
> func_tt = read.table("func.tt",header=TRUE)
> eqmcc(func_tt, outcome="O", expl.0=TRUE)
>
> However, after calculating for a little while, the system throws up a
> memory error :
>
> Error in vector("double", length) :
>   cannot allocate vector of length 2130706560
>
>
> However, looking at the memory usage, I seem to have far more than 2GB free.
>
> Is there some kind of built-in limit on the size of the heap in R? If
> so, is there some way I can extend this?
>
> Does anyone have any insight into this? Perhaps I am doing something stupid?
>
> Thanks
>
> Matthew
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>




More information about the R-help mailing list