Message: Re: How to make each concentric shell sensitive and access information Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Ok Re: How to make each concentric shell sensitive and access information 

Forum: Geometry
Re: Question How to make each concentric shell sensitive and access information (aimsphere)
Re: None Re: How to make each concentric shell sensitive and access information (John Apostolakis)
Date: 19 Jul, 2010
From: aimsphere <aimsphere>

Thank you so much for giving me the appropriate solution what I was looking for actually. This seems to work. In fact I got my previous method to work as well. The problem I was facing earlier was with the data types.  e.g. in my previous code line:

std::string spherenum = "sphereNum_";sphereNum+=i;

here, i was interpreted a char with ascii code and first few ascii codes starting from 0 are reserved for non-printable characters. So now what I did was convert the number i into a string by using 'sprintf'. 
Then to get information I used the GetVolume method to get the name of the sensitive volume and then convert the string part representing i into a number by using 'sscanf' which basically gave me the layer number. 

Once again thank you for the quick reply, I appreciate it.

 Add Message Add Message
to: "Re: How to make each concentric shell sensitive and access information"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]