symengine.rb icon indicating copy to clipboard operation
symengine.rb copied to clipboard

Rubyfication

Open rajithv opened this issue 9 years ago • 2 comments

For better intuitiveness for Ruby users, some SymEngine constructs can be changed.

@zverok Let's add such instances to a list here.

  • [ ] Basic#to_proc instead of SymEngine::lambdify(basic)
  • [ ] Map SymEngine::Symbol to Ruby Symbols. ( x = SymEngine(:x) )

rajithv avatar Jul 21 '16 03:07 rajithv

About first, I still think the name should be to_proc.

lambdify could be an alias (for those knowing SymEngine better than Ruby), but for this case (matching Python API?..) it should be left as SymEngine::lambdify. So, what I propose here is:

  • leave SymEngine::lambdify but explicitly state that Basic#to_proc is preferred;
  • make Basic#to_proc to be able to do everything SymEngine::lambdify could do.

WDYT?

zverok avatar Jul 21 '16 07:07 zverok

Yep. That's better. Updated the checklist to reflect that.

rajithv avatar Jul 21 '16 08:07 rajithv