Code Monkey home page Code Monkey logo

ralpha's Introduction

Ralpha – accessing the Wolfram|Alpha api with ruby with lots of KISS


  puts Ralpha["pi"]

  Query 'pi' Success=true
   > Input
    : pi {Image:true}
   > Decimal approximation [More digits]
    : 3.1415926535897932384626433832795028841971693993751058209749... {Image:true}
   > Property
    : pi is a transcendental number {Image:true}
   > Continued fraction [Fraction form, More terms]
    : [3; 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, ...] {Image:true}
   > Alternative representations [More]
    : pi = 180 ° {Image:true}
    : pi = -i log(-1) {Image:true}
    : pi = cos^(-1)(-1) {Image:true}
      should a have nice inspect

  puts Ralpha["pi"].pods[1].states.first.subquery

  Query [DecimalApproximation__More digits] Success [true]
   > Input
    : pi {Image:true}
   > Decimal approximation [Fewer digits, More digits]
    : 3.141592653589793238462643383279502884197169399375105820974944592307816406286208998628034825342117067982148086513282... {Image:true}
   > Property
    : pi is a transcendental number {Image:true}
   > Number line
    :  {Image:true}
   > Continued fraction [Fraction form, More terms]
    : [3; 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, 1, 1, 2, 2, 2, 2, 1, 84, 2, 1, 1, ...] {Image:true}
   > Alternative representations [More]
    : pi = 180 ° {Image:true}
    : pi = -i log(-1) {Image:true}
    : pi = cos^(-1)(-1) {Image:true}
   > Series representations [More]
    : pi = 4 sum_(k=0)^infinity(-1)^k/(2 k+1) {Image:true}
    : pi = -2+2 sum_(k=1)^infinity2^k/(2 k
  k) {Image:true}
    : pi = sum_(k=0)^infinity(50 k-6)/(2^k (3 k
  k)) {Image:true}
   > Integral representations [More]
    : pi = 2 integral_0^infinity1/(t^2+1) dt {Image:true}
    : pi = 4 integral_0^1sqrt(1-t^2) dt {Image:true}
    : pi = 2 integral_0^infinity(sin(t))/t dt {Image:true}
      should return a new Query instance on #query

This is Alpha code and will not work.

ralpha's People

Contributors

entropie avatar

Stargazers

Joosa Riekkinen avatar  avatar

Watchers

James Cloos avatar

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.