dart_math 0.0.9

  • README.md
  • CHANGELOG.md
  • Example
  • Installing
  • Versions
  • new59

DartMath

A simple dart Math Library

0.0.1

  • Initial version, created by Stagehand

example/main.dart

import 'package:dart_math/algebra.dart';
import 'package:dart_math/dart_math.dart';
main(List<String> arguments) {
  //Intantiate a Fraction Object
  Fraction fractions = new Fraction(3.0, 2.0);
  Fraction fractions1 = new Fraction(5.0, 4.0);
  Fraction fractions2 = new Fraction(5.0, 2.0);
  Fraction sumfrac = fractions.fracAdd(fractions1).fracAdd(fractions2);

//get nominator,denominator, quotient,remainder;
  print(
      'Nominator: ${sumfrac.nominator()} Denominator ${sumfrac.denominator()}');
  print('This is quotient ${sumfrac.quotient()}');
  print('This is remainder ${sumfrac.remainder()}');

  // //Intantiate Line Object
  Line l1 = new Line(y: 1.0, gradient: 2.0, intercept: 3.0);
  Line l2 = new Line(y: 1.0, gradient: -0.5, intercept: 7.0);
  Line l3 = new Line(y: 1.0, gradient: 2.0, x: 1.0);

//Intanciate Cordinates Object
  Cordinates p1 = new Cordinates(x:1.0, y:1.0);
  Cordinates p2 = new Cordinates(x:2.0, y:3.0);

  print('This is distance ${p1.getdistance(p2)}');
  print('This is Slope ${p1.getslope(p2)}');
  print('This is y intercept ${l3.getyintercept()}');

  Cordinates inter;
  Map<String, double> cord;
  //get intersection of two lines
  inter = l1.intersection(l2);
  print(l1.intersection(l2).toLine(p1).intersection(l3));
  cord = inter.getcordinates();
  print('These Lines intersect at $cord');



  //Startof Algebra
  Quadratic quadratic = new Quadratic(2.0, -1.0, -1.0);
  print(quadratic.discriminant());
  print(quadratic.roots());
}

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  dart_math: ^0.0.9

2. Install it

You can install packages from the command line:

with pub:


$ pub get

with Flutter:


$ flutter packages get

Alternatively, your editor might support pub get or flutter packages get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:dart_math/dart_math.dart';
  
Version Uploaded Documentation Archive
0.0.9 Aug 25, 2018 Go to the documentation of dart_math 0.0.9 Download dart_math 0.0.9 archive
0.0.8 Aug 25, 2018 Go to the documentation of dart_math 0.0.8 Download dart_math 0.0.8 archive
0.0.7 Aug 23, 2018 Go to the documentation of dart_math 0.0.7 Download dart_math 0.0.7 archive
0.0.6 Aug 21, 2018 Go to the documentation of dart_math 0.0.6 Download dart_math 0.0.6 archive
0.0.5 Aug 21, 2018 Go to the documentation of dart_math 0.0.5 Download dart_math 0.0.5 archive
0.0.4 Aug 21, 2018 Go to the documentation of dart_math 0.0.4 Download dart_math 0.0.4 archive
0.0.3 Aug 21, 2018 Go to the documentation of dart_math 0.0.3 Download dart_math 0.0.3 archive
0.0.2 Aug 21, 2018 Go to the documentation of dart_math 0.0.2 Download dart_math 0.0.2 archive
0.0.1 Aug 21, 2018 Go to the documentation of dart_math 0.0.1 Download dart_math 0.0.1 archive
Popularity:
Describes how popular the package is relative to other packages. [more]
29
Health:
Code health derived from static analysis. [more]
100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
70
Overall:
Weighted score of the above. [more]
59
Learn more about scoring.

We analyzed this package on Sep 18, 2018, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.0.0
  • pana: 0.12.3

Platforms

Detected platforms: Flutter, web, other

No platform restriction found in primary library package:dart_math/dart_math.dart.

Suggestions

The description is too short.

Add more detail about the package, what it does and what is its target use case. Try to write at least 60 characters.

Package is pre-v0.1 release.

While there is nothing inherently wrong with versions of 0.0.*, it usually means that the author is still experimenting with the general direction of the API.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK 2.0.0
Dev dependencies
test ^1.3.0