Dear Ali, A couple of comments. Indeed lots of energy is transferred into heat, but not all. Therefore, using temperature (after calibrating specific heat coefficient of the device ) is not a good method. Some energy is radiated as visible and invisible light and hard to catch it all. Some as vibration. Some energy is used to flip the bits on the disk. So to speak internal energy.
Thus, monitoring input power is the only way. However, since many jobs are running, the results will be indeed inconsistent. Some people, therefore, erroneously conclude that the question is not answerable. This is not true. A properly crafted research proposal could get funding needed to accomplish this fine goal. I expect 1 million US dollars for 5 years should be close to sufficient. Make sure you measure how long SQLIte performs the task, record power consumption in that period. Then run machine for the same period without SQLIte. Difference in power consumption is what was due to SQLite, controlling for the other processes. Obviously, caching and other things already mentioned, will affect the numbers. Thus, you need to properly randomize these trials, playing with their durations. You will have to perform many of these (therefore 5 year long project) to average out all fluctuations. Given complexity of the project, you should consider getting initial funding to design it in the first place and obtain preliminary data (and necessary equipment) to justify and ensure future success. It appears, given your initial email, that such funding is well underway towards being secured. Be sure to control temperature and humanity in the room, because cooling fans also consume energy, which depends on their speed and viscosity of the air. The tidal forces (of the moon) will affect friction in bearings of all moving parts (fans, disks). Be sure to either co-vary for them or randomize experiments for different phases of the moon. DO NOT MOVE computer while experiment is running. Coriolis force will affect friction in all rotating parts as well. In summary, this is a perfectly doable experiment, if carefully planned and executed. Radio astronomy easily reaches sensitivities of 10^{-9}. You can do it too! At conclusion of the 5 year research period, SQLite will be much different from what it is today. So will kernels of operating systems, hardware etc. Therefore, at conclusion of the research, you will have answered how much power was consumed by SQLite 5 years ago. I am sure this will be very valuable piece of information then, after all the money and efforts are spent. Because of this short delay (5 years is short on the astronomical time scale) and because of the experience you gained by conclusion of the project, I am rather certain you will be able to obtain additional funding to continue and refine the answer to the newer version of SQLite available then. The future is in your hands! Roman ________________________________________ From: sqlite-users [sqlite-users-boun...@mailinglists.sqlite.org] on behalf of Ali Dorri [alidorri...@gmail.com] Sent: Tuesday, November 21, 2017 4:49 PM To: Robert Oeffner Cc: SQLite mailing list Subject: Re: [sqlite] Energy consumption of SQLite queries Dear All, Thanks for your comments. That was really helpful. Regards Ali On Tue, Nov 21, 2017 at 11:41 PM, Robert Oeffner <rob...@oeffner.net> wrote: > This is an interesting topic more belonging to the realms of information > theory and statistical physics. > > I am not an expert in this area but from what I recall from undergraduate > physics the moment you create order in one corner of the universe entropy > rises in another place of the universe. If you loosely speaking equate > information gathering such as an SQL query as creating order then that must > have a cost in terms of increasing the entropy (heat in this case) > elsewhere. There is a lower bound on how little entropy is generated during > this process which comes down to the efficiency of the process (hardware > and software in your case). > > One could get philosophical here and question whether mankinds computer > modeling of climate change in itself causes the excess heat leading to > global warming. > > > Regards, > > Robert > > > -- > Robert Oeffner, Ph.D. > Research Associate, > The Read Group, Department of Haematology, > Cambridge Institute for Medical Research > University of Cambridge > Cambridge Biomedical Campus > Wellcome Trust/MRC Building > Hills Road > Cambridge CB2 0XY > www.cimr.cam.ac.uk/investigators/read/index.html > > > > Date: Tue, 21 Nov 2017 09:54:25 +1100 >> From: Ali Dorri <alidorri...@gmail.com> >> To: SQLite mailing list <sqlite-users@mailinglists.sqlite.org> >> Subject: [sqlite] Energy consumption of SQLite queries >> Message-ID: >> <CAOB3cEGoh=pnp2syjegouoqcve2+q35s99pt4lzx_cu_6uc...@mail.gm >> ail.com> >> Content-Type: text/plain; charset="UTF-8" >> >> Dear All, >> >> I am doing a research on the energy consumed by a query in SQLite. I have >> a >> program which fills a database with blocks of data. Then, it attempts to >> remove some data from the database. I don't know how to measure the energy >> consumed from my host, i.e., my laptop which has both the SQLite and the >> program, from the time I generated the query till the query is finished >> and >> control returns back to my program. >> >> Any help is highly appreciated. >> >> Regards >> Ali >> >> >> > > > > _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users