Code Monkey home page Code Monkey logo

slope-field's Introduction

slope-field Open Source Society University - Data Science

I was studying this course on Integration when I encountered slope fields and I found them interesting!

So I thought I would give it a shot and try to write a program to draw slope fields myself! In order to read a mathematical function definition from input, I wrote mathexpr.

Get Started

If you haven't already, install Haskell Platform.

git clone https://github.com/mdibaiee/slope-field
cd slope-field
stack install
slope-field

Examples

Parameters:

  • dy/dx: derivative of the function you are trying to visualize
  • range: range of numbers to draw
  • estimation size: size of deltax which is used to draw the slope corresponding to a small point, 0.03 is usually a good number, but you might want to try out larger numbers to get a more detailed picture on some examples
dy/dx = 
x + y
range - format: (lower, upper): 
(-10, 10)
estimation size: 
0.03

x plus y

dy/dx = 
x * y
range - format: (lower, upper): 
(-10, 10)
estimation size: 
0.03

x times y

dy/dx = 
-y
range - format: (lower, upper): 
(-10, 10)
estimation size: 
0.03

minus y

dy/dx = 
y/x
range - format: (lower, upper): 
(-20, 20)
estimation size: 
0.1

y divided by x

slope-field's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  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.