bad approximation of composition materials

6 views
Skip to first unread message

Chloé Largeron

unread,
Apr 18, 2023, 10:46:54 AM4/18/23
to pyne...@googlegroups.com

Dear Pyne-developers,

 

I have encountered an issue with using the Material object of pyne.

 

I have constructed a dictionary with composition of 12 elements where one is really high = 0.99970 and the others are really low = 0.00001 or 0.00005

The sum of these elements is not exactly one (the sum is equal to  1.0000800000000003)

I don’t provide to you the exactitude of my composition since I might be not allowed to.

 

Then when I construct it with the Material object with pyne (which is normalized) I obtain an high approximation of the really high elements (= 0.999620030397568) and the lowest elements = 9.99920006399488e-06

 

My dictionary has the following values (please change XX by an element) :

{'XXhigh': 0.9997, 'XX': 2e-05, 'XX': 2e-05, 'XX': 2e-05, 'XX': 0.0002, 'XX': 2e-05, 'XX': 1e-05, 'XX': 5e-05, 'XX': 1e-05, 'XX': 1e-05, 'XX': 1e-05, 'XX': 1e-05}

The composition I obtain with the Material object is :

{XX: 9.99920006399488e-06, XX: 9.99920006399488e-06, XX: 9.99920006399488e-06, XX: 9.99920006399488e-06, XX: 1.999840012798976e-05, XX: 1.999840012798976e-05, XX: 1.999840012798976e-05, XX: 1.999840012798976e-05, XX: 9.99920006399488e-06, XX: 4.99960003199744e-05, XXhigh: 0.9996200303975682, XX: 0.0001999840012798976}

 

The atomic fraction of each element has changed with using the material object, the difference between 0.9997 and 0.99962 is not acceptable to my study.

How could I fix this problem ? How can you explain such differences ?

 

Thank you,

 

Best regards,

 

 

Chloé Largeron
Research engineer

 

chloe.l...@newcleo.com

 

Paul Wilson

unread,
Apr 18, 2023, 8:48:31 PM4/18/23
to pyne...@googlegroups.com

Hello Chloé,

 

I think what you are seeing is the correct behavior.  You have defined your material with atom fractions that sum to a number greater than 1, namely 1.0000800000000003.   PyNE normalizes these material fractions to 1 by dividing all these values by this total:  0.9997/1.0000800000000003 = 0.99962

 

Can you clarify what you expect?  Perhaps there is another way to use PyNE to meet your expecations.

 

Paul

 

-- 
-- ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ --
Paul P.H. Wilson (he/him/his)
Grainger Professor of Nuclear Engineering
Chair, Department of Engineering Physics
o: 608-263-0807, c: 608-469-9615
paul....@wisc.edu
153 Engineering Research Bldg
1500 Engineering Dr, Madison, WI 53706
Zoom Meeting Room: https://uwmadison.zoom.us/j/6082630807
Zoom Phone Access: +1-929-205-6099, Access code: 6082630807

Computational Nuclear Engineering Research Group

 

--

---
You received this message because you are subscribed to the Google Groups "PyNE" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pyne-dev+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pyne-dev/PR3PR09MB5233F305FB473878D08FE59581999%40PR3PR09MB5233.eurprd09.prod.outlook.com.

Reply all
Reply to author
Forward
0 new messages