The start time is : almost NOW (the time at which the script is executed) actually, the nearest preceding hour beginning. The time is in general expressed in UTC time with the C time() function This will obviously most of the time not be the time displayed on your watch since it is universal time. See the C time functions for converting this time into more useful structures.
#include <time.h>
{
time_t script_time;
script_time = time(0);
script_time = 3600*(
int)(script_time/3600);
int i;
float noise;
TH1F *ht =
new TH1F(
"ht",
"Love at first sight",3000,0.,2000.);
for (i=1;i<3000;i++) {
if (i>700) {
noise += 1000*sin((i-700)*6.28/30)*exp((double)(700-i)/300);
}
}
for (i=0;i<100;i++) {
x[i] =
sin(i*4*3.1415926/50)*
exp(-(
double)i/20);
}
for (i=0;i<10;i++) {
t2[i] = i*365*86400;
}
gt2->
SetTitle(
"Number of monkeys on the moon");
return ct;
}
Option_t Option_t TPoint TPoint const char x2
R__EXTERN TRandom * gRandom
R__EXTERN TStyle * gStyle
virtual void SetLabelSize(Float_t size=0.04)
Set size of axis labels.
virtual void SetLineWidth(Width_t lwidth)
Set the line width.
virtual void SetLineColor(Color_t lcolor)
Set the line color.
virtual void SetMarkerColor(Color_t mcolor=1)
Set the marker color.
virtual void SetMarkerStyle(Style_t mstyle=1)
Set the marker style.
virtual void SetMarkerSize(Size_t msize=1)
Set the marker size.
virtual void SetTimeDisplay(Int_t value)
virtual void SetTimeFormat(const char *format="")
Change the format used for time plotting.
TVirtualPad * cd(Int_t subpadnumber=0) override
Set current canvas & pad.
A TGraph is an object made of two arrays X and Y with npoints each.
void Draw(Option_t *chopt="") override
Draw this graph with its current attributes.
TAxis * GetXaxis() const
Get x axis of the graph.
void SetTitle(const char *title="") override
Change (i.e.
1-D histogram with a float per channel (see TH1 documentation)}
void Draw(Option_t *option="") override
Draw this histogram with options.
virtual void SetBinContent(Int_t bin, Double_t content)
Set bin content see convention for numbering bins in TH1::GetBin In case the bin number is greater th...
void Divide(Int_t nx=1, Int_t ny=1, Float_t xmargin=0.01, Float_t ymargin=0.01, Int_t color=0) override
Automatic pad generation by division.
virtual Double_t Gaus(Double_t mean=0, Double_t sigma=1)
Samples a random number from the standard Normal (Gaussian) Distribution with the given mean and sigm...
void SetTimeOffset(Double_t toffset)
Change the time offset for time plotting.
void SetTitleH(Float_t h=0)
RVec< PromoteType< T > > exp(const RVec< T > &v)
RVec< PromoteType< T > > sin(const RVec< T > &v)