On Thu, Jul 9, 2009 at 9:15 AM, Christophe<[email protected]> wrote:
> Hello,
> I send you the module I've made for working with unions and
> intersections of intervals. For the moment this module only works with
> integer and not with sympy "numbers" (I haven't tested it yet).
> I know that my code is uggly and with a lot of mispealings. I also know
> that I need to do some doctest. Can you give me an example of a module
> of sympy with a good doctest ?
Well, we are still working on it, but look for example into
sympy/core/basic.py, then run:
$ bin/coverage_doctest.py sympy/core/basic.py
----------------------------------------------------------------------
sympy/core/basic.py
Missing documentation:
* is_hypergeometric(self, k)
* is_polynomial(self, *syms)
* search(expr)
* search(expr)
* conjugate(self)
* removeO(self)
* getO(e)
* as_powers_dict(self)
* as_base_exp(self)
* as_coeff_terms(self, x=None)
* as_coeff_factors(self, x=None)
* as_numer_denom(self)
* normal(self)
* diff(self, *symbols, **assumptions)
* fdiff(self, *indices)
* integrate(self, *args, **kwargs)
* pattern_match(pattern, expr, repl_dict)
* as_numer_denom(self)
* count_ops(self, symbolic=True)
* doit(self, **hints)
* is_number(self)
* cls_new(cls)
* cls_getnewargs(self)
Missing doctests:
* solve4linearsymbol(eqn, rhs, symbols = None)
* expand(self, deep=True, power_base=True, power_exp=True, mul=True,
\ log=True, multinomial=True, basic=True, **hints)
* series(self, x, point=0, n=6, dir="+")
* lseries(self, x, x0)
* nseries(self, x, x0, n)
* limit(self, x, xlim, direction='+')
* as_coeff_exponent(self, x)
SCORE sympy/core/basic.py: 50% (30 of 60)
----------------------------------------------------------------------
And ignore all the methods that the coverage script reported. Then
look at the other methods (the other 50%), they should have a
reasonable docstring.
>
> Any suggestion is welcome.
Try to use git --- just create a new branch and publish it on github.
Then it's easy for other people to try it and send patches to you with
improvements. Think about this from my perspective --- I don't mind
spending 2 minutes sending you a patch with some docstring, or fixing
some stuff, but it has to be easy for me to contribute -- with git, I
just do git pull, hack on it for 2 minutes, commit and send a patch.
If you send the files in the email, I would have to download them by
hand, put them somewhere, put them to git, create a patch etc.
If you need help with git, I am on IRC (#sympy at freenode) to help out.
Ondrej
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [email protected]
For more options, visit this group at http://groups.google.com/group/sympy?hl=en
-~----------~----~----~----~------~----~------~--~---