GithubHelp home page GithubHelp logo

flomnes / optiflow Goto Github PK

View Code? Open in Web Editor NEW
3.0 1.0 3.0 301 KB

Optiflow is an implementation of a shape-optimization method for two-dimensional incompressible flows.

License: GNU General Public License v3.0

Gnuplot 28.41% Shell 71.59%
freefem shape-optimization fluid-simulation

optiflow's Introduction

optiflow

Optiflow is an implementation of a shape-optimization method for two-dimensional incompressible flows.

Installation

  1. You will need a recent FreeFem++ installation, see http://www.freefem.org/ff++/. This program was written and tested with FreeFem++ 3.42 and should work properly with any subsequent version.

  2. Download the zip archive at https://github.com/flomnes/optiflow/archive/master.zip or clone this repository

    git clone https://github.com/flomnes/optiflow.git
    

    then navigate to the decompressed directory :

    cd optiflow-master
    

    or

    cd optiflow
    

Usage

Seven examples can be found in the file run_case.sh. The general syntax is

FreeFem++-nw main.edp [--config numconfig] [--resu resfolder] [numerical parameters]

The basic options are:

--config	configuration number, from 1 to 5
--resu		folder in which the files and results will be saved, created if non-existent

Numerical paramters:

--navsto	1=Navier-Stokes, 0=Stokes
--raffinit	required edge size when remeshing : hmax=raffinit, hmin=raffinit/sqrt(2)
--optraff	1=remesh if necessary, 0=no remeshing
--minarea	remesh if any element has an area less than minarea
--binit		initial value for b
--btarget	final value for b : b is no longer updated if b >= btarget
--tau		value of tau, step of the gradient method
--l0		initial value of the Lagrange multiplier
--gamma		value of the regularization parameter
--jjmax		maximal number of outer iterations
--errc		value for the stopping criterion \eps_{stop} on the residual
--beta		0 for perimeter constraint, 1 for volume constraint (default)
--delta		Select the functional : 0 for the dissipated energy, 1 for the least-square profile at the outlet
--cv		Ratio (required constraint value)/(initial constraint value). 1 for an identical initial and required volume or perimeter
--alpha		Update ratio for b : b^{n+1}=alpha*b^n
--save		1=save all figures in the result directory, 0=save nothing at all
--saveevery n	figures will be saved every n iterations

Notes

  1. If gnuplot is installed, you can plot relevant data from a result directory. Simply copy plot.gp from the project root the result directory and execute gnuplot plot.gp. A file called "multi.pdf" will be generated.

  2. Crashes may occur for because of mesh self-intersections. You may try to choose a smaller value for tau. You can also increase the value of minarea so that remeshing will be done earlier.

Test-cases 6 & 7

Test-cases 6 and 7 are given as additional material. In test-case 6, a simple pipe is considered. On the left, fixed inlet, and on the right, an outlet allowed to move tangentially. In test-case 7, a double-pipe is considered, with an inlet on the left and two outlets on the right. The closing of one of the outlets entails mesh self-intersections.

Authors & contributors

  • optiflow has been developped by Florian Omnès (Université Pierre et Marie-Curie), Yannick Privat (Université Pierre et Marie Curie, CNRS), Charles Dapogny (Université Grenobles-Alpes, CNRS) and Pascal Frey (Université Pierre et Marie Curie, Institut du Calcul et des Données)
  • Anyone wishing to contribute is welcome to suggest modification through a push request.

License

optiflow is licensed under the terms of the LGPL (LICENSE.md). Copyright Sorbonne-Universités 2016-2018.

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.