Replies: 7 comments
-
I am not sure I understand the question. The GDML language does not istelf have an array tag. What it does have is a loop tag that allows the placement of arrays of object using loop parametrs. At present the GDML workbench does not make use of the loop tag to export arrays. However, arrays such as the one shawn in your attached figure are exported properly as multiple individual parts placed correctly. All elements of the arrays share the same material. That structure should be read correctly into geant4. Check the examples provided with the GDML Workbench Wiki. Perhaps I am missing something about the question. |
Beta Was this translation helpful? Give feedback.
-
Small point. In the screen shot the Part(Volume) experiment is at the same level as the worldVOL. The exporter should handle this but if you were to hand code the GDML there would only be one world Volume at the root level. If you are seeing a problem, my I suggest you select the Part/Volume experiment and drag it to the worldVol and this would then make the structure the same as if hand coded. Again if you are seeing a problem with this please let us know so we can address. |
Beta Was this translation helpful? Give feedback.
-
Yes, the experiment volume should be dragged onto the World volume, and then the World volume box be made large enough to encompass the experimet. There is an icon in the GDML Workbench that adjusts the size of the box to encompass all the parts underneath the World volume. |
Beta Was this translation helpful? Give feedback.
-
@MITgnome, KeithSloan finally explained the problem to me, which, I am afraid I missed on first viewing. Currently the GDML workbench does not support the export an array of logical voulmes (i.e., your DetectorModule and anything underneath it). Currently the GDML workbench only exports an array of solids, not logical volumes. The array is exported as a multiunion, which is a single solid, with a single material. Exporting the structure in your figure would involve an update, which may happen in the future. However, there is a way to accomplish the structure you have, albeit somewhat less elegantly: This is slightly more work, in that four arrays (each consisting of one solid) have to be created instead of one array containing four logical volumes, and one has to make sure each of the arrays contains the same number of elements and displacements. Please note that the arrays have to be arrays of solids, not logical volumes. |
Beta Was this translation helpful? Give feedback.
-
Have created an update for an Orthogonal Array of a Part. Need to create some more more complicated test cases i.e. Arrray of Array and more Complicated Part to do some more testing testExperiment.FCStd.txt Once this is all okay, I will move onto other types of Array with a Part/Volume |
Beta Was this translation helpful? Give feedback.
-
Hi Keith,
First off, I am not sure whom this reply is going to.
I pulled Main into one of my local repositories and started testing. I
began with the polarArray test and reproduced what you had.
(1) The test you had should not be given as an example (in the github),
because it produces overlapping volumes which geant complains about.
(2) When I tried to move (a) either the LV containing the box or (b) the
GDML_box itself, (so as to produce non-overlapping volumes), that
placement was not reflected in the output gdml file, see attached
screenshot and used FreeCAD file.
So, the placements of the array elements should be convolved
(multiplied) by the placements of the underlying elements, as I do for
other assembly objects. That has to be done recursively (as I do it), so
that no matter the level of daughters, the overall placement is still
correct.
I have not tested the rectangular array implementation yet, but I
suspect it will suffer from the same shortcoming, i.e., a rotation of
the underlying element, will probably be not reflected in the array.
Munther
…On 3/16/23 13:54, Keith Sloan wrote:
First pass of Polar Array with Part/Volume merged to Main.
polarArray.FCStd.txt
<https://github.com/KeithSloan/GDML/files/10995777/polarArray.FCStd.txt>
polarArray-worldVOL.gdml.txt
<https://github.com/KeithSloan/GDML/files/10995781/polarArray-worldVOL.gdml.txt>
Image 16-03-2023 at 20 46
<https://user-images.githubusercontent.com/2291247/225750218-90a5cf45-7307-4aa4-94e4-3b3f362cc59a.jpg>
—
Reply to this email directly, view it on GitHub
<#106 (comment)>,
or unsubscribe
|
Beta Was this translation helpful? Give feedback.
-
@MITgnome |
Beta Was this translation helpful? Give feedback.
-
Would you expect the Geant4 GDML Reader to properly import an gdml array of parts. The gdml files that I have succuessfully imported into Geant4 all seem to not be hierarchical. Making Arrays of detectors would make life easier for building the geometry, but I want to make sure that Geant4 would be able to read these types of gdml files in.
Beta Was this translation helpful? Give feedback.
All reactions