> Dear rooters, > Is it possible to write ROOT files directly from FORTRAN? > In principle i can write ntuple and then transform it to root file > but it is not convinuent and requres CERN libraries just to make > some temporary file. It is possible with some special implementation of Hbook2Root interface (based on the CFortran interface from ftp@zebra.desy.de for example). I've pointed with my previous reply one may create this interface and then link his old Fortran code against of this library instead of "standard" HBOOK.LIB coming with CERNLIB This way the Fortran code calling HBOOK1 will create the REAL ROOT object. HFILL will fill it. HROUT write it out, etc. There is an argument whether it is worth. But just to make you sense I did a dummy version of such sort of the interface and even check it with the "standard" CERNLIB HBOOK example 1. (see attachment). It does contain the REAL implementations of HBOOK1, HBOOK2,HFILL,HPRINT, HLIMIT,HDELET. It works. Just try to compile and link all three attachments together. The FULL implemetation needs writing out about 250 functions. I estimate it takes about 15 min/function=0.25 hours/fun = 250*0.25 = 60 hours = 12 days = 2 man-weeks to complete.(Don't forget to add some amount to maintain this code as well). With my regards, Valery Dr. Valeri Faine (Valery Fine) ------------ ------------- Phone: +41 22 767 4921 CERN FAX : +41 22 767 7155 CH-1211 Geneva, 23 mailto:fine@mail.cern.ch Switzerland http://nicewww.cern.ch/~fine
This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:26:21 MET