11.05.2013 Views

Sistema multicanal para aquisiç˜ao de dados em um ... - CBPFIndex

Sistema multicanal para aquisiç˜ao de dados em um ... - CBPFIndex

Sistema multicanal para aquisiç˜ao de dados em um ... - CBPFIndex

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

9 TGraphErrors ∗ graph ;<br />

10 // Gráfico<br />

11 TGraph ∗ g r a p h i n l e ;<br />

12 // Total <strong>de</strong> amostras<br />

13 I n t t N = 100000;<br />

14 // Valores dos <strong>dados</strong> nos a r q u i v o s<br />

15 Double t id , b a s e l i n e , amplitu<strong>de</strong> ;<br />

16 // Constantes <strong>de</strong> c a l i b r a ç ã o dos pres−mpds<br />

17 // x−y : carga (pC)−Valor <strong>de</strong> ADC(LSB)<br />

18 // y = ax + b<br />

19 // [ mpd ] [ ch ]<br />

20 Double t a [ 4 ] [ 4 ] = {273.5 , 2 7 2 . 3 , 2 6 6 . 9 , 2 7 2 . 5 ,<br />

21 2 5 9 . 7 , 2 6 0 . 1 , 2 5 0 . 2 , 2 5 8 . 0 ,<br />

22 2 6 0 . 9 , 2 6 0 . 4 , 2 6 1 . 2 , 2 6 0 . 3 ,<br />

23 2 6 1 . 2 , 2 5 9 . 7 , 2 6 1 . 5 , 2 5 4 . 7 } ;<br />

24 Double t b [ 4 ] [ 4 ] = { 1 2 . 1 6 , 1 3 . 6 6 , 1 2 . 4 7 , 1 1 . 9 8 ,<br />

25 1 0 . 7 8 , 1 2 . 1 9 , 1 6 . 3 8 , 1 2 . 3 ,<br />

26 1 1 . 4 5 , 1 4 . 9 , 1 3 . 4 4 , 1 4 . 9 8 ,<br />

27 1 7 . 2 3 , 1 7 . 3 3 , 1 8 . 0 1 , 7 . 4 9 } ;<br />

28 // Mapeamento <strong>de</strong> p i x e l s : [ mpd ] [ ch ]<br />

29 I n t t p i x e l s [ 4 ] [ 4 ] = { 19 , 20 , 21 , 22 ,<br />

30 27 , 28 , 29 , 30 ,<br />

31 35 , 36 , 37 , 38 ,<br />

32 43 , 44 , 45 , 46};<br />

33 // S t r i n g s <strong>para</strong> nomes e t i t u l o s<br />

34 char t i t u l o [ 5 0 ] ;<br />

35 char nome [ 5 0 ] ;<br />

36 // Stream <strong>para</strong> a b r i r a r q u i v o s <strong>de</strong> <strong>dados</strong><br />

37 i f s t r e a m in ;<br />

38 // v a r i a v e i s u t i l i z a d a s <strong>para</strong> a b r i r d i r e t ó r i o do r e s p e c t i v o canal<br />

39 int canal , mpd ;<br />

40 char p i x e l s p a t h [ 5 0 ] ;<br />

41 char path [ 5 0 ] ;<br />

42<br />

43 cout > p i x e l s p a t h ;<br />

45 cout > mpd ;<br />

47 i f (mpd4){ cout

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!