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

Propagate uncertainty for any function #4

Closed
giordano opened this issue Jun 9, 2016 · 0 comments
Closed

Propagate uncertainty for any function #4

giordano opened this issue Jun 9, 2016 · 0 comments

Comments

@giordano
Copy link
Member

giordano commented Jun 9, 2016

Currently the package defines error propagation rules for known functions, but it would be great to allow for calculation of uncertainties of arbitrary functions.

This should be possible with a macro like

@macroname function(4.3 ± 0.4)

This calculates the value of function(4.3) and the associated approximated uncertainty using numerical derivatives or so, and finally construct the Measurement object function(4.3) ± uncertainty.

giordano added a commit that referenced this issue Jun 13, 2016
Limitation: function must take only one real argument.

The derivative is calculated using Calculus package.  We need numerical
derivatives because we want to support any possible function, not only
those implemented in Julia, so I don’t think automatic differentiation
is an option in this case.

Fixes issue #4.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant