1"use strict";(self.webpackChunkdune_copasi_docusaurus=self.webpackChunkdune_copasi_docusaurus||[]).push([[8072],{2320:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>h,contentTitle:()=>c,default:()=>m,frontMatter:()=>a,metadata:()=>u,toc:()=>p});var i=t(4848),s=t(8453),r=t(1470),o=t(9365),l=t(1254),d=t(2826);const a={id:"install_source",title:"Install From Source",description:"How to build from source",sidebar_label:"Install from Source",tags:["API","CLI"]},c=void 0,u={id:"install_source",title:"Install From Source",description:"How to build from source",source:"@site/docs/install_source.mdx",sourceDirName:".",slug:"/install_source",permalink:"/docs/next/install_source",draft:!1,unlisted:!1,editUrl:"https://gitlab.dune-project.org/copasi/dune-copasi/-/edit/master/doc/docusaurus/docs/install_source.mdx",tags:[{inline:!0,label:"API",permalink:"/docs/next/tags/api"},{inline:!0,label:"CLI",permalink:"/docs/next/tags/cli"}],version:"current",lastUpdatedBy:"Santiago Ospina De Los Rios",lastUpdatedAt:1723635401e3,frontMatter:{id:"install_source",title:"Install From Source",description:"How to build from source",sidebar_label:"Install from Source",tags:["API","CLI"]},sidebar:"docs",previous:{title:"Install from Package Manager",permalink:"/docs/next/install_package"},next:{title:"Usage Options",permalink:"/docs/next/category/docs/use"}},h={},p=[{value:"Dependencies",id:"dependencies",level:2},{value:"Install Generic Dependencies",id:"install-generic-dependencies",level:2},{value:"Download DuneCopasi and DUNE dependencies",id:"download-dunecopasi-and-dune-dependencies",level:2},{value:"Dune Options File",id:"dune-options-file",level:2},{value:"CMake configuration options",id:"cmake-configuration-options",level:2},{value:"Build and Install",id:"build-and-install",level:2},{value:"Run the program",id:"run-the-program",level:2}];function x(e){const n={a:"a",admonition:"admonition",code:"code",em:"em",h2:"h2",li:"li",ol:"ol",p:"p",pre:"pre",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,s.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(n.admonition,{title:"development",type:"caution",children:(0,i.jsx)(n.p,{children:"These are the instruction for the development branch of DuneCopasi!"})}),"\n",(0,i.jsx)(n.admonition,{title:"docker build",type:"tip",children:(0,i.jsxs)(n.p,{children:["This mode of installation is recommended only for ",(0,i.jsx)(n.a,{href:"use_api",children:"API usage"}),", immersive developemt,\nor cases where upstream dependencies need to be modified. In other cases, you can easily modify\nthe source code, build it, and use it through a ",(0,i.jsx)(n.a,{href:"install_docker",children:"docker installation"})," without needing\nto install the dependencies."]})}),"\n",(0,i.jsx)(n.admonition,{title:"Operating Systems and Compilers",type:"note",children:(0,i.jsxs)(n.p,{children:["The installation from source is known to compile and run under Debian/Ubuntu, macOS, and Windows.\nIn all three cases with ",(0,i.jsx)(n.a,{href:"https://clang.llvm.org",children:"Clang"})," and ",(0,i.jsx)(n.a,{href:"https://gcc.gnu.org",children:"GCC"}),"\nbased compilers. It is known to be ",(0,i.jsx)(n.strong,{children:"not"})," compatible with Microsoft Visual Studio."]})}),"\n",(0,i.jsx)(n.h2,{id:"dependencies",children:"Dependencies"}),"\n",(0,i.jsx)(n.p,{children:"Locally building and installing DuneCopasi requires a variety of dependencies:"}),"\n",(0,i.jsx)(n.admonition,{title:"development branches",type:"caution",children:(0,i.jsxs)(n.p,{children:["Many of these dependencies are in a development branch (e.g., ",(0,i.jsx)(n.code,{children:"master"}),") because DuneCopasi is also under developemt\nor because the package does not offer other tagged release."]})}),"\n",(0,i.jsxs)(n.table,{children:[(0,i.jsx)(n.thead,{children:(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.th,{children:"Software"}),(0,i.jsx)(n.th,{children:"Version/Branch"})]})}),(0,i.jsxs)(n.tbody,{children:[(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://cmake.org/",children:"CMake"})}),(0,i.jsx)(n.td,{children:">= 3.16"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"C++ compiler"}),(0,i.jsxs)(n.td,{children:[">= ",(0,i.jsx)(n.a,{href:"https://en.wikipedia.org/wiki/List_of_compilers#C++_compilers",children:"C++20"})]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://www.freedesktop.org/wiki/Software/pkg-config",children:"pkg-config"})}),(0,i.jsx)(n.td,{children:">= 1.8.1"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://fmt.dev/",children:"{fmt}"})}),(0,i.jsx)(n.td,{children:">= 9.1.0"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://github.com/gabime/spdlog",children:"spdlog"})}),(0,i.jsx)(n.td,{children:">= 1.10.0"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"http://www.libtiff.org/",children:"libTIFF"})}),(0,i.jsx)(n.td,{children:">= 3.6.1"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsxs)(n.td,{children:[(0,i.jsx)(n.a,{href:"https://beltoforion.de/article.php?a=muparser",children:"muParser"})," (optional)"]}),(0,i.jsx)(n.td,{children:">= 2.2.5"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsxs)(n.td,{children:[(0,i.jsx)(n.a,{href:"https://symengine.org",children:"SymEngine"})," (optional)"]}),(0,i.jsx)(n.td,{children:">= 0.8.0"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsxs)(n.td,{children:[(0,i.jsx)(n.a,{href:"https://www.partow.net/programming/exprtk",children:"ExprTk"})," (optional, automatic)"]}),(0,i.jsx)(n.td,{children:">= 0.0.2"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsxs)(n.td,{children:[(0,i.jsx)(n.a,{href:"https://github.com/KarypisLab/METIS",children:"METIS"})," (optional)"]}),(0,i.jsx)(n.td,{children:">= 5.1.0"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsxs)(n.td,{children:[(0,i.jsx)(n.a,{href:"https://github.com/parafields/parafields-core",children:"parafields-core"})," (optional, automatic)"]}),(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"master"})})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsxs)(n.td,{children:[(0,i.jsx)(n.a,{href:"https://www.mpi-forum.org",children:"MPI"})," (optional)"]}),(0,i.jsx)(n.td,{children:">= 3.1"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsxs)(n.td,{children:[(0,i.jsx)(n.a,{href:"https://www.fft
1w.org",children:"FFTW"})," (optional)"]}),(0,i.jsx)(n.td,{children:">= 3.0.0"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsxs)(n.td,{children:[(0,i.jsx)(n.a,{href:"https://oneapi-src.github.io",children:"TBB"})," (optional)"]}),(0,i.jsx)(n.td,{children:">= 2018.12"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsxs)(n.td,{children:[(0,i.jsx)(n.a,{href:"https://google.github.io",children:"GTest"})," (optional, automatic)"]}),(0,i.jsx)(n.td,{children:">= 1.12.1"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsxs)(n.td,{children:[(0,i.jsx)(n.a,{href:"https://naios.github.io/function2/",children:"function2"})," (automatic)"]}),(0,i.jsx)(n.td,{children:">= 4.2.3"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsxs)(n.td,{children:[(0,i.jsx)(n.a,{href:"https://github.com/nlohmann/json",children:"nlohmann::json"})," (automatic)"]}),(0,i.jsx)(n.td,{children:">= 3.11.3"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://people.engr.tamu.edu/davis/suitesparse.html",children:"SuiteSparse"})}),(0,i.jsx)(n.td,{children:">= 2.3.3"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://perfetto.dev",children:"Perfetto"})}),(0,i.jsx)(n.td,{children:">= 32.1"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://gitlab.dune-project.org/core/dune-common",children:"dune-common"})}),(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"master"})})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://gitlab.dune-project.org/core/dune-geometry",children:"dune-geometry"})}),(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"master"})})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://gitlab.dune-project.org/core/dune-grid",children:"dune-grid"})}),(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"master"})})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://gitlab.dune-project.org/staging/dune-uggrid",children:"dune-uggrid"})}),(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"master"})})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://gitlab.dune-project.org/core/dune-istl",children:"dune-istl"})}),(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"master"})})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://gitlab.dune-project.org/core/dune-localfunctions",children:"dune-localfunctions"})}),(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"master"})})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://gitlab.dune-project.org/staging/dune-functions",children:"dune-functions"})}),(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"master"})})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://gitlab.dune-project.org/extensions/dune-multidomaingrid",children:"dune-multidomaingrid"})}),(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"master"})})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://gitlab.dune-project.org/staging/dune-typetree",children:"dune-typetree"})}),(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"master"})})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.a,{href:"https://gitlab.dune-project.org/pdelab/dune-pdelab",children:"dune-pdelab"})}),(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"feature/dune-assembler/main-multithreaded"})})]})]})]}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.strong,{children:"automatic"}),": The requirement is automatically fetched from the internet by CMake.\nSee the ",(0,i.jsx)(n.a,{href:"#cmake-configuration-options",children:"CMake configuration options"})," on how to enable/disable this feature."]}),"\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.strong,{children:"optional"}),": The software package is not mandatory (but recommended) to build DuneCopasi."]}),"\n"]}),"\n",(0,i.jsx)(n.admonition,{title:"MPI and FFTW requirements",type:"note",children:(0,i.jsxs)(n.p,{children:["The MPI and FFTW packages are only to fulfill the requirements of parafields-core.\nIf these packages are present if your system, CMake can resolve parafields-core automatically by setting the option\n",(0,i.jsx)(n.code,{children:"DUNE_COPASI_DISABLE_FETCH_PACKAGE_parafields"})," to ",(0,i.jsx)(n.code,{children:"OFF"})," in CMake."]})}),"\n",(0,i.jsx)(n.h2,{id:"install-generic-dependencies",children:"Install Generic Dependencies"}),"\n",(0,i.jsx)(n.p,{children:"Many of the generic dependencies can be directly obtained by package managers, e.g.,"}),"\n",(0,i.jsxs)(r.A,{groupId:"package-manager",defaultValue:"apt",values:[{label:"Debian/Ubuntu (apt)",value:"apt"},{label:"macOS/Linux (brew)",value:"brew"}],children:[(0,i.jsx)(o.A,{value:"apt",children:(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-bash",children:"apt update\napt install \\\n cmake \\\n g++ \\\n gcc \\\n git \\\n libmuparser-dev \\\n libfft
1w3-dev \\\n libfftw3-mpi-dev \\\n libgtest-dev \\\n libscotchmetis-dev \\\n libspdlog-dev \\\n libtbb-dev \\\n libtiff-dev \\\n mpi-default-bin \\\n mpi-default-dev \\\n pkg-config\n"})})}),(0,i.jsx)(o.A,{value:"brew",children:(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-bash",children:"brew update\nbrew install \\\n cmake \\\n fftw \\\n fmt \\\n gcc \\\n git \\\n libtiff \\\n metis \\\n muparser \\\n open-mpi \\\n pkg-config \\\n scotch \\\n spdlog \\\n suite-sparse \\\n symengine \\\n tbb\n"})})})]}),"\n",(0,i.jsx)(n.h2,{id:"download-dunecopasi-and-dune-dependencies",children:"Download DuneCopasi and DUNE dependencies"}),"\n",(0,i.jsx)(n.admonition,{title:"DUNE Version incompatibility",type:"danger",children:(0,i.jsx)(n.p,{children:"Notice that this procedure assumes that you don't have previous installation of DUNE in\nyour system. If that's the case, uninstall DUNE before continuing, otherwise, version\nconflicts may be difficult if not impossible to resolve!"})}),"\n",(0,i.jsxs)(n.p,{children:["The required DUNE modules (including DuneCopasi) can be obtained via\ninternet by using ",(0,i.jsx)(n.a,{href:"https://git-scm.com/",children:(0,i.jsx)(n.code,{children:"git"})}),". For smooth installation, is\nbetter place all the dune modules within the same directory:"]}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-bash",children:"# prepare a folder to download and build dune modules (e.g. ~/dune-modules)\nmkdir ~/dune-modules && cd ~/dune-modules\n"})}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-bash",metastring:'title="~/dune-modules"',children:"# fetch dependencies & dune-copasi in ~/dune-modules folder\ngit clone https://gitlab.dune-project.org/core/dune-common\ngit clone https://gitlab.dune-project.org/core/dune-geometry\ngit clone https://gitlab.dune-project.org/core/dune-grid\ngit clone https://gitlab.dune-project.org/staging/dune-uggrid\ngit clone https://gitlab.dune-project.org/core/dune-istl\ngit clone https://gitlab.dune-project.org/core/dune-localfunctions\ngit clone https://gitlab.dune-project.org/staging/dune-functions\ngit clone https://gitlab.dune-project.org/extensions/dune-multidomaingrid\ngit clone https://gitlab.dune-project.org/staging/dune-typetree\ngit clone -b feature/dune-assembler/main-multithreaded https://gitlab.dune-project.org/pdelab/dune-pdelab\ngit clone https://gitlab.dune-project.org/copasi/dune-copasi\n"})}),"\n",(0,i.jsx)(n.h2,{id:"dune-options-file",children:"Dune Options File"}),"\n",(0,i.jsxs)(n.p,{children:["An important part of the installation procedure is to tune the build system\
1nflags to accommodate the build options to your system: this is done via the ",(0,i.jsx)(n.a,{href:"https://dune-project.org/doc/installation/#storing-flags-in-an-options-file",children:"dune options\nfile"}),".\nIn essence, is just a bash script that sets different flags (mainly the flags\nfor CMake ",(0,i.jsx)(n.code,{children:"CMAKE_FLAGS"}),"). While the dune project usually leaves this open for the user, we\nprovide a ",(0,i.jsx)(n.code,{children:"dune-copasi.opts"})," file with sensible default options for the main\noperating systems. You can find this file in the root directory of the ",(0,i.jsx)(n.code,{children:"dune-copasi"})," repository."]}),"\n",(0,i.jsx)(n.p,{children:"This file can be executed to show the current configuration:"}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-bash",children:"# choose root dune-copasi directory\ncd ~/dune-modules/dune-copasi\n# show current build configuration options\n./dune-copasi.opts\n"})}),"\n",(0,i.jsx)(n.p,{children:"Executing the configuration options will display something similar to this:"}),"\n",(0,i.jsx)(d.A,{prompt:"~/dune-modules/dune-copasi$",title:"Current build configuration options",children:[{input:"./dune-copasi.opts",output:["Installation Prefix:"," /opt/dune","OS Type:"," linux","CMake flags:"," -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_FLAGS='-fvisibility=hidden -fpic' -DCMAKE_CXX_FLAGS_DEBUG='-O0 -g' -DCMAKE_CXX_FLAGS_RELEASE='-O3 -DNDEBUG' -DCMAKE_CXX_FLAGS_RELWITHDEBINFO='-O2 -g3 -DNDEBUG -fno-omit-frame-pointer' -DCMAKE_CXX_STANDARD=17 -DCMAKE_DISABLE_FIND_PACKAGE_MPI=OFF -DCMAKE_GENERATOR='Unix Makefiles' -DCMAKE_INSTALL_PREFIX=/opt/dune -DCMAKE_PREFIX_PATH='/opt/dune' -DDUNE_PDELAB_ENABLE_TRACING=ON ","Make flags:"," "]}]}),"\n",(0,i.jsxs)(n.p,{children:["There are two forms to add flags to the ",(0,i.jsx)(n.code,{children:"dune-copasi.opts"})," file:"]}),"\n",(0,i.jsxs)(n.ol,{children:["\n",(0,i.jsxs)(n.li,{children:["Setting environmental variables starging with ",(0,i.jsx)(n.code,{children:"CMAKE_"})," and ",(0,i.jsx)(n.code,{children:"DUNE_"}),".\nThese variables will be automatically included into the list of cmake flags."]}),"\n"]}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-bash",metastring:'title="~/dune-modules/dune-copasi/"',children:'export CMAKE_INSTALL_PREFIX="/path/to/install/prefix/"\nexport CMAKE_GENERATOR="\'Ninja\'"\n./dune-copasi.opts\n'})}),"\n",(0,i.jsxs)(n.ol,{start:"2",children:["\n",(0,i.jsxs)(n.li,{children:["Appending new flags into the ",(0,i.jsx)(n.code,{children:"CMAKE_FLAGS"})," variable in the ",(0,i.jsx)(n.code,{children:"dune-copasi.opts"})," file\n(care must be taken to scape quotes):"]}),"\n"]}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-bash",metastring:'title="~/dune-modules/dune-copasi/"',children:'echo \'CMAKE_FLAGS+=" -DCMAKE_INSTALL_PREFIX=/path/to/install/prefix/"\' >> dune-copasi.opts\necho "CMAKE_FLAGS+=\\" -DCMAKE_GENERATOR=\'Ninja\'\\"" >> dune-copasi.opts\n./dune-copasi.opts\n'})}),"\n",(0,i.jsxs)(n.p,{children:["For more information about the possible options and the dune options file, check out\nthe dune ",(0,i.jsx)(n.a,{href:"https://dune-project.org/doc/installation/",children:"installation documentation"}),"\nand its ",(0,i.jsx)(n.a,{href:"https://dune-project.org/sphinx/core-2.7/",children:"build system documentation"}),"."]}),"\n",(0,i.jsx)(n.h2,{id:"cmake-configuration-options",children:"CMake configuration options"}),"\n",(0,i.jsx)(n.p,{children:"The following is the list of options to customize the build of DuneCopasi."}),"\n",(0,i.jsxs)(n.table,{children:[(0,i.jsx)(n.thead,{children:(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.th,{children:(0,i.jsx)(n.code,{children:"CACHE:TYPE=DEFAULT"})}),(0,i.jsx)(n.th,{children:"Description"})]})}),(0,i.jsxs)(n.tbody,{children:[(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"DUNE_COPASI_WITH_EXECUTABLE:BOOL=ON"})}),(0,i.jsx)(n.td,{children:"Build dune-copasi executable"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"DUNE_COPASI_CONCURRENT_ASSEMBLY:BOOL=ON"})}),(0,i.jsx)(n.td,{children:"Build with concurrent assembly. Turn off to reduce memory consumption"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"DUNE_COPASI_PRECOMPILED_MODE:BOOL=ON"})}),(0,i.jsx)(n.td,{children:"Pre-build a fixed set of class instances"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:'DUNE_COPASI_GRID_DIMENSIONS:STRING="2"'})}),(0,i.jsx)(n.td,{children:"Semi-colon separated list of dimensions to build"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:'DUNE_COPASI_${dim}D_DIFFUSION_REACTION_FEM_ORDERS:STRING="1"'})}),(0,i.jsxs)(n.td,{children:["Semi-colon separated list of finite element order to compile for dimension ",(0,i.jsx)(n.code,{children:"${dim}"})]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"DUNE_COPASI_DISABLE_FETCH_PACKAGE_ExprTk:BOOL=OFF"})}),(0,i.jsx)(n.td,{children:"Disable automatic fetch of ExprTk package"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"DUNE_COPASI_DISABLE_FETCH_PACKAGE_parafields:BOOL=OFF"})}),(0,i.jsx)(n.td,{children:"Disable automatic fetch of parafields-core package"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"DUNE_COPASI_DISABLE_FMT_STYLE:BOOL=OFF"})}),(0,i.jsx)(n.td,{children:"Disable {fmt} styling"})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:(0,i.jsx)(n.code,{children:"DUNE_PDELAB_ENABLE_TRACING:BOOL=ON"})}),(0,i.jsx)(n.td,{children:"Enable automatic fetch of perfetto"})]})]})]}),"\n",(0,i.jsx)(n.h2,{id:"build-and-install",children:"Build and Install"}),"\n",(0,i.jsx)(n.p,{children:"Before starting the build process, make sure to have your terminal in the directory with all DUNE modules:"}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-bash",children:"# choose root dune modules directory\ncd ~/dune-modules\n"})}),"\n",(0,i.jsxs)(n.p,{children:["The, build and install the ",(0,i.jsx)(n.em,{children:"all"})," of the DUNE modules with the ",(0,i.jsx)(n.code,{children:"dunecontrol"})," script from ",(0,i.jsx)(n.code,{children:"dune-common"}),":"]}),"\n",(0,i.jsx)(n.admonition,{title:"Memory usage",type:"warning",children:(0,i.jsxs)(n.p,{children:["The building stage is known to take substantial memory during compilation (varies depen
1ding on the compiler).\nIf your system fails to build due to insufficient memory, try serializing the build process with the ",(0,i.jsx)(n.code,{children:"-j {cores}"})," flag\nand disabling some of the features."]})}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-bash",metastring:'title="~/dune-modules"',children:"# choose an installation path (this is read by the 'dune-copasi.opts' file)\nexport CMAKE_INSTALL_PREFIX=/opt/dune\n\n# uncomment if you have MPI and FFTW\n# export DUNE_COPASI_DISABLE_FETCH_PACKAGE_parafields=OFF\n\n# configure and build dune modules (go grab a coffee \u2615)\n./dune-common/bin/dunecontrol --opts=dune-copasi/dune-copasi.opts all\n\n# (optional) build tests\n./dune-common/bin/dunecontrol --opts=dune-copasi/dune-copasi.opts --module=dune-copasi cmake -t build_tests\n\n# (optional) run unit, system and tutorial tests on built binaries\n./dune-common/bin/dunecontrol --opts=dune-copasi/dune-copasi.opts --module=dune-copasi bexec ctest\n\n# install libraries and binaries (may require sudo \ud83d\udd12)\n./dune-common/bin/dunecontrol --opts=dune-copasi/dune-copasi.opts bexec make install\n\n# remove source and build files from working directory\ncd ~ && rm -r ~/dune-modules\n\n# include dune binaries into your path (if you use bash)\necho \"export PATH=${CMAKE_INSTALL_PREFIX}/bin:\\$PATH\" >> $HOME/.bashrc\n"})}),"\n",(0,i.jsx)(n.admonition,{title:"Active development cycle",type:"tip",children:(0,i.jsxs)(n.p,{children:["An active development cycle does not need you to install the packages.\nInstead, you can run the program directly in the build directory (i.e., ",(0,i.jsx)(n.code,{children:"bin/dune-copasi"}),"). In that case, we recommend\nusing ",(0,i.jsx)(n.code,{children:"--builddir"})," option from ",(0,i.jsx)(n.code,{children:"dunecontrol"})," in order to keep all the DUNE build directorties out of the source code."]})}),"\n",(0,i.jsxs)(n.p,{children:["For further information on dune module installation process, check out\nthe ",(0,i.jsx)(n.a,{href:"https://www.dune-project.org/doc/installation/",children:"dune-project web page"}),"."]}),"\n",(0,i.jsx)(n.h2,{id:"run-the-program",children:"Run the program"}),"\n",(0,i.jsxs)(n.p,{children:["Once installed, the program ",(0,i.jsx)(n.code,{children:"dune-copasi"})," will be available on the command line and be ready for ",(0,i.jsx)(n.a,{href:"use_cli",children:"CLI usage"}),":"]}),"\n",(0,i.jsx)(l.A,{}),"\n",(0,i.jsx)(n.admonition,{title:"Configuration Options",type:"tip",children:(0,i.jsxs)(n.p,{children:["For more information on the possible options to successfully run a simulation, make sure to visit the ",(0,i.jsx)(n.a,{href:"use_cli",children:"Command Line Interface"}),", the ",(0,i.jsx)(n.a,{href:"param_tree",children:"Configuration Options"}),", and the ",(0,i.jsx)(n.a,{href:"/tutorials",children:"Tutorials"})," documentations!"]})})]})}function m(e={}){const{wrapper:n}={...(0,s.R)(),...e.components};return n?(0,i.jsx)(n,{...e,children:(0,i.jsx)(x,{...e})}):x(e)}},1254:(e,n,t)=>{t.d(n,{A:()=>r});var i=t(2826),s=t(4848);function r(e){let{prefix:n}=e;return n=n||"",(0,s.jsx)(i.A,{title:"Command Line Interface of DuneCopasi",children:[{input:`${n}
1dune-copasi --help`,output:["USAGE: dune-copasi [options]","","Numerical simulator for diffusion-reaction systems on single or multiple compartments","","Website: <https://dune-copasi.netlify.app>","","OPTIONS:",""," -h / --help - Display this help."," --help-full - Display this help with long descriptions."," --version - Display the version of this program."," --parser-default - Display the default parser."," --parser-list - Display the parsers available for this program."," --dimension-list - Display the grid dimensions available for this program."," --dump-config - Dumps configuration in the INI format to stdout."," --config=<string> - Specifies a config file in INI format. See Configuration Options."," --{key}={value} - Overrides key=value sections of the config file. See Configuration Options.","","..."]}]})}},9365:(e,n,t)=>{t.d(n,{A:()=>o});t(6540);var i=t(8215);const s={tabItem:"tabItem_Ymn6"};var r=t(4848);function o(e){let{children:n,hidden:t,className:o}=e;return(0,r.jsx)("div",{role:"tabpanel",className:(0,i.A)(s.tabItem,o),hidden:t,children:n})}},1470:(e,n,t)=>{t.d(n,{A:()=>E});var i=t(6540),s=t(8215),r=t(3104),o=t(6347),l=t(205),d=t(7485),a=t(1682),c=t(679);function u(e){return i.Children.toArray(e).filter((e=>"\n"!==e)).map((e=>{if(!e||(0,i.isValidElement)(e)&&function(e){const{props:n}=e;return!!n&&"object"==typeof n&&"value"in n}(e))return e;throw new Error(`Docusaurus error: Bad <Tabs> child <${"string"==typeof e.type?e.type:e.type.name}>: all children of the <Tabs> component should be <TabItem>, and every <TabItem> should have a unique "value" prop.`)}))?.filter(Boolean)??[]}function h(e){const{values:n,children:t}=e;return(0,i.useMemo)((()=>{const e=n??function(e){return u(e).map((e=>{let{props:{value:n,label:t,attributes:i,default:s}}=e;return{value:n,label:t,attributes:i,default:s}}))}(t);return function(e){const n=(0,a.XI)(e,((e,n)=>e.value===n.value));if(n.length>0)throw new Error(`Docusaurus error: Duplicate values "${n.map((e=>e.value)).join(", ")}" found in <Tabs>. Every value needs to be unique.`)}(e),e}),[n,t])}function p(e){let{value:n,tabValues:t}=e;return t.some((e=>e.value===n))}function x(e){let{queryString:n=!1,groupId:t}=e;const s=(0,o.W6)(),r=function(e){let{queryString:n=!1,groupId:t}=e;if("string"==typeof n)return n;if(!1===n)return null;if(!0===n&&!t)throw new Error('Docusaurus error: The <Tabs> component groupId prop is required if queryString=true, because this value is used as the search param name. You can also provide an explicit value such as queryString="my-search-param".');return t??null}({queryString:n,groupId:t});return[(0,d.aZ)(r),(0,i.useCallback)((e=>{if(!r)return;const n=new URLSearchParams(s.location.search);n.set(r,e),s.replace({...s.location,search:n.toString()})}),[r,s])]}function m(e){const{defaultValue:n,queryString:t=!1,groupId:s}=e,r=h(e),[o,d]=(0,i.useState)((()=>function(e){let{defaultValue:n,tabValues:t}=e;if(0===t.length)throw new Error("Docusaurus error: the <Tabs> component requires at least one <TabItem> children component");if(n){if(!p({value:n,tabValues:t}))throw new Error(`Docusaurus error: The <Tabs> has a defaultValue "${n}" but none of its children has the corresponding value. Available values are: ${t.map((e=>e.value)).join(", ")}. If you intend to show no default tab, use defaultValue={null} instead.`);return n}const i=t.find((e=>e.default))??t[0];if(!i)throw new Error("Unexpected error: 0 tabValues");return i.value}({defaultValue:n,tabValues:r}))),[a,u]=x({queryString:t,groupId:s}),[m,j]=function(e){let{groupId:n}=e;const t=function(e){return e?`docusaurus.tab.${e}`:null}(n),[s,r]=(0,c.Dv)(t);return[s,(0,i.useCallback)((e=>{t&&r.set(e)}),[t,r])]}({groupId:s}),f=(()=>{const e=a??m;return p({value:e,tabValues:r})?e:null})();(0,l.A)((()=>{f&&d(f)}),[f]);return{selectedValue:o,selectValue:(0,i.useCallback)((e=>{if(!p({value:e,tabValues:r}))throw new Error(`Can't select invalid tab value=${e}`);d(e),u(e),j(e)}),[u,j,r]),tabValues:r}}var j=t(2303);const f={tabList:"tabList__CuJ",tabItem:"tabItem_LNqP"};var g=t(4848);function b(e){let{className:n,block:t,selectedValue:i,selectValue:o,tabValues:l}=e;const d=[],{blockElementScrollPositionUntilNextRender:a}=(0,r.a_)(),c=e=>{const n=e.currentTarget,t=d.indexOf(n),s=l[t].value;s!==i&&(a(n),o(s))},u=e=>{let n=null;switch(e.key){case"Enter":c(e);break;case"ArrowRight":{const t=d.indexOf(e.currentTarget)+1;n=d[t]??d[0];break}case"ArrowLeft":{const t=d.indexOf(e.currentTarget)-1;n=d[t]??d[d.length-1];break}}n?.focus()};return(0,g.jsx)("ul",{role:"tablist","aria-orientation":"horizontal",className:(0,s.A)("tabs",{"tabs--block":t},n),children:l.map((e=>{let{value:n,label:t,attributes:r}=e;return(0,g.jsx)("li",{role:"tab",tabIndex:i===n?0:-1,"aria-selected":i===n,ref:e=>d.push(e),onKeyDown:u,onClick:c,...r,className:(0,s.A)("tabs__item",f.tabItem,r?.className,{"tabs__item--active":i===n}),children:t??n},n)}))})}function y(e){let{lazy:n,children:t,selectedValue:r}=e;
1const o=(Array.isArray(t)?t:[t]).filter(Boolean);if(n){const e=o.find((e=>e.props.value===r));return e?(0,i.cloneElement)(e,{className:(0,s.A)("margin-top--md",e.props.className)}):null}return(0,g.jsx)("div",{className:"margin-top--md",children:o.map(((e,n)=>(0,i.cloneElement)(e,{key:n,hidden:e.props.value!==r})))})}function v(e){const n=m(e);return(0,g.jsxs)("div",{className:(0,s.A)("tabs-container",f.tabList),children:[(0,g.jsx)(b,{...n,...e}),(0,g.jsx)(y,{...n,...e})]})}function E(e){const n=(0,j.A)();return(0,g.jsx)(v,{...e,children:u(e.children)},String(n))}},2826:(e,n,t)=>{t.d(n,{A:()=>r});t(6540);var i=t(1308),s=t(4848);function r(e){let{children:n,prompt:t,title:r}=e;t=t||"~$";const o={custom:{themeBGColor:"rgb(41, 45, 62)",themeToolbarColor:"#ffffff1a",themeColor:"rgb(191, 199, 213)",themePromptColor:"rgb(130, 170, 255)"}},l=e=>(0,s.jsx)("span",{style:{color:o.custom.themePromptColor,WebkitUserSelect:"none",KhtmlUserSelect:"none",MozUserSelect:"none",msUserSelect:"none",OUserSelect:"none",userSelect:"none"},children:e}),d=(0,s.jsx)("span",{style:{whiteSpace:"pre-wrap"},children:n.map(((e,n)=>(0,s.jsxs)("span",{children:[l(e.prompt?e.prompt:t)," ",(0,s.jsx)("span",{children:Array.isArray(e.input)?e.input.map(((e,n)=>(0,s.jsxs)("span",{children:[e," ",(0,s.jsx)("br",{})]},n))):(0,s.jsxs)("span",{children:[" ",e.input," ",(0,s.jsx)("br",{})]})}),e.output&&e.output.map(((e,n)=>(0,s.jsxs)("span",{children:[e," ",(0,s.jsx)("br",{})]},n)))]},n)))}),a={display:"inline-block",width:"10px",float:"left",height:"10px",background:"#f9f9f9",borderRadius:"50%",margin:"8px 4px 0 0"};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{style:{width:"100%",borderRadius:"7px 7px 7px 7px",WebkitBoxShadow:"rgba(0, 0, 0, 0.3) 0 1px 3px",MozBoxShadow:"rgba(0,0,0,0.3) 0 1px 3px",BoxShadow:"rgba(0, 0, 0, 0.3) 0 1px 3px",WebkitFontSmoothing:"antialiased",textRendering:"optimizelegibility"},children:(0,s.jsx)("div",{style:{width:"100%",position:"relative",WebkitBoxSizing:"border-box",borderRadius:"7px 7px 7px 7px"},children:(0,s.jsxs)("div",{style:{background:"rgb(244,244,239)",width:"100%",borderRadius:"7px 7px 7px 7px"},children:[(0,s.jsxs)("div",{style:{height:"25px",padding:"0px 10px",color:"#4d494d",textAlign:"center",fontFamily:"HelveticaNeue, 'Helvetica Neue', 'Lucida Grande', Arial, sans-serif"},children:[(0,s.jsx)("div",{style:{...a,background:"#FF6057",border:"1px solid #E14640"}}),(0,s.jsx)("div",{style:{...a,background:"#FFBD2E",border:"1px solid #DFA123"}}),(0,s.jsx)("div",{style:{...a,background:"rgba(218, 218, 213)",border:"1px solid rgba(203, 203, 196)"}}),(0,s.jsx)("div",{style:{height:"10px",textAlign:"center",fontSize:14,opacity:.75,WebkitFontSmoothing:"antialiased",textRendering:"optimizelegibility"},children:r&&(0,s.jsx)(s.Fragment,{children:r})})]}),(0,s.jsx)("div",{style:{width:"100%",background:"rgb(41,45,62)",margin:"0px auto",borderRadius:"0px 0px 7px 7px",padding:"7px 7px 7px",position:"relative",WebkitBoxSizing:"border-box",boxSizing:"border-box"},children:(0,s.jsx)(i.XL,{children:(0,s.jsx)(i.e,{prompt:t,theme:"custom",themes:o,showControlButtons:!1,welcomeMessage:d,enableInput:!1,showControlBar:!1})})})]})})}),(0,s.jsx)("br",{})]})}},8453:(e,n,t)=>{t.d(n,{R:()=>o,x:()=>l});var i=t(6540);const s={},r=i.createContext(s);function o(e){const n=i.useContext(r);return i.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function l(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:o(e.components),i.createElement(r.Provider,{value:n},e.children)}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.