Coder Social home page Coder Social logo

szaghi / off Goto Github PK

View Code? Open in Web Editor NEW
126.0 35.0 59.0 44.97 MB

OFF, Open source Finite volume Fluid dynamics code

Shell 0.76% Fortran 96.88% Makefile 2.36%
fluid-dynamics fortran oop cfd finite-volume riemann-solvers gas-dynamics hydrodynamics hpc

off's Introduction

OFF

OFF, Open source Finite volumes Fluid dynamics code see documentation.

It is written in in standard (compliant) Fortran 2003 with highly modularity as design target.

The aim of OFF is to solve, numerically, the Navier-Stokes equations of fluid dynamics by means of Finite Volume technique.

Citing

Please kindly cite OFF in your publications if it helps your research:

@article{zaghi-2014,
  author  = {S. Zaghi},
  title   = {{OFF, Open source Finite volume Fluid dynamics code: A free, high-order solver based on parallel, modular, object-oriented Fortran API}},
  journal = {Computer Physics Communications },
  volume  = {},
  number  = {0},
  pages   = { - },
  year    = {2014},
  issn    = {0010-4655},
  doi     = {http://dx.doi.org/10.1016/j.cpc.2014.04.005},
  url     = {http://www.sciencedirect.com/science/article/pii/S0010465514001283},
}

The main features of OFF code are the following:

  • Finite Volume, Godunov-like scheme based on Euler conservation Laws written in fully conservative formulation:
    • the extension to viscous Navier-Stokes equations is under developing;
  • Underling Riemann Problem solver for convective fluxes:
    • Approximate Riemann solver based on (local) Lax-Friedrichs (known also as Rusanov) algorithm;
    • Approximate Riemann solver based on Primitive Variables Linearization algorithm;
    • Approximate Riemann solver based on Two Rarefactions algorithm;
    • Approximate Riemann solver based on Two Shocks algorithm;
    • Approximate Riemann solver based on Adaptive (non iterative) PVL-TR-TS algorithm;
    • Approximate Riemann solver based on Adaptive (non iterative) LF-TR algorithm;
    • Approximate Riemann solver based on HLLC algorithm;
    • Approximate Riemann solver based on Roe linearization.
    • Exact Riemann solver based on iterative solution of u-function;
  • Multi-Species fluids models:
    • Partial Densities species conservation (Standard Thermodynamic Model);
    • New multi-dimensional conservation models of Favini, B. et al (under developing);
  • Multi-Phases fluids models:
    • Fully-coupled Lagrangian particles transport model (under developing);
  • Space numerical integration models:
    • 1-st order piece-wise constant reconstruction;
    • 2-nd order TVD linear-wise reconstruction;
    • 3-rd,5-th,7-th orders WENO non-linear reconstruction;
  • Time approximation models:
    • 1-st order forward Euler integration;
    • 2-nd,3-rd,4-th orders Strong-Stability-Preserving explicit Runge-Kutta integration;
  • Local pseudo-time convergence acceleration for steady simulations;
  • Multi-grid time convergence acceleration:
    • Multi-grid model has been already developed, but it is affected by some not still recognized bugs. Testing and bugs fixing are in progress.
  • Underling numerical grid models:
    • 3D, general curvilinear, body-fitted, structured multi-blocks mesh;
    • Adaptive Mesh Refinement, AMR model (under developing);
    • Blocks overlapping, overset (Chimera) model (to be developed in future);
  • Computational parallelism ability:
    • Domain decomposition by means of Message Passing Interface (MPI) paradigm providing the ability to use distributed-memory cluster facilities;
    • Fine, local parallelism by means of OpenMP paradigm providing the ability to use shared-memory cluster facilities;
    • Fine, local parallelism by means of GPU programming (e.g. CUDA framework) providing the ability to use GPUs cluster facilities (to be developed in future).

Copyrights

OFF is an open source project, it is distributed under the GPL v3. Anyone is interest to use, to develop or to contribute to OFF is welcome. Take a look at the contributing guidelines for starting to contribute to the project.

Documentation

Detailed documentation can be found on the GitHub pages of the project.

off's People

Contributors

giacrossi avatar szaghi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

off's Issues

Add doctests

Exploit FoBiS doctests for improving code coverage/regression/usage-documentation.

New code roadmap

Desiderata features

  • Compressible, multi-fluid, multi-phase, Navier-Stokes equations:
    • Preconditioned equations to efficient handling incompressibile, compressible, cavitating and multi-phase stiff problems;
    • Turbulent models:
      • LES:
        • Smagorinsky;
        • Germano;
      • DES-DDES;
      • WM-LES;
      • k-e, k-w;
    • Multi-fluid models:
      • Partial densities species conservation (Standard Thermodynamic Model);
    • Multi-Phase models:
      • Fully-coupled Lagrangian particles transport model;
  • Fully-conservative Finite Volume Schemes:
    • Space integration models:
      • Riemann Problem solvers for convective fluxes:
        • Approximate Riemann solver based on (local) Lax-Friedrichs (known also as Rusanov) algorithm;
        • Approximate Riemann solver based on Primitive Variables Linearization algorithm;
        • Approximate Riemann solver based on Two Rarefactions algorithm;
        • Approximate Riemann solver based on Two Shocks algorithm;
        • Approximate Riemann solver based on Adaptive (non iterative) PVL-TR-TS algorithm;
        • Approximate Riemann solver based on Adaptive (non iterative) LF-TR algorithm;
        • Approximate Riemann solver based on HLLC algorithm;
        • Approximate Riemann solver based on Roe linearization.
        • Exact Riemann solver based on iterative solution of u-function;
        • Rotated Riemann solvers;
      • High order finite volume approximations for diffusive (viscous) fluxes;
      • Very High Order WENO reconstructions;
    • Time approximation models:
      • Strong-Stability-Preserving explicit/implicit Runge-Kutta integration;
      • Low Storage explicit/implicit Runge-Kutta integration;
      • Embeded explicit Runge-Kutta integration;
      • Very high-order multi-step Adams-Bashfort-Moulton integration;
      • Backward Differentian Formula integration;
      • Local pseudo-time convergence acceleration for steady simulations;
      • Multi-grid time convergence acceleration:
    • General curvilinear block-structured grids;
      • Adaptive Mesh Refinement (AMR);
      • Dynamic Overlapping Grids;
      • Immersed Boundaries;
    • General curvilinear unstructured grids;
    • Moving grids;
  • Programming API:
    • Computational kernels in Fortran (possible Python interface);
    • Computational parallelism (exascale targetting):
      • partitioned global address space (PGAS) model by means of Coarrays Fortran (CAF);
    • Object Oriented Programming (OOP):
      • Abstract Calculus Pattern;
      • Very high-level programming interface;
    • Test Driven Development (TDD);
    • Fully documented;

Unlimited polymorphic pointers violate standard

The standard (2003/2008) seems to not allow a typed pointer to point an unlimited polymorphic one, e.g. the following seems to be not standard:

class(*), pointer:: foo
type(mytype), pointer:: bar

bar => foo
call bar%mymethod(...)

Presently, such a pointers association is widely used in OFF, e.g. https://github.com/szaghi/OFF/blob/testing/src/Data_Type_Tree.f90#L210 and https://github.com/szaghi/OFF/blob/testing/src/Data_Type_Global.f90#L130.

Think to a workaround.

Code refactoring for Feng's work

The master and testing branches are very old, many progresses have been done with other libraries. To help @fxie2 to be more comfortable, OFF must be updated/refactored.

  • add PENF as third_party dependency;
  • add WenOOF as third_party dependency;
  • add FOODIE as third_party dependency;
  • add support for Travis CI;
  • made a coverage analysis;

Bug in Dt estimation

The algorithm for estimating the time step Dt is bugged, see https://github.com/szaghi/OFF/blob/testing/src/Data_Type_SBlock.f90#L1300

The speed of sound is not multiplied for the interface area thus the vmax is underestimated. Corrected computation should be something like

        ! computing the local speed of sound
        ss = a(p=block%C(i,j,k)%P%p,r=block%C(i,j,k)%P%d,g=block%C(i,j,k)%P%g)
        ! evaluating the maximum propagation speed of acoustic segnals multiplied for face area
        ! left i
        vm   = 0.5_R_P*(block%C(i-1,j,k)%P%v+block%C(i,j,k)%P%v)
        vmiL = (abs(vm.dot.block%Fi(i-1,j,k)%N) + ss ) * block%Fi(i-1,j,k)%S

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.