Skip to content

fixed the rounding problem .5-.55 for remaining field calculations #107

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

Merged
merged 1 commit into from
Apr 26, 2019

Conversation

OrtnerMichael
Copy link
Member

fixes the 0.5-0.55 problem for remaining Bfield-calcualtions (Cylinder, circular). idea: the field evaluates as NaN with rounding to 1e-15 ... except for the current line....but users can figure this one out...

@OrtnerMichael OrtnerMichael merged commit d2b205f into development Apr 26, 2019
@OrtnerMichael OrtnerMichael deleted the fixFieldRoundingProblem branch April 26, 2019 08:14
OrtnerMichael added a commit that referenced this pull request Apr 26, 2019
* Update getBsweep for collection (#89)

- Remove Displacement Input for getBsweep in Collection
    - Add multiprocessing disable flag
    - Add tests

* Complete replacement of the PM_Box field with fixed and fast version (#91)

* fixed all remaining fields, no more singularities, all magnet surfaces and all positions directly on currents give NaN (#97)

* Fix Line not accepting numpy array for vertices #98 (#99)

- Add two numpy array cases for
      valid input
    - Add test
    - Add test comments

* Solidify Testing Harness (#100)

* added testing examples for field calculations and basic classes

* Add PMBox inside/Outside tests

* Add currentLine field outside test

* Add error message to Collection

* Add fundamental current loop field tests

* Add fundamental current line field tests

* Add fundamental magnet loop field tests

* Add fundamental moment dipole field tests

* Add rotation and rotation+getB tests for Currents

* Add rotation and rotation+getB tests for magnets

* Add rotation and rotation+getB tests for moments

* Add edge, corner, face tests for Cube
    - Fixed BfieldBox_inside to match
      inside tests rather than corners

* Add currentLine segment, middle and line tests

* Add singularity catch test cases to Cylinder, Sphere

* Add singularity catch test cases to Currents

* Add singularity catch test cases to Dipole

* Add mixed input, duplicate warning, removal and
motion tests to Collection #95
    - Added comments to other tests

* Add rotation,translation and setPosition/Orientation tests for RCS #94

    - Add comments to RCS tests
    - Remove duplicate tests

* Add public math package tests

* fix bug in type testing for base
   - Was not picking up on faulty axis
     definitions

* Add missing edge test to Cylinder field

* Add import of current and magnet source for test coverage

* Add reachable "bad Angle" systemerror catch for base
     - Add tests for most catches

* Remove redudant pos argument from currentLine test

* Remove very old code block from collection
    - Multicore remains, moved to getBsweep

* Remove old, unused utility functions

* Add test for adding a list while duplicate warnings are off.

* Fixed the small digits problem. when sweepin additions like .5-.55 give .0500000000000000012 which results in non-special case evaluation. However, the square then kills the small digit resulting in a 1/0 (#104)

* fixed the rounding problem .5-.55 for remaining field calculations (#107)

* Missing tests (#106)

* added testing examples for field calculations and basic classes

* Add PMBox inside/Outside tests

* Add currentLine field outside test

* Add error message to Collection

* Add fundamental current loop field tests

* Add fundamental current line field tests

* Add fundamental magnet loop field tests

* Add fundamental moment dipole field tests

* Add rotation and rotation+getB tests for Currents

* Add rotation and rotation+getB tests for magnets

* Add rotation and rotation+getB tests for moments

* Add edge, corner, face tests for Cube
    - Fixed BfieldBox_inside to match
      inside tests rather than corners

* Add currentLine segment, middle and line tests

* Add singularity catch test cases to Cylinder, Sphere

* Add singularity catch test cases to Currents

* Add singularity catch test cases to Dipole

* Add mixed input, duplicate warning, removal and
motion tests to Collection #95
    - Added comments to other tests

* Add rotation,translation and setPosition/Orientation tests for RCS #94

    - Add comments to RCS tests
    - Remove duplicate tests

* Add public math package tests

* fix bug in type testing for base
   - Was not picking up on faulty axis
     definitions

* Add missing edge test to Cylinder field

* Add import of current and magnet source for test coverage

* Add reachable "bad Angle" systemerror catch for base
     - Add tests for most catches

* Remove redudant pos argument from currentLine test

* Remove very old code block from collection
    - Multicore remains, moved to getBsweep

* Remove old, unused utility functions

* Add test for adding a list while duplicate warnings are off.

* Add missing tests for Cylinder

* Add missing tests for CurrentLoop

* Add comment to getB_raw test

* Modify rounding edge case in Box class
OrtnerMichael pushed a commit that referenced this pull request May 13, 2019
*  Add Sphinx settings for Rst + Markdown
    - These settings allow you to use rST and
       Markdown in the same file.
    - This is useful so one can use rST directives like
       the class and method links

* Add getting started manual stub

* Add first logo iteration to repository

* Add autoplot of figures to guide, separate code

* Update installation instructions

* Update examples to autoplot

* Update installation examples

* Organize static file structure, add install images

* Add source summary, moved image on summary

* Add smoothing for pages, update install page

* Scale down static images for summary and init

* Add fundamentals page

* Change Library Contents to Library Docstrings, Reorder Index

* Remove About Subheader from index.rst

* Add examples for Source Objects

* Fix broken link to Examples in install guide

* Add input types table, add output display to scripts

* Give examples its own folder in pyplot folder

* Add output to collection comments

* Fix grammar in example comments

* Add animations to fundamentals, add more stuff to guide

* Update fundamentals with more images

* Add link to quaternions

* Add an unhealthy amount of code examples to Getting Started

* Update axis information in manipulation title (X and Y were swapped)

* Add multiprocess example

* Add direction arrows  to currents in example

* Add getBsweep for displacement

* Development (#108)

* Update getBsweep for collection (#89)

- Remove Displacement Input for getBsweep in Collection
    - Add multiprocessing disable flag
    - Add tests

* Complete replacement of the PM_Box field with fixed and fast version (#91)

* fixed all remaining fields, no more singularities, all magnet surfaces and all positions directly on currents give NaN (#97)

* Fix Line not accepting numpy array for vertices #98 (#99)

- Add two numpy array cases for
      valid input
    - Add test
    - Add test comments

* Solidify Testing Harness (#100)

* added testing examples for field calculations and basic classes

* Add PMBox inside/Outside tests

* Add currentLine field outside test

* Add error message to Collection

* Add fundamental current loop field tests

* Add fundamental current line field tests

* Add fundamental magnet loop field tests

* Add fundamental moment dipole field tests

* Add rotation and rotation+getB tests for Currents

* Add rotation and rotation+getB tests for magnets

* Add rotation and rotation+getB tests for moments

* Add edge, corner, face tests for Cube
    - Fixed BfieldBox_inside to match
      inside tests rather than corners

* Add currentLine segment, middle and line tests

* Add singularity catch test cases to Cylinder, Sphere

* Add singularity catch test cases to Currents

* Add singularity catch test cases to Dipole

* Add mixed input, duplicate warning, removal and
motion tests to Collection #95
    - Added comments to other tests

* Add rotation,translation and setPosition/Orientation tests for RCS #94

    - Add comments to RCS tests
    - Remove duplicate tests

* Add public math package tests

* fix bug in type testing for base
   - Was not picking up on faulty axis
     definitions

* Add missing edge test to Cylinder field

* Add import of current and magnet source for test coverage

* Add reachable "bad Angle" systemerror catch for base
     - Add tests for most catches

* Remove redudant pos argument from currentLine test

* Remove very old code block from collection
    - Multicore remains, moved to getBsweep

* Remove old, unused utility functions

* Add test for adding a list while duplicate warnings are off.

* Fixed the small digits problem. when sweepin additions like .5-.55 give .0500000000000000012 which results in non-special case evaluation. However, the square then kills the small digit resulting in a 1/0 (#104)

* fixed the rounding problem .5-.55 for remaining field calculations (#107)

* Missing tests (#106)

* added testing examples for field calculations and basic classes

* Add PMBox inside/Outside tests

* Add currentLine field outside test

* Add error message to Collection

* Add fundamental current loop field tests

* Add fundamental current line field tests

* Add fundamental magnet loop field tests

* Add fundamental moment dipole field tests

* Add rotation and rotation+getB tests for Currents

* Add rotation and rotation+getB tests for magnets

* Add rotation and rotation+getB tests for moments

* Add edge, corner, face tests for Cube
    - Fixed BfieldBox_inside to match
      inside tests rather than corners

* Add currentLine segment, middle and line tests

* Add singularity catch test cases to Cylinder, Sphere

* Add singularity catch test cases to Currents

* Add singularity catch test cases to Dipole

* Add mixed input, duplicate warning, removal and
motion tests to Collection #95
    - Added comments to other tests

* Add rotation,translation and setPosition/Orientation tests for RCS #94

    - Add comments to RCS tests
    - Remove duplicate tests

* Add public math package tests

* fix bug in type testing for base
   - Was not picking up on faulty axis
     definitions

* Add missing edge test to Cylinder field

* Add import of current and magnet source for test coverage

* Add reachable "bad Angle" systemerror catch for base
     - Add tests for most catches

* Remove redudant pos argument from currentLine test

* Remove very old code block from collection
    - Multicore remains, moved to getBsweep

* Remove old, unused utility functions

* Add test for adding a list while duplicate warnings are off.

* Add missing tests for Cylinder

* Add missing tests for CurrentLoop

* Add comment to getB_raw test

* Modify rounding edge case in Box class

* working on doku2

* add images/sourceBasics

* doku

* doku

* mmm

* doku

* doku

* doku

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* 'doku'

* Fix image path for Guide after page structure adjustment

* 'doku'

* fix path for install images

* fix path for examples file

* Add new explanation gifs

* 'doku'

* 'doku'

* 'doku'

* doku

* doku

* Update documentation gifs for manipulation functions

* 'doku'

* finish documentation, adjust image paths

* 'doku'

* doku

* doku

* doku

* doku

* doku

* doku

* Fix warnings in directory structure update

* doku

* Add sweep input visualization

* doku

* test doku vector graphics

* Change "Class Variables" to "Attribute/Property"

* Update Collection section

    - Add note about getB sweep
    - List kwargs for displaySystem
    - Fix typo

* Update Markdown TOC in documentation document

* use source_vars_methos svg image

* fix typo in figure

* Add matlab example

* Add matlab TOC,  add install to hidden section

* Fix broken example in displaySystem docstring

* Add multiprocessing guard to example in guide

* Fix misspelling in matlab example

* fix weird characters in matlab script

* Fix line length on index

* Add Readme info and Windows make script

* Add tests readme

* Add input reference to readme

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Add SAL logo

* Remove wrong info about magnet interaction

* Update collection docstring

* Add developer guide drafts

* Update dev guide, getting started
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants