Giter Site home page Giter Site logo

polynomialmagic's Introduction

Polynomial Magic

Showing how to get whatever radius you like from a single set of charge form factor pseudo data.

Testing whether from a single randomly generated set of data one can always find the proton radius you want if you scan with high order polynomials. The radius is determined by taking the slope of the function at zero as it done with charge form factor data.

code outline

  • generate ONE set of equal spaced random data with 1000 points from 0.01 to 10 fm$^{-2}$ using standard dipole and 0.003 random errors
  • ask user to pick a proton radius from 0.70 to 0.92 fm
  • loop over polynomial functions to see if we find the result we want
  • it fails, drop one low q2 data point and try again
  • repeat until we find at polynomial that will give the answer we want

bonus code

  • float the normalizing of the "rejected" low q2 data and then show all the data now gives a great fit

Example Out

For the example figure, data is generated with standard dipole (0.81fm radius) and then a 0.90fm radius is requested. Using a high order polynomial and a floating normalization gives the requested radius.

As shown in the notebook, if one then fits the renormalized data with the high order polynomial it makes a beautiful fit of all 1000 points.

DOI

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.