Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DRAFT: Python implementation of cobyla #37

Draft
wants to merge 6 commits into
base: main
Choose a base branch
from

Commits on Sep 20, 2023

  1. Initial commit of Python translation

    calcfc_chebyqud and calcfc_hexagon in Python return values close to what is returned by Fortran,
    but not exactly the same and the difference is outside of machine precision.
    
    For chebyquad the fortran version iterates 387 times within cobylb, whereas
    the Python version iterates 564 times. The results are as follows
    
    Fortran:
    x(1) = 0.06687201625695266
    x(2) = 0.28872054433564054
    x(3) = 0.36668681233017669
    x(4) = 0.63330363432938008
    x(5) = 0.71126615229302259
    x(6) = 0.93312277720964698
    f = 3.9135366518694255e-10
    
    Python:
    x[0] = 0.06688196439284098
    x[1] = 0.2887610493288529
    x[2] = 0.36668226015206873
    x[3] = 0.6333320849097046
    x[4] = 0.7112583722245663
    x[5] = 0.9331254078707577
    f = 3.8259601181730434e-10
    
    The first position in x differs by 9.948135888e-6, so it's further away than machine precision, but
    it's possible that the difference is the result of accumulation of machine precision errors.
    nbelakovski committed Sep 20, 2023
    Configuration menu
    Copy the full SHA
    8e536e1 View commit details
    Browse the repository at this point in the history

Commits on Sep 22, 2023

  1. rearranging some stuff

    nbelakovski committed Sep 22, 2023
    Configuration menu
    Copy the full SHA
    40f7da9 View commit details
    Browse the repository at this point in the history

Commits on Sep 26, 2023

  1. Added a readme with some style guidelines.

    Implemented savehist and modified the return values to be more usable.
    
    I've gone through cobyla.py and it seems pretty close to the original.
    
    Remaining work is to implement retmsg and to add in all pre/post conditions
    and retrofit existing pre/post conditions to match the style guide.
    
    Then we're ready for a deeper conversation on whether any of this is useful XD
    nbelakovski committed Sep 26, 2023
    Configuration menu
    Copy the full SHA
    b233dfa View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    0b6108a View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    52d5647 View commit details
    Browse the repository at this point in the history

Commits on Sep 28, 2023

  1. Adding Python action

    nbelakovski committed Sep 28, 2023
    Configuration menu
    Copy the full SHA
    1095cc1 View commit details
    Browse the repository at this point in the history