README.md in dydx-0.0.7 vs README.md in dydx-0.0.8
- old
+ new
@@ -1,32 +1,55 @@
# Dydx
It always happens you want to differentiate with ruby. right?
Dydx will eliminate this. Like this
+
```
-( d/dx(e ^ :x) ).to_s
+( d/dx(:x ^ 2) ).to_s
+=> "( 2 * x )"
+
+# pretermit '#to_s'
+
+d/dx(e ^ :x)
=> "( e ^ x )"
+d/dz(log(:z))
+=> "( 1 / z )"
+
+d/dx(:x^:n)
+=> "( n * ( x ^ ( n - 1 ) ) )"
+
+```
+
+you can do like ``` dy/dx ```, if you use global var.
+
+```
$y = cos(:x)
-(dy/dx).to_s
+dy/dx
=> "( - sin( x ) )"
-# pretermit '.to_s'
+$x = :a * ( (:t ^ 2) / 2 )
+dx/dt
+=> "( a * t )"
-d/dx(log(:x))
-=> "( 1 / x )"
+d/dt(dx/dt)
+=>"a"
-d/dx(:x^:n)
-=> "( n * ( x ^ ( n - 1 ) ) )"
+```
+you can use method chaining.
-d/dx(:x^2)
-=> "( 2 * x )"
+```
+((:x ^ 2) * :y).d(:x)
+=> "( ( 2 * x ) * y )"
+((:x ^ 2) * :y).d(:x).d(:y)
+=> "( 2 * x )"
```
-(That's wonderful!!!!! But, I feel there is no meaning ... )
+
+(That's wonderful!!!!! ..............)
## Installation
Add this line to your application's Gemfile: