Pub Date : 2024-12-30DOI: 10.1016/j.cpc.2024.109477
Alberto Bocchinfuso, David M. Rogers, Caio Alves, Jorge Ramirez, Dilipkumar N. Asthagiri, Thomas L. Beck, Juan M. Restrepo
We describe and compare outcomes of various Multi-Level Monte Carlo (MLMC) method variants, motivated by the potential of improved computational efficiency over rejection based Monte Carlo, which scales poorly with problem dimension. With an eye toward its application to computational chemical physics, we test MLMC's ability to sample trajectories on two problems — a familiar double-well potential, with known stationary distributions, and a Lennard-Jones solid potential (a Galton Board). By sampling Brownian motion trajectories, we are able to compute expectations of observable averages. These multi-basin potential energy problems capture the essence of the challenges with using MLMC, namely, maintaining correspondence of sample paths as time-resolution is varied. Addressing this challenge properly can lead to MLMC significantly outperforming standard Monte Carlo path sampling. We describe the essence of this problem and suggest strategies that circumvent diverging multilevel sample paths for an important class of problems. In the tests we also compare the computational cost of several, “adaptive,” variants of MLMC. Our results demonstrate that MLMC overcomes the collision, time scale limitation of the more familiar Brownian path MC samplers, and our implementation provides tunable error thresholds, making MLMC a promising candidate for application to larger and more complex molecular systems.
{"title":"Multi-level Monte Carlo methods in chemical applications with Lennard-Jones potentials and other landscapes with isolated singularities","authors":"Alberto Bocchinfuso, David M. Rogers, Caio Alves, Jorge Ramirez, Dilipkumar N. Asthagiri, Thomas L. Beck, Juan M. Restrepo","doi":"10.1016/j.cpc.2024.109477","DOIUrl":"10.1016/j.cpc.2024.109477","url":null,"abstract":"<div><div>We describe and compare outcomes of various Multi-Level Monte Carlo (MLMC) method variants, motivated by the potential of improved computational efficiency over rejection based Monte Carlo, which scales poorly with problem dimension. With an eye toward its application to computational chemical physics, we test MLMC's ability to sample trajectories on two problems — a familiar double-well potential, with known stationary distributions, and a Lennard-Jones solid potential (a Galton Board). By sampling Brownian motion trajectories, we are able to compute expectations of observable averages. These multi-basin potential energy problems capture the essence of the challenges with using MLMC, namely, maintaining correspondence of sample paths as time-resolution is varied. Addressing this challenge properly can lead to MLMC significantly outperforming standard Monte Carlo path sampling. We describe the essence of this problem and suggest strategies that circumvent diverging multilevel sample paths for an important class of problems. In the tests we also compare the computational cost of several, “adaptive,” variants of MLMC. Our results demonstrate that MLMC overcomes the collision, time scale limitation of the more familiar Brownian path MC samplers, and our implementation provides tunable error thresholds, making MLMC a promising candidate for application to larger and more complex molecular systems.</div></div>","PeriodicalId":285,"journal":{"name":"Computer Physics Communications","volume":"309 ","pages":"Article 109477"},"PeriodicalIF":7.2,"publicationDate":"2024-12-30","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"143127917","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":2,"RegionCategory":"物理与天体物理","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"OA","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
Pub Date : 2024-12-30DOI: 10.1016/j.cpc.2024.109491
Max Aehle , Mihály Novák , Vassil Vassilev , Nicolas R. Gauger , Lukas Heinrich , Michael Kagan , David Lange
Among the well-known methods to approximate derivatives of expectancies computed by Monte-Carlo simulations, averages of pathwise derivatives are often the easiest one to apply. Computing them via algorithmic differentiation typically does not require major manual analysis and rewriting of the code, even for very complex programs like simulations of particle-detector interactions in high-energy physics. However, the pathwise derivative estimator can be biased if there are discontinuities in the program, which may diminish its value for applications.
This work integrates algorithmic differentiation into the electromagnetic shower simulation code HepEmShow based on G4HepEm, allowing us to study how well pathwise derivatives approximate derivatives of energy depositions in a sampling calorimeter with respect to parameters of the beam and geometry. We found that when multiple scattering is disabled in the simulation, means of pathwise derivatives converge quickly to their expected values, and these are close to the actual derivatives of the energy deposition. Additionally, we demonstrate the applicability of this novel gradient estimator for stochastic gradient-based optimization in a model example.
{"title":"Optimization using pathwise algorithmic derivatives of electromagnetic shower simulations","authors":"Max Aehle , Mihály Novák , Vassil Vassilev , Nicolas R. Gauger , Lukas Heinrich , Michael Kagan , David Lange","doi":"10.1016/j.cpc.2024.109491","DOIUrl":"10.1016/j.cpc.2024.109491","url":null,"abstract":"<div><div>Among the well-known methods to approximate derivatives of expectancies computed by Monte-Carlo simulations, averages of pathwise derivatives are often the easiest one to apply. Computing them via algorithmic differentiation typically does not require major manual analysis and rewriting of the code, even for very complex programs like simulations of particle-detector interactions in high-energy physics. However, the pathwise derivative estimator can be biased if there are discontinuities in the program, which may diminish its value for applications.</div><div>This work integrates algorithmic differentiation into the electromagnetic shower simulation code HepEmShow based on G4HepEm, allowing us to study how well pathwise derivatives approximate derivatives of energy depositions in a sampling calorimeter with respect to parameters of the beam and geometry. We found that when multiple scattering is disabled in the simulation, means of pathwise derivatives converge quickly to their expected values, and these are close to the actual derivatives of the energy deposition. Additionally, we demonstrate the applicability of this novel gradient estimator for stochastic gradient-based optimization in a model example.</div></div>","PeriodicalId":285,"journal":{"name":"Computer Physics Communications","volume":"309 ","pages":"Article 109491"},"PeriodicalIF":7.2,"publicationDate":"2024-12-30","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"143093126","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":2,"RegionCategory":"物理与天体物理","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"OA","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
Pub Date : 2024-12-27DOI: 10.1016/j.cpc.2024.109479
Pere A. Martorell , Santiago Badia
Approximating partial differential equations for extensive industrial and scientific applications requires leveraging the power of modern high-performance computing. In large-scale parallel computations, the geometrical discretisation rapidly becomes a bottleneck in the simulation pipeline. Unstructured mesh generation is hardly automatic, and meshing algorithms cannot efficiently exploit distributed-memory computers. Besides, partitioning of unstructured meshes relies on graph partitioning strategies, which scale poorly. As a result, the use of dynamic load balancing for locally refined meshes becomes prohibitive. Adaptive Cartesian meshes are far more advantageous, providing cheap and scalable mesh generation, partitioning, and balancing compared to unstructured meshes. However, Cartesian meshes are not suitable for complex geometries when using standard discretisation techniques. Unfitted finite element methods are a promising solution to the abovementioned problems. These numerical schemes rely on Cartesian meshes and can handle complex geometries. Nevertheless, their application is usually constrained to implicit (level set) geometrical representations. The extension to general geometries, e.g., provided by an STL surface mesh, requires advanced intersection algorithms. This work presents an efficient parallel implementation of all the geometric tools required, e.g., for unfitted finite element methods (in a broad sense), for explicit boundary representations. Such geometries can readily be generated using standard computer-aided design tools. The proposed geometrical workflow utilises a multilevel approach to overlapping computations, effectively eliminating bottlenecks in large-scale computations. The numerical results demonstrate perfect weak scalability over 13,000 processors and one billion cells. All these algorithms are implemented in the open-source STLCutters.jl library, written in the Julia programming language. The library is designed to be used in conjunction with the Gridap.jl library provides a high-level interface to the finite element method.
{"title":"STLCutters.jl: A scalable geometrical framework library for unfitted finite element discretisations","authors":"Pere A. Martorell , Santiago Badia","doi":"10.1016/j.cpc.2024.109479","DOIUrl":"10.1016/j.cpc.2024.109479","url":null,"abstract":"<div><div>Approximating partial differential equations for extensive industrial and scientific applications requires leveraging the power of modern high-performance computing. In large-scale parallel computations, the geometrical discretisation rapidly becomes a bottleneck in the simulation pipeline. Unstructured mesh generation is hardly automatic, and meshing algorithms cannot efficiently exploit distributed-memory computers. Besides, partitioning of unstructured meshes relies on graph partitioning strategies, which scale poorly. As a result, the use of dynamic load balancing for locally refined meshes becomes prohibitive. Adaptive Cartesian meshes are far more advantageous, providing cheap and scalable mesh generation, partitioning, and balancing compared to unstructured meshes. However, Cartesian meshes are not suitable for complex geometries when using standard discretisation techniques. Unfitted finite element methods are a promising solution to the abovementioned problems. These numerical schemes rely on Cartesian meshes and can handle complex geometries. Nevertheless, their application is usually constrained to implicit (level set) geometrical representations. The extension to general geometries, e.g., provided by an STL surface mesh, requires advanced intersection algorithms. This work presents an efficient parallel implementation of all the geometric tools required, e.g., for unfitted finite element methods (in a broad sense), for explicit boundary representations. Such geometries can readily be generated using standard computer-aided design tools. The proposed geometrical workflow utilises a multilevel approach to overlapping computations, effectively eliminating bottlenecks in large-scale computations. The numerical results demonstrate perfect weak scalability over 13,000 processors and one billion cells. All these algorithms are implemented in the open-source <span>STLCutters.jl</span> library, written in the Julia programming language. The library is designed to be used in conjunction with the <span>Gridap.jl</span> library provides a high-level interface to the finite element method.</div></div>","PeriodicalId":285,"journal":{"name":"Computer Physics Communications","volume":"309 ","pages":"Article 109479"},"PeriodicalIF":7.2,"publicationDate":"2024-12-27","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"143127926","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":2,"RegionCategory":"物理与天体物理","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
Pub Date : 2024-12-24DOI: 10.1016/j.cpc.2024.109478
Kevin Schäfers , Jacob Finkenrath , Michael Günther , Francesco Knechtli
We propose a new framework of Hessian-free force-gradient integrators that do not require the analytical expression of the force-gradient term based on the Hessian of the potential. Due to that the new class of decomposition algorithms for separable Hamiltonian systems with quadratic kinetic energy may be particularly useful when applied to Hamiltonian systems where an evaluation of the Hessian is significantly more expensive than an evaluation of its gradient, e.g. in molecular dynamics simulations of classical systems. Numerical experiments of an N-body problem, as well as applications to the molecular dynamics step in the Hybrid Monte Carlo (HMC) algorithm for lattice simulations of the Schwinger model and Quantum Chromodynamics (QCD) verify these expectations.
{"title":"Hessian-free force-gradient integrators","authors":"Kevin Schäfers , Jacob Finkenrath , Michael Günther , Francesco Knechtli","doi":"10.1016/j.cpc.2024.109478","DOIUrl":"10.1016/j.cpc.2024.109478","url":null,"abstract":"<div><div>We propose a new framework of Hessian-free force-gradient integrators that do not require the analytical expression of the force-gradient term based on the Hessian of the potential. Due to that the new class of decomposition algorithms for separable Hamiltonian systems with quadratic kinetic energy may be particularly useful when applied to Hamiltonian systems where an evaluation of the Hessian is significantly more expensive than an evaluation of its gradient, e.g. in molecular dynamics simulations of classical systems. Numerical experiments of an N-body problem, as well as applications to the molecular dynamics step in the Hybrid Monte Carlo (HMC) algorithm for lattice simulations of the Schwinger model and Quantum Chromodynamics (QCD) verify these expectations.</div></div>","PeriodicalId":285,"journal":{"name":"Computer Physics Communications","volume":"309 ","pages":"Article 109478"},"PeriodicalIF":7.2,"publicationDate":"2024-12-24","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"143127915","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":2,"RegionCategory":"物理与天体物理","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"OA","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
<div><div>Structural mechanics is pivotal in comprehending how structures respond to external forces and imposed displacements. Typically, the analysis of structures is performed numerically using the direct stiffness method, which is an implementation of the finite element method. This method is commonly associated with the numerical solution of large systems of equations. However, the underlying theory can also be conveniently used to perform the analysis of structures either symbolically or in a hybrid symbolic-numerical fashion. This approach is useful to mitigate the computational burden as the obtained partial or full symbolic solution can be simplified and used to generate lean code for efficient simulations. Nonetheless, the symbolic direct stiffness method is also useful for model reduction purposes, as it allows the derivation of small-scale models that can be used for diminishing simulation time. Despite the mentioned advantages, symbolic computation carries intrinsically complex operations. In particular, the symbolic solution of large linear systems of equations is hard to compute, and it may not always be available due to software capabilities. This paper introduces a toolbox named <span>TrussMe-Fem</span>, whose implementation is based on the direct stiffness method. <span>TrussMe-Fem</span> leverages <span>Maple</span>®'s symbolic computation and <span>Matlab</span>®'s numerical capabilities for symbolic and hybrid symbolic-numerical analyses and solutions of structures. Efficient code generation is also possible by exploiting the simplification of the problem's expressions. The challenges posed by symbolic computation on the solution of large linear systems are addressed by introducing novel routines for the symbolic matrix factorization with the hierarchical representation of large expressions. For this purpose, the <span>TrussMe-Fem</span> toolbox optionally uses the <span>Lem</span> and <span>Last Maple</span>® packages, which are also available as open-source software.</div></div><div><h3>Program summary</h3><div><em>Program Title:</em> <span>TrussMe-Fem</span></div><div><em>CPC Library link to program files:</em> <span><span>https://doi.org/10.17632/m59fyw5hs4.1</span><svg><path></path></svg></span></div><div><em>Developer's repository link:</em> <span><span>https://github.com/StoccoDavide/TrussMe-FEM</span><svg><path></path></svg></span> – Optional dependencies: <span>Lem</span> <span><span>https://github.com/StoccoDavide/LEM</span><svg><path></path></svg></span>, <span>Last</span> <span><span>https://github.com/StoccoDavide/LAST</span><svg><path></path></svg></span></div><div><em>Licensing provisions:</em> BSD 3-clause.</div><div><em>Programming language:</em> <span>Maple</span>®, <span>Matlab</span>®.</div><div><em>Supplementary material:</em> Usage examples for the <span>TrussMe-Fem</span> toolbox, <span>Lem</span> and <span>Last Maple</span>® packages.</div><div><em>Nature of problem:</em> Structural mechanics is a bran
{"title":"TrussMe-Fem: A toolbox for symbolic-numerical analysis and solution of structures","authors":"Davide Stocco , Matteo Larcher , Matteo Tomasi, Enrico Bertolazzi","doi":"10.1016/j.cpc.2024.109476","DOIUrl":"10.1016/j.cpc.2024.109476","url":null,"abstract":"<div><div>Structural mechanics is pivotal in comprehending how structures respond to external forces and imposed displacements. Typically, the analysis of structures is performed numerically using the direct stiffness method, which is an implementation of the finite element method. This method is commonly associated with the numerical solution of large systems of equations. However, the underlying theory can also be conveniently used to perform the analysis of structures either symbolically or in a hybrid symbolic-numerical fashion. This approach is useful to mitigate the computational burden as the obtained partial or full symbolic solution can be simplified and used to generate lean code for efficient simulations. Nonetheless, the symbolic direct stiffness method is also useful for model reduction purposes, as it allows the derivation of small-scale models that can be used for diminishing simulation time. Despite the mentioned advantages, symbolic computation carries intrinsically complex operations. In particular, the symbolic solution of large linear systems of equations is hard to compute, and it may not always be available due to software capabilities. This paper introduces a toolbox named <span>TrussMe-Fem</span>, whose implementation is based on the direct stiffness method. <span>TrussMe-Fem</span> leverages <span>Maple</span>®'s symbolic computation and <span>Matlab</span>®'s numerical capabilities for symbolic and hybrid symbolic-numerical analyses and solutions of structures. Efficient code generation is also possible by exploiting the simplification of the problem's expressions. The challenges posed by symbolic computation on the solution of large linear systems are addressed by introducing novel routines for the symbolic matrix factorization with the hierarchical representation of large expressions. For this purpose, the <span>TrussMe-Fem</span> toolbox optionally uses the <span>Lem</span> and <span>Last Maple</span>® packages, which are also available as open-source software.</div></div><div><h3>Program summary</h3><div><em>Program Title:</em> <span>TrussMe-Fem</span></div><div><em>CPC Library link to program files:</em> <span><span>https://doi.org/10.17632/m59fyw5hs4.1</span><svg><path></path></svg></span></div><div><em>Developer's repository link:</em> <span><span>https://github.com/StoccoDavide/TrussMe-FEM</span><svg><path></path></svg></span> – Optional dependencies: <span>Lem</span> <span><span>https://github.com/StoccoDavide/LEM</span><svg><path></path></svg></span>, <span>Last</span> <span><span>https://github.com/StoccoDavide/LAST</span><svg><path></path></svg></span></div><div><em>Licensing provisions:</em> BSD 3-clause.</div><div><em>Programming language:</em> <span>Maple</span>®, <span>Matlab</span>®.</div><div><em>Supplementary material:</em> Usage examples for the <span>TrussMe-Fem</span> toolbox, <span>Lem</span> and <span>Last Maple</span>® packages.</div><div><em>Nature of problem:</em> Structural mechanics is a bran","PeriodicalId":285,"journal":{"name":"Computer Physics Communications","volume":"309 ","pages":"Article 109476"},"PeriodicalIF":7.2,"publicationDate":"2024-12-24","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"143127850","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":2,"RegionCategory":"物理与天体物理","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"OA","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
<div><div>A novel Eulerian-Lagrangian MPI parallelized solver is developed to resolve the dynamics of ellipsoidal fibers in the OpenFOAM platform. Due to the nonspherical shape of the ellipsoidal fibers and the dependence of the drag force on the orientation of the fiber, the solver solves the full conservation of linear and angular momentum equations, in addition to the time evolution equation for Euler's parameters, quaternions. To this end, a new parcel type is introduced to represent ellipsoidal fibers with several new properties, including Euler's parameters, angular velocity, and torque class. Finally, new member functions are defined to solve angular momentum and Euler's parameters time evolution equations. The solver is the first publicly available, robust and reliable computational framework for the numerical analysis of ellipsoidal fibers motion. It promotes the capability of the standard Lagrangian OpenFOAM solvers and libraries to capture the orientation and rotational dynamics of nonspherical particles. As validation cases, the solver was applied to four benchmarks: three-dimensional rotation of an ellipsoid in linear shear flow, two-dimensional rotation of a magnetic ellipsoid in linear shear flow subjected to a uniform magnetic field, motion of an ellipsoid in pipe flow, and ellipsoids deposition in three-dimensional bifurcation flow. Comparison of the results with analytical solutions, experimental data and in-silico results indicates close agreements and high accuracy of the developed numerical model for single- and multi-physics test cases.</div></div><div><h3>Program summary</h3><div><em>Program title:</em> EllipsoidalFiberFoam</div><div><em>CPC Library link to program files:</em> <span><span>https://doi.org/10.17632/nf35zjvmr2.1</span><svg><path></path></svg></span></div><div><em>Licensing provisions:</em> GNU General Public License Version 3</div><div><em>Programming language:</em> C++</div><div><em>Nature of problem:</em> The developed Eulerian-Lagrangian solver introduces the Euler's parameters, angular velocity and hydrodynamic and magnetic torques of ellipsoidal fibers and it solves the equations of conservation of angular momentum and Euler's parameters time evolution to describe the fiber orientation fully. The orientation-dependent drag force and the fiber trajectory are calculated afterward by solving the equations of conservation of linear momentum.</div><div><em>Solution method:</em> Fluid phase velocity and pressure are obtained through the PIMPLE algorithm. For the particulate phase, a new parcel type owning Euler's parameters and angular velocity accompanied by new classes for hydrodynamic and magnetic torques and orientation-based drag force represents an ellipsoidal fiber, and the Lagrangian cloud of the parcel is evolved through the integration of the equations of translational and rotational motion.</div><div><em>Additional comments, including restrictions and unusual features:</em> The current version of the
{"title":"EllipsoidalFiberFoam, a novel Eulerian-Lagrangian solver for resolving translational and rotational motion dynamics of ellipsoidal fibers","authors":"Kazem Reza-Asl, Ebrahim Goshtasbi Rad, Omid Abouali","doi":"10.1016/j.cpc.2024.109481","DOIUrl":"10.1016/j.cpc.2024.109481","url":null,"abstract":"<div><div>A novel Eulerian-Lagrangian MPI parallelized solver is developed to resolve the dynamics of ellipsoidal fibers in the OpenFOAM platform. Due to the nonspherical shape of the ellipsoidal fibers and the dependence of the drag force on the orientation of the fiber, the solver solves the full conservation of linear and angular momentum equations, in addition to the time evolution equation for Euler's parameters, quaternions. To this end, a new parcel type is introduced to represent ellipsoidal fibers with several new properties, including Euler's parameters, angular velocity, and torque class. Finally, new member functions are defined to solve angular momentum and Euler's parameters time evolution equations. The solver is the first publicly available, robust and reliable computational framework for the numerical analysis of ellipsoidal fibers motion. It promotes the capability of the standard Lagrangian OpenFOAM solvers and libraries to capture the orientation and rotational dynamics of nonspherical particles. As validation cases, the solver was applied to four benchmarks: three-dimensional rotation of an ellipsoid in linear shear flow, two-dimensional rotation of a magnetic ellipsoid in linear shear flow subjected to a uniform magnetic field, motion of an ellipsoid in pipe flow, and ellipsoids deposition in three-dimensional bifurcation flow. Comparison of the results with analytical solutions, experimental data and in-silico results indicates close agreements and high accuracy of the developed numerical model for single- and multi-physics test cases.</div></div><div><h3>Program summary</h3><div><em>Program title:</em> EllipsoidalFiberFoam</div><div><em>CPC Library link to program files:</em> <span><span>https://doi.org/10.17632/nf35zjvmr2.1</span><svg><path></path></svg></span></div><div><em>Licensing provisions:</em> GNU General Public License Version 3</div><div><em>Programming language:</em> C++</div><div><em>Nature of problem:</em> The developed Eulerian-Lagrangian solver introduces the Euler's parameters, angular velocity and hydrodynamic and magnetic torques of ellipsoidal fibers and it solves the equations of conservation of angular momentum and Euler's parameters time evolution to describe the fiber orientation fully. The orientation-dependent drag force and the fiber trajectory are calculated afterward by solving the equations of conservation of linear momentum.</div><div><em>Solution method:</em> Fluid phase velocity and pressure are obtained through the PIMPLE algorithm. For the particulate phase, a new parcel type owning Euler's parameters and angular velocity accompanied by new classes for hydrodynamic and magnetic torques and orientation-based drag force represents an ellipsoidal fiber, and the Lagrangian cloud of the parcel is evolved through the integration of the equations of translational and rotational motion.</div><div><em>Additional comments, including restrictions and unusual features:</em> The current version of the","PeriodicalId":285,"journal":{"name":"Computer Physics Communications","volume":"309 ","pages":"Article 109481"},"PeriodicalIF":7.2,"publicationDate":"2024-12-23","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"143127920","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":2,"RegionCategory":"物理与天体物理","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
Pub Date : 2024-12-19DOI: 10.1016/j.cpc.2024.109470
Liang Xu , Ziyan Liu , Yiwei Feng , Tiegang Liu
Machine learning has the potential to provide a non-traditional and feasible approach for solving Riemann problems to model the coupling effects of multi-material flows. However, most recent research on predicting Riemann solutions with neural networks is limited to addressing single-material flows and featured as the supervised learning, or is limited to solving specific problems and difficult to apply to a wide range of initial conditions. In this work, we explore physics-constrained neural networks, termed PCNN-RS, as multi-material Riemann solvers without any labeled data. Based on the frame of a general neural network, physics-constrained functions that conform to the shock/rarefaction relationships between initial states and interfacial states are constructed after the output layer, transforming the unlabeled output into a theoretically zero-valued functional form. This allows training learning models with standard loss functions solely using input data. The interfacial pressure of multi-material Riemann problem is predicted using the surrogate model, and other interfacial states can be directly derived through simple calculations. In addition, the basic principle of scaling of initial conditions and Riemann solutions with general equations of state is established theoretically. Based on this property, a transformation of input and output data is proposed to enhance the wide applicability of the Riemann-solver surrogate model. Furthermore, an optimization of samples is presented to reduce the training dataset and shorten the training time. The PCNN-RS is able to make accurate predictions, even when utilizing a compact neural network architecture with fewer neurons, and it is easily applied to the ghost-fluid-based sharp interface methods. It possesses the ability to simulate various interface evolutions for the interaction between two materials.
{"title":"Unsupervised neural-network solvers for multi-material Riemann problems","authors":"Liang Xu , Ziyan Liu , Yiwei Feng , Tiegang Liu","doi":"10.1016/j.cpc.2024.109470","DOIUrl":"10.1016/j.cpc.2024.109470","url":null,"abstract":"<div><div>Machine learning has the potential to provide a non-traditional and feasible approach for solving Riemann problems to model the coupling effects of multi-material flows. However, most recent research on predicting Riemann solutions with neural networks is limited to addressing single-material flows and featured as the supervised learning, or is limited to solving specific problems and difficult to apply to a wide range of initial conditions. In this work, we explore physics-constrained neural networks, termed PCNN-RS, as multi-material Riemann solvers without any labeled data. Based on the frame of a general neural network, physics-constrained functions that conform to the shock/rarefaction relationships between initial states and interfacial states are constructed after the output layer, transforming the unlabeled output into a theoretically zero-valued functional form. This allows training learning models with standard loss functions solely using input data. The interfacial pressure of multi-material Riemann problem is predicted using the surrogate model, and other interfacial states can be directly derived through simple calculations. In addition, the basic principle of scaling of initial conditions and Riemann solutions with general equations of state is established theoretically. Based on this property, a transformation of input and output data is proposed to enhance the wide applicability of the Riemann-solver surrogate model. Furthermore, an optimization of samples is presented to reduce the training dataset and shorten the training time. The PCNN-RS is able to make accurate predictions, even when utilizing a compact neural network architecture with fewer neurons, and it is easily applied to the ghost-fluid-based sharp interface methods. It possesses the ability to simulate various interface evolutions for the interaction between two materials.</div></div>","PeriodicalId":285,"journal":{"name":"Computer Physics Communications","volume":"308 ","pages":"Article 109470"},"PeriodicalIF":7.2,"publicationDate":"2024-12-19","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"143162811","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":2,"RegionCategory":"物理与天体物理","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
Pub Date : 2024-12-19DOI: 10.1016/j.cpc.2024.109475
Matthias Niethammer, Muhammad Hassan Asghar, Dieter Bothe, Tomislav Maric
Since viscoelastic two-phase flows arise in various industrial and natural processes, developing accurate and efficient software for their detailed numerical simulation is a highly relevant and challenging research task. We present a geometrical unstructured Volume-of-Fluid (VOF) method for handling two-phase flows with viscoelastic liquid phase, where the latter is modeled via generic rate-type constitutive equations and a one-field description is derived by conditional volume averaging of the local instantaneous bulk equations and interface jump conditions. The method builds on the plicRDF-isoAdvector geometrical VOF solver that is extended and combined with the modular framework DeboRheo for viscoelastic computational fluid dynamics (CFD). A piecewise-linear geometrical interface reconstruction technique on general unstructured meshes is employed for discretizing the viscoelastic stresses across the fluid interface. DeboRheo facilitates a flexible combination of different rheological models with appropriate stabilization methods to address the high Weissenberg number problem.
Program summary
Program Title: DeboRheo
CPC Library link to program files:https://doi.org/10.17632/gsgdrjm2md.1
Nature of problem: DNS of viscoelastic two-phase flows encounters major challenges due to abrupt changes of physical properties and rheological behaviors of the two phases at the fluid interface, and viscoelastic flows characterized with high Weissenberg numbers introduce additional numerical challenges.
Solution method: A geometrical unstructured Volume-of-Fluid (VOF) method for handling two-phase flows with a viscoelastic liquid phase, where the latter is modeled by generic rate-type constitutive equations. Appropriate stabilization techniques are included to address the High Weissenberg Number Problem (HWNP).
{"title":"An unstructured geometrical un-split VOF method for viscoelastic two-phase flows","authors":"Matthias Niethammer, Muhammad Hassan Asghar, Dieter Bothe, Tomislav Maric","doi":"10.1016/j.cpc.2024.109475","DOIUrl":"10.1016/j.cpc.2024.109475","url":null,"abstract":"<div><div>Since viscoelastic two-phase flows arise in various industrial and natural processes, developing accurate and efficient software for their detailed numerical simulation is a highly relevant and challenging research task. We present a geometrical unstructured Volume-of-Fluid (VOF) method for handling two-phase flows with viscoelastic liquid phase, where the latter is modeled via generic rate-type constitutive equations and a one-field description is derived by conditional volume averaging of the local instantaneous bulk equations and interface jump conditions. The method builds on the plicRDF-isoAdvector geometrical VOF solver that is extended and combined with the modular framework DeboRheo for viscoelastic computational fluid dynamics (CFD). A piecewise-linear geometrical interface reconstruction technique on general unstructured meshes is employed for discretizing the viscoelastic stresses across the fluid interface. DeboRheo facilitates a flexible combination of different rheological models with appropriate stabilization methods to address the high Weissenberg number problem.</div></div><div><h3>Program summary</h3><div><em>Program Title:</em> DeboRheo</div><div><em>CPC Library link to program files:</em> <span><span>https://doi.org/10.17632/gsgdrjm2md.1</span><svg><path></path></svg></span></div><div><em>Developer's repository link:</em> <span><span>https://gitlab.com/deborheo/deborheorelease/</span><svg><path></path></svg></span></div><div><em>Licensing provisions:</em> GPLv3</div><div><em>Programming language:</em> C++</div><div><em>Nature of problem:</em> DNS of viscoelastic two-phase flows encounters major challenges due to abrupt changes of physical properties and rheological behaviors of the two phases at the fluid interface, and viscoelastic flows characterized with high Weissenberg numbers introduce additional numerical challenges.</div><div><em>Solution method:</em> A geometrical unstructured Volume-of-Fluid (VOF) method for handling two-phase flows with a viscoelastic liquid phase, where the latter is modeled by generic rate-type constitutive equations. Appropriate stabilization techniques are included to address the High Weissenberg Number Problem (HWNP).</div></div>","PeriodicalId":285,"journal":{"name":"Computer Physics Communications","volume":"309 ","pages":"Article 109475"},"PeriodicalIF":7.2,"publicationDate":"2024-12-19","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"143127921","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":2,"RegionCategory":"物理与天体物理","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"OA","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
Pub Date : 2024-12-18DOI: 10.1016/j.cpc.2024.109474
Alexander P. Antonov , Sören Schweers , Artem Ryabov , Philipp Maass
We present an efficient method to perform overdamped Brownian dynamics simulations in external force fields and for particle interactions that include a hardcore part. The method applies to particle motion in one dimension, where it is possible to update particle positions by repositioning particle clusters as a whole. These clusters consist of several particles in contact. They form because particle collisions are treated as completely inelastic rather than elastic ones. Updating of cluster positions in time steps is carried out by cluster fragmentation and merging procedures. The presented method is particularly powerful at high collision rates in densely crowded systems, where collective movements of particle assemblies is governing the dynamics. As an application, we simulate the single-file diffusion of sticky hard spheres in a periodic potential.
{"title":"Fast Brownian cluster dynamics","authors":"Alexander P. Antonov , Sören Schweers , Artem Ryabov , Philipp Maass","doi":"10.1016/j.cpc.2024.109474","DOIUrl":"10.1016/j.cpc.2024.109474","url":null,"abstract":"<div><div>We present an efficient method to perform overdamped Brownian dynamics simulations in external force fields and for particle interactions that include a hardcore part. The method applies to particle motion in one dimension, where it is possible to update particle positions by repositioning particle clusters as a whole. These clusters consist of several particles in contact. They form because particle collisions are treated as completely inelastic rather than elastic ones. Updating of cluster positions in time steps is carried out by cluster fragmentation and merging procedures. The presented method is particularly powerful at high collision rates in densely crowded systems, where collective movements of particle assemblies is governing the dynamics. As an application, we simulate the single-file diffusion of sticky hard spheres in a periodic potential.</div></div>","PeriodicalId":285,"journal":{"name":"Computer Physics Communications","volume":"309 ","pages":"Article 109474"},"PeriodicalIF":7.2,"publicationDate":"2024-12-18","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"143093125","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":2,"RegionCategory":"物理与天体物理","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"OA","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}