# cksteppe

> Step by step math solutions

Latest version **0.0.1** (published 2022-08-01) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install cksteppe
pnpm add cksteppe
yarn add cksteppe
bun add cksteppe
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.1 |
| Published | 2022-08-01 |
| First published | 2022-08-01 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=6.0.0 |
| Dependencies | 2 |
| Unpacked size | 359.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Evy Kassirer |
| Maintainers | jappends |
| Keywords | math, steps, algebra, cas, computer, algebra, system |

## Links

- npm: https://www.npmjs.com/package/cksteppe
- Repository: https://github.com/cksteppe/cksteppe
- Homepage: https://github.com/kemu-studio/mathsteps#readme
- Issues: https://github.com/kemu-studio/mathsteps/issues
- npm.io page: https://npm.io/package/cksteppe

## Dependencies (2)

- [mathjs](https://npm.io/package/mathjs.md) ^7.5.1
- [npm-check-updates](https://npm.io/package/npm-check-updates.md) ^9.1.2

## Alternatives

- [@mce/gif](https://npm.io/package/@mce/gif.md) — 2.6K weekly downloads
- [cleanse](https://npm.io/package/cleanse.md) — 173 weekly downloads
- [str](https://npm.io/package/str.md) — 127 weekly downloads
- [naming](https://npm.io/package/naming.md) — 95 weekly downloads
- [tap-telco-api](https://npm.io/package/tap-telco-api.md) — 19 weekly downloads

## Recent versions

- 0.0.1 (latest) — 2022-08-01

## README

# Mathsteps - A step by step solver for math

[![CircleCI](https://circleci.com/gh/kemu-studio/mathsteps.svg?style=svg)](https://app.circleci.com/pipelines/github/kemu-studio/mathsteps.svg)
[![Git Commit](https://img.shields.io/github/last-commit/kemu-studio/mathsteps.svg?style=flat)](https://github.com/kemu-studio/mathsteps/commits/master)

# Demo ![Calculla.com](https://calculla.com/g/calculla_logo_small_32.png)

To see this version of mathsteps in action go to [calculla.com](https://calculla.com). For example it's used in [Sum of angles calculator](https://calculla.com/sum_of_angles_in_triangle), so you can put something like "1/3 pi" into alpha and beta angles and it will show you all steps needed to achieve "1/3 pi" result.

## Requirements

Mathsteps requires Node version > 6.0.0

## Usage

To install mathsteps using npm:

    npm install mathsteps

```js
const mathsteps = require('mathsteps');

const steps = mathsteps.simplifyExpression('2x + 2x + x + x');

steps.forEach(step => {
        console.log("before change: " + step.oldNode.toString());   // before change: 2 x + 2 x + x + x
        console.log("change: " + step.changeType);                  // change: ADD_POLYNOMIAL_TERMS
        console.log("after change: " + step.newNode.toString());    // after change: 6 x
        console.log("# of substeps: " + step.substeps.length);      // # of substeps: 3
});
```

To solve an equation:
```js
const result = mathsteps.solveEquation({
  equationAsText: '2x + 3x = 35',
  unknownVariable: 'x',
  onStepCb: function(step) {
    console.log(`[ ${step.equation.getId()} ] ${step.stepId} | ${step.equation}`)
  }
})
```

(if you're using mathsteps v0.1.6 or lower, use `.print()` instead of `.ascii()`)

To see all the change types:
```js
const changes = mathsteps.ChangeTypes;
```

## Contributing

Hi! If you're interested in working on this, that would be super awesome!
Learn more here: [CONTRIBUTING.md](CONTRIBUTING.md).

## Build

First clone the project from github:

    git clone https://github.com/socraticorg/mathsteps.git
    cd mathsteps

Install the project dependencies:

    npm ci

## Test

To execute tests for the library, install the project dependencies once:

    npm ci

Then, the tests can be executed:

    npm test

---
_Source: https://npm.io/package/cksteppe · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
