Skip to main content

Python framework for MYSTRAN validation

Project description

MYSTRAN validation

https://img.shields.io/pypi/v/mystran_validation.svg Documentation Status

Python framework for MYSTRAN validation

Features

Limitations

  • for now, only [a few vectors](#vectors) are implemented

  • Mystran results are based on .NEU result file, therefore, somewhere limited with available results. Plan is to migrate to OP2 parsing once it will have been developped.

Vectors

Currently implemented vectors:

  • Displacements (3 translations, 3 rotations)

  • Reactions (6-dof reactions)

A declarative Framework

mystran_validation is a python declarative framework dedicated to MYSTRAN test cases.

declarative means that end-user do not need to know python at-all. Test cases are declared as ini text files, pointing to relevant files, and describing the test itself.

Example:

[DEFAULT]
title = test 00
bulk = bulk_model.nas
reference = test_case_03.op2

[Checking Displs]
# we check all nodes displacements
description = check all displacements
vector = displacements

[Reactions]
# we check all nodes displacements
description = this is a multi-lines
        description
vector = reactions

The above configuration file describes two tests performed on bulk_model.nas (named “Checking Displs”). This test will check all displacements and all ractions against test_case_03.op2 file.

A flexible framework

Event though [many limitations] still remain, the framework features:

### tolerance management

The above example may be tweaked as follows:

[...]

[Displacements]
# we check all nodes displacements
description = check all displacements
vector = displacements
## we can reduce / increase tolerance
rtol = 1e-05 # default relative tolerance
atol = 1e-08 # default absolute tolerance

### checking data subset

Data subset can be checked by specifying gids, SubcaseIDs:

[...]

[Displacements]
# we check all nodes displacements
description = check all displacements
vector = displacements
## we can restrict checked data:
gids = 1, 2
SubcaseIDs = 1,2

### Manual references

Beside reference results file, one can specify a value by-hand as follows:

[Displacements II]
description = Check one single value
vector = displacements
## restrict check to MYSTRAN subset:
gids = 1
SubcaseIDs = 2
axis = 6
reference = 0.00513
atol = 1e-06

History

0.1.0 (2021-05-17)

  • First release on PyPI.

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

mystran_validation-0.1.0.tar.gz (34.4 kB view hashes)

Uploaded Source

Built Distribution

mystran_validation-0.1.0-py2.py3-none-any.whl (11.9 kB view hashes)

Uploaded Python 2 Python 3

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