Skip to main content

Reduce monomial basis for SDP computations for ROM of Rayleigh–Bénard convection.

Project description

ReduceMonomsRBC

ReduceMonomsRBC is a Python package that reduces the list of monomials for sum-of-squares (SOS) optimization of reduced-order models (ROMS). The monomials are reduced by applying highest-degree cancellation and symmetry conditions derived from the structure of the ROM. This package is built for ROMs of 2D Rayleigh–Bénard convection, but can be adapted to any ROM whose general structure is known.

Features:

  • Reduce list of monomials and save list for use in SOS optimization
  • Generate ouptut file with number of monomials at each reduction step.

Package Requirements

  • numpy (Version 1.5 or later)
  • sympy (Version 1.6 or later)
  • csv (any version)
  • scipy (Version 0.10 or later)

Installation

To install the package, either:

  • download or clone this repository and use from ReduceMonomsRBC import monom_reduction from the directory containing the package, OR
  • install package directly using pip install ReduceMonomsRBC then from ReduceMonomsRBC import monom_reduction

Instructions

To construct a system of ROMs, use the command monom_reduction(*args). Options can be passed as function arguments as detailed below.

Options:

  • ode_name : Name of ODE
  • num_vars : Number of variables in ODE
  • monom_deg : Maximum degree of auxilary functions. Typically an even number
  • hk_hier : If True, uses HK hierarchy for Rayleigh–Bénard
  • hier_num : Model number in the HK hierarchy. Only matters if hk_hier=True
  • monom_stats : If True, outputs stats on number of monomials after each step
  • out_file : Name of output file
  • out_dir : Specify output directory

Examples:

monom_reduction('HK4', 4, 6, hk_hier=True, hier_num=1)
Generates and reduces list of monomials of degree 6 for the HK4 model (in the HK hierarchy of ROMs)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ReduceMonomsRBC-0.2.tar.gz (9.8 kB view details)

Uploaded Source

Built Distribution

ReduceMonomsRBC-0.2-py3-none-any.whl (11.5 kB view details)

Uploaded Python 3

File details

Details for the file ReduceMonomsRBC-0.2.tar.gz.

File metadata

  • Download URL: ReduceMonomsRBC-0.2.tar.gz
  • Upload date:
  • Size: 9.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.8.3

File hashes

Hashes for ReduceMonomsRBC-0.2.tar.gz
Algorithm Hash digest
SHA256 053cbfc73f3d0f39151d7ce173c37ef3f4a83346d0de395e332d6b4eb13d8884
MD5 0668d59389532601b3b3cf50b5f2b42c
BLAKE2b-256 3501ad568c34e355d6f4d09477673e681d32ede7e3a2c3599cbbb5d5f7ea2c71

See more details on using hashes here.

File details

Details for the file ReduceMonomsRBC-0.2-py3-none-any.whl.

File metadata

  • Download URL: ReduceMonomsRBC-0.2-py3-none-any.whl
  • Upload date:
  • Size: 11.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.8.3

File hashes

Hashes for ReduceMonomsRBC-0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 3668e31f863e0450ac1d8fdc0d554f71b32d8c064db9e73a1a59c38f4dbd71f4
MD5 7402f3e59698e1e283c7bc57b49a3076
BLAKE2b-256 02ea4d2fd709972dbc8f7f356540815c55602621dcb7108c6131e32c021acead

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page