SlideShare a Scribd company logo
1 of 26
Download to read offline
Non-equilibrium Molecular Simulations of Polymers
under Flow: Saving Energy through Process
Optimization
Jamil Gafur, Lintao Bu, Michael Crowley
Renewable Resources and Enabling Science Center at
the National Renewable Energy Lab (NREL)
NREL is a national laboratory of the U.S. Department of Energy Office of Energy Efficiency and Renewable Energy operated
by the Alliance for Sustainable Energy, LLC
Background
• We are studying the process of
plastic extrusion to minimize the
polymer build up around the
extrusion pipe
• When build up starts to occur the
overall structure and stability of the
product decreases significantly https://en.wikipedia.org/wiki/Plastic_extrusion
Background
• We are studying the process of
plastic extrusion to minimize the
polymer build up around the
extrusion pipe
• When build up starts to occur the
overall structure and stability of the
product decreases significantly https://en.wikipedia.org/wiki/Plastic_extrusion
Background
• We are studying the process of
plastic extrusion to minimize the
polymer build up around the
extrusion pipe
• When build up starts to occur the
overall structure and stability of the
product decreases significantly https://en.wikipedia.org/wiki/Plastic_extrusion
Feed pipe
Flow velocity (Normal)
Laminar flow (Slow)
Background
• We are studying the process of
plastic extrusion to minimize the
polymer build up around the
extrusion pipe
• When build up starts to occur the
overall structure and stability of the
product decreases significantly https://en.wikipedia.org/wiki/Plastic_extrusion
Molecular Weight Distribution
Background
• We are studying the process of
plastic extrusion to minimize the
polymer build up around the
extrusion pipe
• When build up starts to occur the
overall structure and stability of the
product decreases significantly https://en.wikipedia.org/wiki/Plastic_extrusion
Molecular Weight Distribution
Impact
• This project combines DOE High Performance Computing capabilities
with established and emerging molecular simulation techniques to
address industrially relevant issues of practical interest to
US Manufacturing competitiveness.
• Our work this summer is focused on setting up the codebase for future
development, and optimizing the code to allow for optimal use of
allocated nodes
Initial work
• Given a zip file of Fortran 90 codes and an associated simulation script; this zip file was sent the
main way of distributing the code
• There was no documentation on how to run the simulations, or how the code worked
• We have existing codes that simulate the extrusion process; however, it does not run efficiently
(some runs taking more than 6 months to run)
• This code has not been optimized in any way, nor has the codebase been under any form of RSE
practices
• CI
• Unit testing
• Documentation
First steps
• Set up version control on GitHub
• Set up timelines, milestones and issues with
short term, and long-term goals in mind
• Initiated some form of unit testing.
• Currently in the process of having better unit
tests
• Ran the simulation, saved the output files
and compared future runs to this "golden"
set of output files
• "I have the same level of confidence that this
code works now, as when I got it.”
• “I have no way of knowing if there are any errors
associated with the algorithms"
- Jamil Gafur
https://github.com/crowleymf/hpc4eidow
File Structure and Initial profiling
• Initial results showed that the code mostly
focused on computation
• There was no MPI, or open MP added to the
codebase, thus everything was running on one
core
• The rest of the time was spent on I/O
• Takes about 11 min for the "test case" to run
Optimization
Using the intel profiler (VTune) we identified parts of the code that
can be optimized, our results are shown below
Vel.f90 utilization
Next step, Optimization of code
• Most of the issues we found were due to memory allocation,
something that can't easily be fixed
Next step, Optimization of code
• Most of the issues we found were due to memory allocation,
something that can't easily be fixed
BUT WHO SAID LIFE WAS EASY?
Next step, Optimization of code
• Most of the issues we found were due to memory allocation,
something that can't easily be fixed
BUT WHO SAID LIFE WAS EASY?
Next step, Optimization of code
• Most of the issues we found were due to memory allocation,
something that can't easily be fixed
BUT WHO SAID LIFE WAS EASY?
~20%
0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
Index
Bits
Integer
(dmask)
Integer
(dmask)
Use the d value as binary operators for our integer
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
Integer (16) Index
Bits
0 0 0 1 0 0 1 0 1 0 1 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
Index
Bits
Use the d value as binary operators for our integer
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
Integer (16) Index
Bits
0 0 0 1 0 0 1 0 1 0 1 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0
0 0 0 1 0 0 1 0 1 0 1 0 0 0 0 0
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
Index
Bits
0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0
iand
Integer
(dmask)
• We have condensed an if-statement (>20 clock cycles) into 2 clock
cycles.
• iand
• ishft
0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0
Left 4
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
Original Code we were given
Updated Code we updated
Optimized Using -0fast flag when compiling
Non-optimized !^
Output Write output logs every 10 iterations (default of
original code)
No-Output Writes output at last iteration
Original Code we were given
Updated Code we updated
Optimized Using -0fast flag when compiling
Non-optimized !^
Output Write output logs every 10 iterations (default of
original code)
No-Output Writes output at last iteration
Conclusion
• It is important to use good
programming practices and
algorithm design before
implementing parallelization
• Profiling a code gives you a
good idea on where you can
update code to get the most
speed up
• Version control, V&V,
documentation
Moving Forward
• Moving forward our group would like to implement MPI
to allow for multi-node support.
• Using MPI we believe we can offload the I/O to a
separate process and gain an additional 11% speedup
Thank you for your time
Special thanks to:
• Mentors/Advisors:
• Dr. Lintao Bu
• Dr. Michael Crowley
• Dr. Suely Oliveira
• Dr. Gretta Kellogg
• Energy Efficiency and Renewable Energy (EERE) Advanced
Manufacturing Office (AMO)
• Oak Ridge Institute for Science and Education (ORISE)
• University of Iowa Computer Science Department
About me:
https://jamilggafur.gitlab.io/
jamil-gafur@uiowa.edu

More Related Content

Similar to Non equilibrium Molecular Simulations of Polymers under Flow Saving Energy through Process Optimization

Preparing for Enterprise Continuous Delivery - 5 Critical Steps
Preparing for Enterprise Continuous Delivery - 5 Critical StepsPreparing for Enterprise Continuous Delivery - 5 Critical Steps
Preparing for Enterprise Continuous Delivery - 5 Critical StepsXebiaLabs
 
Laying the Foundation for Ionic Platform Insights on Spark
Laying the Foundation for Ionic Platform Insights on SparkLaying the Foundation for Ionic Platform Insights on Spark
Laying the Foundation for Ionic Platform Insights on SparkIonic Security
 
Using Static Binary Analysis To Find Vulnerabilities And Backdoors in Firmware
Using Static Binary Analysis To Find Vulnerabilities And Backdoors in FirmwareUsing Static Binary Analysis To Find Vulnerabilities And Backdoors in Firmware
Using Static Binary Analysis To Find Vulnerabilities And Backdoors in FirmwareLastline, Inc.
 
MongoDB World 2019: Finding the Right MongoDB Atlas Cluster Size: Does This I...
MongoDB World 2019: Finding the Right MongoDB Atlas Cluster Size: Does This I...MongoDB World 2019: Finding the Right MongoDB Atlas Cluster Size: Does This I...
MongoDB World 2019: Finding the Right MongoDB Atlas Cluster Size: Does This I...MongoDB
 
Improving Batch-Process Testing Techniques with a Domain-Specific Language
Improving Batch-Process Testing Techniques with a Domain-Specific LanguageImproving Batch-Process Testing Techniques with a Domain-Specific Language
Improving Batch-Process Testing Techniques with a Domain-Specific LanguageDr. Spock
 
Silicon Valley Code Camp 2015 - Advanced MongoDB - The Sequel
Silicon Valley Code Camp 2015 - Advanced MongoDB - The SequelSilicon Valley Code Camp 2015 - Advanced MongoDB - The Sequel
Silicon Valley Code Camp 2015 - Advanced MongoDB - The SequelDaniel Coupal
 
The OMR GC talk - Ruby Kaigi 2015
The OMR GC talk - Ruby Kaigi 2015The OMR GC talk - Ruby Kaigi 2015
The OMR GC talk - Ruby Kaigi 2015craig lehmann
 
Introduction to Agile Hardware
Introduction to Agile Hardware Introduction to Agile Hardware
Introduction to Agile Hardware Cprime
 
It Does What You Say, Not What You Mean: Lessons From A Decade of Program Repair
It Does What You Say, Not What You Mean: Lessons From A Decade of Program RepairIt Does What You Say, Not What You Mean: Lessons From A Decade of Program Repair
It Does What You Say, Not What You Mean: Lessons From A Decade of Program RepairClaire Le Goues
 
Jfokus 2016 - A JVMs Journey into Polyglot Runtimes
Jfokus 2016 - A JVMs Journey into Polyglot RuntimesJfokus 2016 - A JVMs Journey into Polyglot Runtimes
Jfokus 2016 - A JVMs Journey into Polyglot RuntimesCharlie Gracie
 
goployer, 코드 기반의 배포 도구 - 송주영 (beNX) :: AWS Community Day 2020
goployer, 코드 기반의 배포 도구 - 송주영 (beNX) :: AWS Community Day 2020goployer, 코드 기반의 배포 도구 - 송주영 (beNX) :: AWS Community Day 2020
goployer, 코드 기반의 배포 도구 - 송주영 (beNX) :: AWS Community Day 2020AWSKRUG - AWS한국사용자모임
 
Design for Scale / Surge 2010
Design for Scale / Surge 2010Design for Scale / Surge 2010
Design for Scale / Surge 2010Christopher Brown
 
Pipeline as code for your infrastructure as Code
Pipeline as code for your infrastructure as CodePipeline as code for your infrastructure as Code
Pipeline as code for your infrastructure as CodeKris Buytaert
 
Giving automated tests the love they deserve at Listings
Giving automated tests the love they deserve at ListingsGiving automated tests the love they deserve at Listings
Giving automated tests the love they deserve at ListingsJordi Pradel
 
Behavior-Driven Development (BDD) Testing with Apache Spark with Aaron Colcor...
Behavior-Driven Development (BDD) Testing with Apache Spark with Aaron Colcor...Behavior-Driven Development (BDD) Testing with Apache Spark with Aaron Colcor...
Behavior-Driven Development (BDD) Testing with Apache Spark with Aaron Colcor...Databricks
 
Large Scale Architecture -- The Unreasonable Effectiveness of Simplicity
Large Scale Architecture -- The Unreasonable Effectiveness of SimplicityLarge Scale Architecture -- The Unreasonable Effectiveness of Simplicity
Large Scale Architecture -- The Unreasonable Effectiveness of SimplicityRandy Shoup
 
How I Learned to Stop Worrying and Love Legacy Code.....
How I Learned to Stop Worrying and Love Legacy Code.....How I Learned to Stop Worrying and Love Legacy Code.....
How I Learned to Stop Worrying and Love Legacy Code.....Mike Harris
 
Performant Django - Ara Anjargolian
Performant Django - Ara AnjargolianPerformant Django - Ara Anjargolian
Performant Django - Ara AnjargolianHakka Labs
 
Infrastructure as Code for Network
Infrastructure as Code for NetworkInfrastructure as Code for Network
Infrastructure as Code for NetworkDamien Garros
 

Similar to Non equilibrium Molecular Simulations of Polymers under Flow Saving Energy through Process Optimization (20)

Preparing for Enterprise Continuous Delivery - 5 Critical Steps
Preparing for Enterprise Continuous Delivery - 5 Critical StepsPreparing for Enterprise Continuous Delivery - 5 Critical Steps
Preparing for Enterprise Continuous Delivery - 5 Critical Steps
 
Laying the Foundation for Ionic Platform Insights on Spark
Laying the Foundation for Ionic Platform Insights on SparkLaying the Foundation for Ionic Platform Insights on Spark
Laying the Foundation for Ionic Platform Insights on Spark
 
Using Static Binary Analysis To Find Vulnerabilities And Backdoors in Firmware
Using Static Binary Analysis To Find Vulnerabilities And Backdoors in FirmwareUsing Static Binary Analysis To Find Vulnerabilities And Backdoors in Firmware
Using Static Binary Analysis To Find Vulnerabilities And Backdoors in Firmware
 
MongoDB World 2019: Finding the Right MongoDB Atlas Cluster Size: Does This I...
MongoDB World 2019: Finding the Right MongoDB Atlas Cluster Size: Does This I...MongoDB World 2019: Finding the Right MongoDB Atlas Cluster Size: Does This I...
MongoDB World 2019: Finding the Right MongoDB Atlas Cluster Size: Does This I...
 
Fastest Servlets in the West
Fastest Servlets in the WestFastest Servlets in the West
Fastest Servlets in the West
 
Improving Batch-Process Testing Techniques with a Domain-Specific Language
Improving Batch-Process Testing Techniques with a Domain-Specific LanguageImproving Batch-Process Testing Techniques with a Domain-Specific Language
Improving Batch-Process Testing Techniques with a Domain-Specific Language
 
Silicon Valley Code Camp 2015 - Advanced MongoDB - The Sequel
Silicon Valley Code Camp 2015 - Advanced MongoDB - The SequelSilicon Valley Code Camp 2015 - Advanced MongoDB - The Sequel
Silicon Valley Code Camp 2015 - Advanced MongoDB - The Sequel
 
The OMR GC talk - Ruby Kaigi 2015
The OMR GC talk - Ruby Kaigi 2015The OMR GC talk - Ruby Kaigi 2015
The OMR GC talk - Ruby Kaigi 2015
 
Introduction to Agile Hardware
Introduction to Agile Hardware Introduction to Agile Hardware
Introduction to Agile Hardware
 
It Does What You Say, Not What You Mean: Lessons From A Decade of Program Repair
It Does What You Say, Not What You Mean: Lessons From A Decade of Program RepairIt Does What You Say, Not What You Mean: Lessons From A Decade of Program Repair
It Does What You Say, Not What You Mean: Lessons From A Decade of Program Repair
 
Jfokus 2016 - A JVMs Journey into Polyglot Runtimes
Jfokus 2016 - A JVMs Journey into Polyglot RuntimesJfokus 2016 - A JVMs Journey into Polyglot Runtimes
Jfokus 2016 - A JVMs Journey into Polyglot Runtimes
 
goployer, 코드 기반의 배포 도구 - 송주영 (beNX) :: AWS Community Day 2020
goployer, 코드 기반의 배포 도구 - 송주영 (beNX) :: AWS Community Day 2020goployer, 코드 기반의 배포 도구 - 송주영 (beNX) :: AWS Community Day 2020
goployer, 코드 기반의 배포 도구 - 송주영 (beNX) :: AWS Community Day 2020
 
Design for Scale / Surge 2010
Design for Scale / Surge 2010Design for Scale / Surge 2010
Design for Scale / Surge 2010
 
Pipeline as code for your infrastructure as Code
Pipeline as code for your infrastructure as CodePipeline as code for your infrastructure as Code
Pipeline as code for your infrastructure as Code
 
Giving automated tests the love they deserve at Listings
Giving automated tests the love they deserve at ListingsGiving automated tests the love they deserve at Listings
Giving automated tests the love they deserve at Listings
 
Behavior-Driven Development (BDD) Testing with Apache Spark with Aaron Colcor...
Behavior-Driven Development (BDD) Testing with Apache Spark with Aaron Colcor...Behavior-Driven Development (BDD) Testing with Apache Spark with Aaron Colcor...
Behavior-Driven Development (BDD) Testing with Apache Spark with Aaron Colcor...
 
Large Scale Architecture -- The Unreasonable Effectiveness of Simplicity
Large Scale Architecture -- The Unreasonable Effectiveness of SimplicityLarge Scale Architecture -- The Unreasonable Effectiveness of Simplicity
Large Scale Architecture -- The Unreasonable Effectiveness of Simplicity
 
How I Learned to Stop Worrying and Love Legacy Code.....
How I Learned to Stop Worrying and Love Legacy Code.....How I Learned to Stop Worrying and Love Legacy Code.....
How I Learned to Stop Worrying and Love Legacy Code.....
 
Performant Django - Ara Anjargolian
Performant Django - Ara AnjargolianPerformant Django - Ara Anjargolian
Performant Django - Ara Anjargolian
 
Infrastructure as Code for Network
Infrastructure as Code for NetworkInfrastructure as Code for Network
Infrastructure as Code for Network
 

More from ORAU

Mining Data for Ore Natural Language Processing to Identify Lithium Minerals ...
Mining Data for Ore Natural Language Processing to Identify Lithium Minerals ...Mining Data for Ore Natural Language Processing to Identify Lithium Minerals ...
Mining Data for Ore Natural Language Processing to Identify Lithium Minerals ...ORAU
 
Simulation of Electrochemical Processes in Aluminum Smelting
Simulation of Electrochemical Processes in Aluminum SmeltingSimulation of Electrochemical Processes in Aluminum Smelting
Simulation of Electrochemical Processes in Aluminum SmeltingORAU
 
Fossil resources support energy storage systems
Fossil resources support energy storage systemsFossil resources support energy storage systems
Fossil resources support energy storage systemsORAU
 
Lesson 9 Energy and You | The Harnessed Atom (2016)
Lesson 9 Energy and You | The Harnessed Atom (2016)Lesson 9 Energy and You | The Harnessed Atom (2016)
Lesson 9 Energy and You | The Harnessed Atom (2016)ORAU
 
Lesson 8 Concerns | The Harnessed Atom (2016)
Lesson 8 Concerns | The Harnessed Atom (2016)Lesson 8 Concerns | The Harnessed Atom (2016)
Lesson 8 Concerns | The Harnessed Atom (2016)ORAU
 
Lesson 7 Waste from Nuclear Power Plants | The Harnessed Atom (2016)
Lesson 7 Waste from Nuclear Power Plants | The Harnessed Atom (2016)Lesson 7 Waste from Nuclear Power Plants | The Harnessed Atom (2016)
Lesson 7 Waste from Nuclear Power Plants | The Harnessed Atom (2016)ORAU
 
Lesson 6 Atoms to Electricity | The Harnessed Atom (2016)
Lesson 6 Atoms to Electricity | The Harnessed Atom (2016)Lesson 6 Atoms to Electricity | The Harnessed Atom (2016)
Lesson 6 Atoms to Electricity | The Harnessed Atom (2016)ORAU
 
Lesson 5 Fission and Chain Reactions | The Harnessed Atom (2016)
Lesson 5 Fission and Chain Reactions | The Harnessed Atom (2016)Lesson 5 Fission and Chain Reactions | The Harnessed Atom (2016)
Lesson 5 Fission and Chain Reactions | The Harnessed Atom (2016)ORAU
 
Lesson 4 Ionizing Radiation | The Harnessed Atom (2016)
Lesson 4 Ionizing Radiation | The Harnessed Atom (2016)Lesson 4 Ionizing Radiation | The Harnessed Atom (2016)
Lesson 4 Ionizing Radiation | The Harnessed Atom (2016)ORAU
 
Lesson 2 Electricity | The Harnessed Atom (2016)
Lesson 2 Electricity | The Harnessed Atom (2016)Lesson 2 Electricity | The Harnessed Atom (2016)
Lesson 2 Electricity | The Harnessed Atom (2016)ORAU
 
Lesson 3 Atoms and Isotopes | The Harnessed Atom (2016)
Lesson 3 Atoms and Isotopes | The Harnessed Atom (2016)Lesson 3 Atoms and Isotopes | The Harnessed Atom (2016)
Lesson 3 Atoms and Isotopes | The Harnessed Atom (2016)ORAU
 
Fermi Feud
Fermi FeudFermi Feud
Fermi FeudORAU
 

More from ORAU (12)

Mining Data for Ore Natural Language Processing to Identify Lithium Minerals ...
Mining Data for Ore Natural Language Processing to Identify Lithium Minerals ...Mining Data for Ore Natural Language Processing to Identify Lithium Minerals ...
Mining Data for Ore Natural Language Processing to Identify Lithium Minerals ...
 
Simulation of Electrochemical Processes in Aluminum Smelting
Simulation of Electrochemical Processes in Aluminum SmeltingSimulation of Electrochemical Processes in Aluminum Smelting
Simulation of Electrochemical Processes in Aluminum Smelting
 
Fossil resources support energy storage systems
Fossil resources support energy storage systemsFossil resources support energy storage systems
Fossil resources support energy storage systems
 
Lesson 9 Energy and You | The Harnessed Atom (2016)
Lesson 9 Energy and You | The Harnessed Atom (2016)Lesson 9 Energy and You | The Harnessed Atom (2016)
Lesson 9 Energy and You | The Harnessed Atom (2016)
 
Lesson 8 Concerns | The Harnessed Atom (2016)
Lesson 8 Concerns | The Harnessed Atom (2016)Lesson 8 Concerns | The Harnessed Atom (2016)
Lesson 8 Concerns | The Harnessed Atom (2016)
 
Lesson 7 Waste from Nuclear Power Plants | The Harnessed Atom (2016)
Lesson 7 Waste from Nuclear Power Plants | The Harnessed Atom (2016)Lesson 7 Waste from Nuclear Power Plants | The Harnessed Atom (2016)
Lesson 7 Waste from Nuclear Power Plants | The Harnessed Atom (2016)
 
Lesson 6 Atoms to Electricity | The Harnessed Atom (2016)
Lesson 6 Atoms to Electricity | The Harnessed Atom (2016)Lesson 6 Atoms to Electricity | The Harnessed Atom (2016)
Lesson 6 Atoms to Electricity | The Harnessed Atom (2016)
 
Lesson 5 Fission and Chain Reactions | The Harnessed Atom (2016)
Lesson 5 Fission and Chain Reactions | The Harnessed Atom (2016)Lesson 5 Fission and Chain Reactions | The Harnessed Atom (2016)
Lesson 5 Fission and Chain Reactions | The Harnessed Atom (2016)
 
Lesson 4 Ionizing Radiation | The Harnessed Atom (2016)
Lesson 4 Ionizing Radiation | The Harnessed Atom (2016)Lesson 4 Ionizing Radiation | The Harnessed Atom (2016)
Lesson 4 Ionizing Radiation | The Harnessed Atom (2016)
 
Lesson 2 Electricity | The Harnessed Atom (2016)
Lesson 2 Electricity | The Harnessed Atom (2016)Lesson 2 Electricity | The Harnessed Atom (2016)
Lesson 2 Electricity | The Harnessed Atom (2016)
 
Lesson 3 Atoms and Isotopes | The Harnessed Atom (2016)
Lesson 3 Atoms and Isotopes | The Harnessed Atom (2016)Lesson 3 Atoms and Isotopes | The Harnessed Atom (2016)
Lesson 3 Atoms and Isotopes | The Harnessed Atom (2016)
 
Fermi Feud
Fermi FeudFermi Feud
Fermi Feud
 

Recently uploaded

Solution chemistry, Moral and Normal solutions
Solution chemistry, Moral and Normal solutionsSolution chemistry, Moral and Normal solutions
Solution chemistry, Moral and Normal solutionsHajira Mahmood
 
Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
FREE NURSING BUNDLE FOR NURSES.PDF by na
FREE NURSING BUNDLE FOR NURSES.PDF by naFREE NURSING BUNDLE FOR NURSES.PDF by na
FREE NURSING BUNDLE FOR NURSES.PDF by naJASISJULIANOELYNV
 
Pests of Blackgram, greengram, cowpea_Dr.UPR.pdf
Pests of Blackgram, greengram, cowpea_Dr.UPR.pdfPests of Blackgram, greengram, cowpea_Dr.UPR.pdf
Pests of Blackgram, greengram, cowpea_Dr.UPR.pdfPirithiRaju
 
Behavioral Disorder: Schizophrenia & it's Case Study.pdf
Behavioral Disorder: Schizophrenia & it's Case Study.pdfBehavioral Disorder: Schizophrenia & it's Case Study.pdf
Behavioral Disorder: Schizophrenia & it's Case Study.pdfSELF-EXPLANATORY
 
preservation, maintanence and improvement of industrial organism.pptx
preservation, maintanence and improvement of industrial organism.pptxpreservation, maintanence and improvement of industrial organism.pptx
preservation, maintanence and improvement of industrial organism.pptxnoordubaliya2003
 
Best Call Girls In Sector 29 Gurgaon❤️8860477959 EscorTs Service In 24/7 Delh...
Best Call Girls In Sector 29 Gurgaon❤️8860477959 EscorTs Service In 24/7 Delh...Best Call Girls In Sector 29 Gurgaon❤️8860477959 EscorTs Service In 24/7 Delh...
Best Call Girls In Sector 29 Gurgaon❤️8860477959 EscorTs Service In 24/7 Delh...lizamodels9
 
Analytical Profile of Coleus Forskohlii | Forskolin .pptx
Analytical Profile of Coleus Forskohlii | Forskolin .pptxAnalytical Profile of Coleus Forskohlii | Forskolin .pptx
Analytical Profile of Coleus Forskohlii | Forskolin .pptxSwapnil Therkar
 
User Guide: Orion™ Weather Station (Columbia Weather Systems)
User Guide: Orion™ Weather Station (Columbia Weather Systems)User Guide: Orion™ Weather Station (Columbia Weather Systems)
User Guide: Orion™ Weather Station (Columbia Weather Systems)Columbia Weather Systems
 
Sulphur & Phosphrus Cycle PowerPoint Presentation (2) [Autosaved]-3-1.pptx
Sulphur & Phosphrus Cycle PowerPoint Presentation (2) [Autosaved]-3-1.pptxSulphur & Phosphrus Cycle PowerPoint Presentation (2) [Autosaved]-3-1.pptx
Sulphur & Phosphrus Cycle PowerPoint Presentation (2) [Autosaved]-3-1.pptxnoordubaliya2003
 
User Guide: Magellan MX™ Weather Station
User Guide: Magellan MX™ Weather StationUser Guide: Magellan MX™ Weather Station
User Guide: Magellan MX™ Weather StationColumbia Weather Systems
 
Grafana in space: Monitoring Japan's SLIM moon lander in real time
Grafana in space: Monitoring Japan's SLIM moon lander  in real timeGrafana in space: Monitoring Japan's SLIM moon lander  in real time
Grafana in space: Monitoring Japan's SLIM moon lander in real timeSatoshi NAKAHIRA
 
(9818099198) Call Girls In Noida Sector 14 (NOIDA ESCORTS)
(9818099198) Call Girls In Noida Sector 14 (NOIDA ESCORTS)(9818099198) Call Girls In Noida Sector 14 (NOIDA ESCORTS)
(9818099198) Call Girls In Noida Sector 14 (NOIDA ESCORTS)riyaescorts54
 
The dark energy paradox leads to a new structure of spacetime.pptx
The dark energy paradox leads to a new structure of spacetime.pptxThe dark energy paradox leads to a new structure of spacetime.pptx
The dark energy paradox leads to a new structure of spacetime.pptxEran Akiva Sinbar
 
Microphone- characteristics,carbon microphone, dynamic microphone.pptx
Microphone- characteristics,carbon microphone, dynamic microphone.pptxMicrophone- characteristics,carbon microphone, dynamic microphone.pptx
Microphone- characteristics,carbon microphone, dynamic microphone.pptxpriyankatabhane
 
BUMI DAN ANTARIKSA PROJEK IPAS SMK KELAS X.pdf
BUMI DAN ANTARIKSA PROJEK IPAS SMK KELAS X.pdfBUMI DAN ANTARIKSA PROJEK IPAS SMK KELAS X.pdf
BUMI DAN ANTARIKSA PROJEK IPAS SMK KELAS X.pdfWildaNurAmalia2
 
Pests of jatropha_Bionomics_identification_Dr.UPR.pdf
Pests of jatropha_Bionomics_identification_Dr.UPR.pdfPests of jatropha_Bionomics_identification_Dr.UPR.pdf
Pests of jatropha_Bionomics_identification_Dr.UPR.pdfPirithiRaju
 
Bentham & Hooker's Classification. along with the merits and demerits of the ...
Bentham & Hooker's Classification. along with the merits and demerits of the ...Bentham & Hooker's Classification. along with the merits and demerits of the ...
Bentham & Hooker's Classification. along with the merits and demerits of the ...Nistarini College, Purulia (W.B) India
 
Microteaching on terms used in filtration .Pharmaceutical Engineering
Microteaching on terms used in filtration .Pharmaceutical EngineeringMicroteaching on terms used in filtration .Pharmaceutical Engineering
Microteaching on terms used in filtration .Pharmaceutical EngineeringPrajakta Shinde
 
STOPPED FLOW METHOD & APPLICATION MURUGAVENI B.pptx
STOPPED FLOW METHOD & APPLICATION MURUGAVENI B.pptxSTOPPED FLOW METHOD & APPLICATION MURUGAVENI B.pptx
STOPPED FLOW METHOD & APPLICATION MURUGAVENI B.pptxMurugaveni B
 

Recently uploaded (20)

Solution chemistry, Moral and Normal solutions
Solution chemistry, Moral and Normal solutionsSolution chemistry, Moral and Normal solutions
Solution chemistry, Moral and Normal solutions
 
Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Munirka Delhi 💯Call Us 🔝8264348440🔝
 
FREE NURSING BUNDLE FOR NURSES.PDF by na
FREE NURSING BUNDLE FOR NURSES.PDF by naFREE NURSING BUNDLE FOR NURSES.PDF by na
FREE NURSING BUNDLE FOR NURSES.PDF by na
 
Pests of Blackgram, greengram, cowpea_Dr.UPR.pdf
Pests of Blackgram, greengram, cowpea_Dr.UPR.pdfPests of Blackgram, greengram, cowpea_Dr.UPR.pdf
Pests of Blackgram, greengram, cowpea_Dr.UPR.pdf
 
Behavioral Disorder: Schizophrenia & it's Case Study.pdf
Behavioral Disorder: Schizophrenia & it's Case Study.pdfBehavioral Disorder: Schizophrenia & it's Case Study.pdf
Behavioral Disorder: Schizophrenia & it's Case Study.pdf
 
preservation, maintanence and improvement of industrial organism.pptx
preservation, maintanence and improvement of industrial organism.pptxpreservation, maintanence and improvement of industrial organism.pptx
preservation, maintanence and improvement of industrial organism.pptx
 
Best Call Girls In Sector 29 Gurgaon❤️8860477959 EscorTs Service In 24/7 Delh...
Best Call Girls In Sector 29 Gurgaon❤️8860477959 EscorTs Service In 24/7 Delh...Best Call Girls In Sector 29 Gurgaon❤️8860477959 EscorTs Service In 24/7 Delh...
Best Call Girls In Sector 29 Gurgaon❤️8860477959 EscorTs Service In 24/7 Delh...
 
Analytical Profile of Coleus Forskohlii | Forskolin .pptx
Analytical Profile of Coleus Forskohlii | Forskolin .pptxAnalytical Profile of Coleus Forskohlii | Forskolin .pptx
Analytical Profile of Coleus Forskohlii | Forskolin .pptx
 
User Guide: Orion™ Weather Station (Columbia Weather Systems)
User Guide: Orion™ Weather Station (Columbia Weather Systems)User Guide: Orion™ Weather Station (Columbia Weather Systems)
User Guide: Orion™ Weather Station (Columbia Weather Systems)
 
Sulphur & Phosphrus Cycle PowerPoint Presentation (2) [Autosaved]-3-1.pptx
Sulphur & Phosphrus Cycle PowerPoint Presentation (2) [Autosaved]-3-1.pptxSulphur & Phosphrus Cycle PowerPoint Presentation (2) [Autosaved]-3-1.pptx
Sulphur & Phosphrus Cycle PowerPoint Presentation (2) [Autosaved]-3-1.pptx
 
User Guide: Magellan MX™ Weather Station
User Guide: Magellan MX™ Weather StationUser Guide: Magellan MX™ Weather Station
User Guide: Magellan MX™ Weather Station
 
Grafana in space: Monitoring Japan's SLIM moon lander in real time
Grafana in space: Monitoring Japan's SLIM moon lander  in real timeGrafana in space: Monitoring Japan's SLIM moon lander  in real time
Grafana in space: Monitoring Japan's SLIM moon lander in real time
 
(9818099198) Call Girls In Noida Sector 14 (NOIDA ESCORTS)
(9818099198) Call Girls In Noida Sector 14 (NOIDA ESCORTS)(9818099198) Call Girls In Noida Sector 14 (NOIDA ESCORTS)
(9818099198) Call Girls In Noida Sector 14 (NOIDA ESCORTS)
 
The dark energy paradox leads to a new structure of spacetime.pptx
The dark energy paradox leads to a new structure of spacetime.pptxThe dark energy paradox leads to a new structure of spacetime.pptx
The dark energy paradox leads to a new structure of spacetime.pptx
 
Microphone- characteristics,carbon microphone, dynamic microphone.pptx
Microphone- characteristics,carbon microphone, dynamic microphone.pptxMicrophone- characteristics,carbon microphone, dynamic microphone.pptx
Microphone- characteristics,carbon microphone, dynamic microphone.pptx
 
BUMI DAN ANTARIKSA PROJEK IPAS SMK KELAS X.pdf
BUMI DAN ANTARIKSA PROJEK IPAS SMK KELAS X.pdfBUMI DAN ANTARIKSA PROJEK IPAS SMK KELAS X.pdf
BUMI DAN ANTARIKSA PROJEK IPAS SMK KELAS X.pdf
 
Pests of jatropha_Bionomics_identification_Dr.UPR.pdf
Pests of jatropha_Bionomics_identification_Dr.UPR.pdfPests of jatropha_Bionomics_identification_Dr.UPR.pdf
Pests of jatropha_Bionomics_identification_Dr.UPR.pdf
 
Bentham & Hooker's Classification. along with the merits and demerits of the ...
Bentham & Hooker's Classification. along with the merits and demerits of the ...Bentham & Hooker's Classification. along with the merits and demerits of the ...
Bentham & Hooker's Classification. along with the merits and demerits of the ...
 
Microteaching on terms used in filtration .Pharmaceutical Engineering
Microteaching on terms used in filtration .Pharmaceutical EngineeringMicroteaching on terms used in filtration .Pharmaceutical Engineering
Microteaching on terms used in filtration .Pharmaceutical Engineering
 
STOPPED FLOW METHOD & APPLICATION MURUGAVENI B.pptx
STOPPED FLOW METHOD & APPLICATION MURUGAVENI B.pptxSTOPPED FLOW METHOD & APPLICATION MURUGAVENI B.pptx
STOPPED FLOW METHOD & APPLICATION MURUGAVENI B.pptx
 

Non equilibrium Molecular Simulations of Polymers under Flow Saving Energy through Process Optimization

  • 1. Non-equilibrium Molecular Simulations of Polymers under Flow: Saving Energy through Process Optimization Jamil Gafur, Lintao Bu, Michael Crowley Renewable Resources and Enabling Science Center at the National Renewable Energy Lab (NREL) NREL is a national laboratory of the U.S. Department of Energy Office of Energy Efficiency and Renewable Energy operated by the Alliance for Sustainable Energy, LLC
  • 2. Background • We are studying the process of plastic extrusion to minimize the polymer build up around the extrusion pipe • When build up starts to occur the overall structure and stability of the product decreases significantly https://en.wikipedia.org/wiki/Plastic_extrusion
  • 3. Background • We are studying the process of plastic extrusion to minimize the polymer build up around the extrusion pipe • When build up starts to occur the overall structure and stability of the product decreases significantly https://en.wikipedia.org/wiki/Plastic_extrusion
  • 4. Background • We are studying the process of plastic extrusion to minimize the polymer build up around the extrusion pipe • When build up starts to occur the overall structure and stability of the product decreases significantly https://en.wikipedia.org/wiki/Plastic_extrusion Feed pipe Flow velocity (Normal) Laminar flow (Slow)
  • 5. Background • We are studying the process of plastic extrusion to minimize the polymer build up around the extrusion pipe • When build up starts to occur the overall structure and stability of the product decreases significantly https://en.wikipedia.org/wiki/Plastic_extrusion Molecular Weight Distribution
  • 6. Background • We are studying the process of plastic extrusion to minimize the polymer build up around the extrusion pipe • When build up starts to occur the overall structure and stability of the product decreases significantly https://en.wikipedia.org/wiki/Plastic_extrusion Molecular Weight Distribution
  • 7. Impact • This project combines DOE High Performance Computing capabilities with established and emerging molecular simulation techniques to address industrially relevant issues of practical interest to US Manufacturing competitiveness. • Our work this summer is focused on setting up the codebase for future development, and optimizing the code to allow for optimal use of allocated nodes
  • 8. Initial work • Given a zip file of Fortran 90 codes and an associated simulation script; this zip file was sent the main way of distributing the code • There was no documentation on how to run the simulations, or how the code worked • We have existing codes that simulate the extrusion process; however, it does not run efficiently (some runs taking more than 6 months to run) • This code has not been optimized in any way, nor has the codebase been under any form of RSE practices • CI • Unit testing • Documentation
  • 9. First steps • Set up version control on GitHub • Set up timelines, milestones and issues with short term, and long-term goals in mind • Initiated some form of unit testing. • Currently in the process of having better unit tests • Ran the simulation, saved the output files and compared future runs to this "golden" set of output files • "I have the same level of confidence that this code works now, as when I got it.” • “I have no way of knowing if there are any errors associated with the algorithms" - Jamil Gafur https://github.com/crowleymf/hpc4eidow
  • 10. File Structure and Initial profiling • Initial results showed that the code mostly focused on computation • There was no MPI, or open MP added to the codebase, thus everything was running on one core • The rest of the time was spent on I/O • Takes about 11 min for the "test case" to run
  • 11. Optimization Using the intel profiler (VTune) we identified parts of the code that can be optimized, our results are shown below
  • 13. Next step, Optimization of code • Most of the issues we found were due to memory allocation, something that can't easily be fixed
  • 14. Next step, Optimization of code • Most of the issues we found were due to memory allocation, something that can't easily be fixed BUT WHO SAID LIFE WAS EASY?
  • 15. Next step, Optimization of code • Most of the issues we found were due to memory allocation, something that can't easily be fixed BUT WHO SAID LIFE WAS EASY?
  • 16. Next step, Optimization of code • Most of the issues we found were due to memory allocation, something that can't easily be fixed BUT WHO SAID LIFE WAS EASY? ~20%
  • 17. 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 Index Bits Integer (dmask)
  • 18. Integer (dmask) Use the d value as binary operators for our integer 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 Integer (16) Index Bits 0 0 0 1 0 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 Index Bits
  • 19. Use the d value as binary operators for our integer 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 Integer (16) Index Bits 0 0 0 1 0 0 1 0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 1 0 0 1 0 1 0 1 0 0 0 0 0 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 Index Bits 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 iand Integer (dmask)
  • 20. • We have condensed an if-statement (>20 clock cycles) into 2 clock cycles. • iand • ishft 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 Left 4 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
  • 21.
  • 22. Original Code we were given Updated Code we updated Optimized Using -0fast flag when compiling Non-optimized !^ Output Write output logs every 10 iterations (default of original code) No-Output Writes output at last iteration
  • 23. Original Code we were given Updated Code we updated Optimized Using -0fast flag when compiling Non-optimized !^ Output Write output logs every 10 iterations (default of original code) No-Output Writes output at last iteration
  • 24. Conclusion • It is important to use good programming practices and algorithm design before implementing parallelization • Profiling a code gives you a good idea on where you can update code to get the most speed up • Version control, V&V, documentation
  • 25. Moving Forward • Moving forward our group would like to implement MPI to allow for multi-node support. • Using MPI we believe we can offload the I/O to a separate process and gain an additional 11% speedup
  • 26. Thank you for your time Special thanks to: • Mentors/Advisors: • Dr. Lintao Bu • Dr. Michael Crowley • Dr. Suely Oliveira • Dr. Gretta Kellogg • Energy Efficiency and Renewable Energy (EERE) Advanced Manufacturing Office (AMO) • Oak Ridge Institute for Science and Education (ORISE) • University of Iowa Computer Science Department About me: https://jamilggafur.gitlab.io/ jamil-gafur@uiowa.edu