igraph-help
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [igraph] memory usage


From: Tamás Nepusz
Subject: Re: [igraph] memory usage
Date: Mon, 30 Jan 2012 13:39:45 +0100

Dear Yulia,

> I have recently been searching for information on how much memory is needed 
> to store an igraph object.
> During this search I have found two contradictory posts:
> one (from Tamás Nepusz) claiming that igraph allocates 16 bytes per edge + 8 
> bytes per vertex,
> and another one (from Gabor Czardi) (it was actually a presentation) saying 
> that it allocates twice as much: 
> 32 bytes per edge + 16 bytes per vertex.
> 
> So I would greatly appreciate if someone could tell me how much memory is 
> being used in the current implementation . Or does it somehow depend on the 
> OS or the hardware ?
It ultimately depends on the size of the "double" data type in C on your OS or 
the hardware. If your "double" is 8 bytes long, then the required memory is 
8*4*|E| + 8*2*|V|. I might have been wrong to assume that a "double" takes up 
only 4 bytes, so I think that Gabor's figures are correct.

-- 
Tamas


reply via email to

[Prev in Thread] Current Thread [Next in Thread]