development process should be lowered by the resources and experience
of the people in my lab. This will help both students to hit the
ground running a lot more quickly.
Cheers,
~Luke
[0] -- pydy.org
--
You received this message because you are subscribed to the Google Groups
"sympy&
reate NewtonianReferenceFrame and then call the declare_coords on it
probably should be abstracted to a different class. This is something
that we are going to think about more carefully than I did when I
first work on PyDy.
Cheers,
~Luke
On Apr 5, 1:51 pm, Tim Lahey wrote:
> On Tue, Apr
give it a look, but it
hasn't been touched since June 26, 2009, so there may be quite a lot
that breaks once I rebase from the current master.
~Luke
On Apr 5, 3:02 pm, Aaron Meurer wrote:
> I agree with Ondrej.
>
> Since PyDy is (still at least) separate form SymPy, another ide
would start
working on.
So are 3D symbolic vector operations and the framework for
managing orientations and positions, something that users of SymPy
find useful? If so, I think this would justify it's inclusion as a
module, and I would like to help make it happen.
Thoughts?
Thanks,
ny comments, we would greatly
appreciate it.
~Luke
On Apr 5, 9:41 pm, Brian Granger wrote:
> On Tue, Apr 5, 2011 at 8:11 PM, Luke wrote:
> > Yeah, that is a good idea -- thanks!
>
> > Regardless of whether these two applicants end up being accepted, I
> > would like to get back
n this approach
to class design?
~Luke
--
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to sympy@googlegroups.com.
To unsubscribe from this group, send email to
sympy+unsubscr...@googlegroups.com.
For more opt
nk all the other types of products have to make use of explicit
method calls since there would be no way to know which type of product
would be implied.
~Luke
On Mon, May 9, 2011 at 4:23 PM, Gilbert Gede wrote:
> In PyDy (which we plan to merge into SymPy.physics.classical this summer)
> Ve
Can the vectors and multivectors in the GA module work with arbitrary
sympy expressions? i.e, if v is a GA vector, and s is a sympy
expression, does it make sense to do: s*v? Is the result of type Mul
or of something else?
~Luke
On Mon, May 9, 2011 at 5:42 PM, Alan Bromborsky wrote:
> On
asses that implement only the methods that make sense for them,
including the __mul__ and __rmul__ methods, as Alan did in his MV
class?
~Luke
On Tue, May 10, 2011 at 5:44 AM, Alan Bromborsky wrote:
> The assumption is that the expression multiplying the vector (multivector)
> is a scalar and t
around the class methods, so the user can choose to use whichever
approach is more natural to them.
~Luke
On Tue, May 10, 2011 at 11:02 AM, Vinzent Steinberg
wrote:
> On 10 Mai, 03:30, Ronan Lamy wrote:
>> Please, try to make the interface dot(v1, v2), and not v1.dot(v2).
>
> While
but I think all the other benefits of FOSS will become clear
to these people once they take the time to try it. But there is a
whole generation of entrenchment that will eventually retire and make
room for open source, so I see things getting better as time goes on.
~Luke
On Thu, May 12, 2011 at 10:
ke
sure we can accommodate many different reference frames which is
common in multibody dynamics.
~Luke
On Fri, May 13, 2011 at 6:29 PM, Gilbert gede wrote:
> So I think we've decided to make a new Vector class, to replace the
> previous UnitVector and Vector classes, and it will not ext
Hi eveyone,
I'm developing an web application which has to interact with "user-
defined formulas" of some financial kpis.
I decided to use sympy to have a more solid math engine.
Basically the input I reiceve is very simple, it might be in the worst
case something like:
kpi -> "(log(sum('productio
would have been:
>>> a = SUM('field') + SUM('field') + SUM('field') -> 3SUM('field') # one
>>> single query
>>> print a
>>> 3*SUM('field')
>>> print N(a)
>>> 1234
just like other functions wo
e, "myresults")
return result.find_one()['value'][unicode(cls.arg)]
Because arg in _eval_evalf was strangely enough a float (more
precisely 57, have no clue why :) ).
Thank you all guys!
On Jun 2, 6:07 pm, Ronan Lamy wrote:
> Le jeudi 02 juin 2011 à 08:03 -0700, luke
a symbol but
is a float (57 in my case, probably is an index of some internal
variable.. I can't find any documentation about that). So it's pretty
unusable, that's why I set cls.arg. However the code is working so
thanks everybody.
On Jun 2, 7:01 pm, Ronan Lamy wrote:
> Le je
WAIT, I didn't see that you use
self.arg[0]!! that's why my code was giving me 57, I just need to call
cls.arg[0], great now I can remove the eval ;)! thanks again
On Jun 2, 9:30 pm, luke wrote:
> Actually you're wrong. Every instance of a class in python has its own
> attri
Nope in spite of my enthusiasm cls.args wont work properly as it will
give me a and not a :) I'll put back my eval since
it worked. Hope that was of any help!
On Jun 2, 9:32 pm, luke wrote:
> WAIT, I didn't see that you use
> self.arg[0]!! that's why my code was giving
s != undefined){
sum += doc.%(field)s;
}
});
return {%(field)s:sum};
};""" % {'field':cls.args[0]})
result = db.people.map_reduce(map, reduce, "myresults&qu
n add some skeleton files that will get the basic sphinx framework
started, and then the submodules can be more completely fleshed out
and polished by the people who are most familiar with the various bits
of code that sympy/physics includes.
Thoughts?
~Luke
[0] -- https://github.com/gilbertgede/
cs.sympy.org in the past (other than lack of time)?
>
> No, it should be there, it is just that noone yet made sure it's
> generated correctly when building the docs.
>
I'll get started on this.
~Luke
--
You received this message because you are subscribed to the Google Gro
ppy to go over the code and
> document the parts that I use.
Cool, thanks! I'll mail the list when I get this up and running on a
github branch.
~Luke
>
> Stefan
>
> On 7 June 2011 20:34, Luke wrote:
>>
>> >> 1) Should any of the code in sympy.physics b
I was writing some documentation for physics/units.py and discovered
some infinite recursion RuntimeError:
>>> from sympy.physics.units import joule
>>> joule
....
File "/home/luke/repos/sympy/sympy/core/expr.py", line 140, in __lt__
return C.StrictInequality(sel
+1 for sympy.physics.mechanics
~Luke
On Thu, Jun 9, 2011 at 12:56 PM, Brian Granger wrote:
> On Tue, Jun 7, 2011 at 10:28 PM, Luke wrote:
>> On Tue, Jun 7, 2011 at 1:26 PM, krastanov.ste...@gmail.com
>> wrote:
>>> What would the classical module contain? Won'
ished then push it in as a whole?
~Luke
--
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to sympy@googlegroups.com.
To unsubscribe from this group, send email to
sympy+unsubscr...@googlegroups.com.
For more
.
If people have thoughts on any negative implications of implementing
multiple ways to perform the same thing, especially related to long
term maintenance of the code, it would be great to hear them.
~Luke
On Thu, Aug 11, 2011 at 12:14 PM, Gilbert Gede wrote:
> My Summer of Code project is writing
your library (sympy.physics.mechanics). If you
> rewrite the language definition, then it doesn't necessarily fit with the
> rest of the code.
> Jason
>
> On Thu, Aug 11, 2011 at 12:42 PM, Luke wrote:
>>
>> I ran this same question by my girlfriend who teaches under
entered "make
html" from the sympy/doc directory. Is this a bug, or am I doing
something incorrectly?
Thanks,
~Luke
--
"Those who would give up essential liberty to purchase a little
temporary safety deserve neither liberty nor safety."
-- Benjamin Franklin, Historical Revie
Ok, I just upgraded to Sphinx 1.0.7 and it fixed the problem.
Thanks,
~Luke
On Tue, Aug 16, 2011 at 4:10 PM, Aaron Meurer wrote:
> It works for me. The only thing that I can think of is that your
> version of Sphinx has a bug in it. I am using 1.0.7, which generates
> src
ypes: python
sympy/physics/doctest_globaldict.py[1] F
[FAIL]
__
sympy.physics.doctest_globaldict.foo
File "/home/luke/repos/sympy/sympy/physics/doctest_globaldict.py",
li
Something in testmod() must be different from the default doctest
module, I'll give it a look.
> By the way, when you say "running Python on this file," do you mean
> running "python -m doctest myfile.py"?
>
I mean "python myfile.py".
~Luke
> Aar
On Sun, Aug 21, 2011 at 10:42 AM, Aaron Meurer wrote:
> On Sat, Aug 20, 2011 at 7:34 PM, Luke wrote:
>> On Sat, Aug 20, 2011 at 3:37 PM, Aaron Meurer wrote:
>>> I don't know of any doctests in SymPy that do this. Why can't you put
>>> imports in e
hereas the Python standard library, doctest is a module with a large
number of functions, testmod() being one of them.
~Luke
On Mon, Aug 22, 2011 at 10:32 AM, Aaron Meurer wrote:
> Well, I don't know why you are doing things this way, but clearly
> python -m doctest file.py or ./bin/docte
On Thu, Aug 25, 2011 at 7:00 AM, Ronan Lamy wrote:
>
> Le samedi 20 août 2011 à 18:34 -0700, Luke a écrit :
> > On Sat, Aug 20, 2011 at 3:37 PM, Aaron Meurer wrote:
> > > I don't know of any doctests in SymPy that do this. Why can't you put
> > > import
then try to import sympy, I get the following import errors:
luke@ThinkPad-W510:~$ echo $PYTHONPATH
luke@ThinkPad-W510:~$ python
Python 2.7.2+ (default, Oct 4 2011, 20:06:09)
[GCC 4.6.1] on linux2
Type "help", "copyright", "credits" or "license" for more i
ted when I did the `python setup.py install` step. I deleted the build
directory, and repeated my steps, and now everything works as expected.
Thanks,
~Luke
--
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to sympy@g
figure it out, apparently Feynman did. My solution is here:
http://dlpeterson.com/FLP_Exercise_Challenge/solution.pdf
~Luke
--
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to sympy@googlegroups.com.
To u
Ondrej,
Great comments! How are you!? We need to get a beer next time you
are coming through -- do you have a regular schedule, maybe Google
Calendar that we can share?
> 1) How did you create the drawing in the pdf?
I used TikZ. I looked into PStricks, which is very powerful, but it
seems li
cently, I've used pydy to derive the
equations of motion for a rattleback [0], a non-trivial nonholonomic
system that has some very interesting dynamic behavior (and which can
be predicted by Newtonian mechanics). I'll try to add the
cart-pendulum system when I have time.
~Luke
[0] -- h
I found an error in my calculations, I have corrected it in the most
recent commit on the github page.
~Luke
--
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to sympy@googlegroups.com.
To unsubscribe from
rrect that the length of the pendulum is not needed if you
want the displacement in the x or y directions (l cancels out). It is
needed, however, if you want the amplitude of the angular
displacements (see
On Tue, Nov 15, 2011 at 4:32 PM, Alan Bromborsky wrote:
> On 11/15/2011 02:18 PM, Luke w
On Tue, Nov 15, 2011 at 6:41 PM, Luke wrote:
> Alan,
> Looks good, thanks. Yeah, Lagrange's method is the way to go on
> this problem, the reason I chose to do F=ma directly was purely
> because the problem is targeted towards a freshman audience and they
> won't be fa
have to use
Lagrange multipliers, or is there another way?
In the approach I outlined, you would simply dot the vector form of
the motion equation into a direction aligned with the rod
(-sin(theta)*\hat{i} - cos(theta)*\hat{j}), and then solve for F.
~Luke
--
You received this message because you a
> Are you asking, for example, how to calculate the tension in the pendulum
> arm
> using the Lagrangian method?
Yes.
--
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to sympy@googlegroups.com.
To unsubscribe from thi
ly obtain from a differential equation. But
perhaps that relationship is derivable without appealing to
differential equations. In any event, there must be some way to
relate period to length, and if it isn't this relationship, I don't
know what it is or how to rationalize it.
~Luke
--
Y
Do you mean in my solution that involves differential equations?
I think this dimensional analysis approach may have merit, I just need
to see all the steps and make sure they can all be justified without
referencing a differential equation.
~Luke
On Wed, Nov 16, 2011 at 10:08 AM, Aaron Meurer
I don't feel I
have any deeper understanding of pendulums, mechanics, or geometry,
than when I started.
If I sound like I'm criticizing you here, I apologize, I am not. I am
primarily dissatisfied with this question and others like it, and I
really don't see the point of them.
~Luke
On Wed, Nov 16, 2011 at 1:57 PM, Luke wrote:
> A very similar solution was proposed on the forum and rejected because
> he made use of the assumption of \omega_n^2 = sqrt(g/l).
I meant \omega_n^2 = g/l
~Luke
--
You received this message because you are subscribed to the Google Groups
reliably, it makes sense to pursue the flexible body case. I don't
think it make sense to pursue the flexible case until after that
though, and code output will vary significantly between the two
because you obtain PDE's in one case and ODE's in the other.
Luke
>
>
> On
hink
getting sympy.physics.mechanics into sage would solve this problem
very well.
Luke
--
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to sympy@googlegroups.com.
To unsubscribe from this group, send email to
sympy+unsubs
asons to have a custom Lagrangian class.
Luke
--
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to sympy@googlegroups.com.
To unsubscribe from this group, send email to
sympy+unsubscr...@googlegroups.com.
For m
The Maple director of research, Dr. Jürgen Gerhard, is going to be
interviewed June 28th in the following webinar:
http://spectrum.ieee.org/webinar/2075921
I thought people here might find it interesting to hear what he has to
say about symbolic computation.
~Luke
--
"People call
hen this common subexpression replacement method
is used.
Any ideas or references on this subject?
Thanks,
~Luke
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to
re
yet how to approach.
Thanks for the response and if you have any other ideas or references,
I'd love to hear them! I'm guessing I'm going to need to study up on
searching, sorting, and regular expressions.
Thanks,
~Luke
On Jun 14, 11:10 am, "Ondrej Certik" &
ose subexpression and identify
subsubexpressions), and introduce variables for any that are used
more than once. If a subexpression is found, but doesn't occur more
than once in any of the preceding equations, but then later shows up
in another equation, it would then be introduced as
Robert,
The Mathematica link you provided is exactly what I'm trying to do.
I haven't tried your python code yet but after reading it I think it
should work great. I really appreciate your comments and your help!
Thanks,
~Luke
On Jun 16, 12:14 pm, "Robert Kern" <[
and python fairly well, and I know the
kinematics well, but I'm by no means an experience object oriented
programmer, so I'm not sure about how the best way to structure things
would be.
Any suggestions on how I might start on something like this?
Thanks,
~Luke
--~--~-~--~~--
fine the position of one point q relative to another p:
p_q_p = q2*a1 + q3*b2
and the be able to do:
dot(p_q_p,a1)
and get:
q2 - sin(q1)*q3
(recall, b2 = -sin(q1)*a1+cos(q1)*a2)
Hopefully this clarifies what I'm trying to do.
Thanks,
~Luke
On Jan 17, 5:12 am, Alan Bromborsky wrote:
> L
If I have a symbolic expression like:
expr = a*sin(x) + b*cos(y) - c*tan(z)
I can get each individual additive term, sort of like:
In[1]: terms(expr)
Out[1]: [a*sin(x), b*cos(y), -c*tan(z)]
?
Thanks,
~Luke
--~--~-~--~~~---~--~~
You received this message
is how I implemented it.
Should the ._args list for the above example then be:
v1._args == [5*A[1], 6*A[2]]
?
Thanks,
~Luke
-- Forwarded message --
From: Ondrej Certik
Date: Thu, Apr 16, 2009 at 9:37 PM
Subject: Re: Confused about something
To: Luke
On Thu, Apr 16, 2009 at 8:
d I go about tackling this?
Thanks,
~Luke
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to sympy@googlegroups.com
To unsubscribe from this group, send email t
Traceback (most recent call last)
/home/luke/Documents/PythonDynamics/ in ()
/usr/lib/pymodules/python2.5/sympy/polys/factortools.pyc in factor(f,
*symbols, **flags)
78 return f
79
---> 80 coeff, factors = poly_factors(f, *symbols, **flags)
81
82 res
Incidentally, trying trigsimp with recursive=True, deep=True, or both True
didn't give the desired result.
On Tue, Apr 28, 2009 at 12:22 AM, Luke wrote:
> I'm writing some tests for some code that expresses a Vector expression in
> the coordinates of a different frame. I
nctions of time.
Even better would be something that allows for syntax such as:
>>> gc('q', 3)
But has the same behavior as above.
Is there a way to do this but *not* inject it into the *global* namespace,
only the local one?
~Luke
--~--~-~--~~~-
file the bug report, and I'll try to look at the paper Akshay
mentioned. Akshay, if you need more examples that should simplify, I
can provide you with a handful more :)
~Luke
On Apr 28, 8:28 am, Akshay Srinivasan
wrote:
> I think trigsimp is too hack-ish. I'll try implementing
be what we want to implement. I don't have
much time to start coding on it for a few weeks, but I could probably
look at a few papers and let it soak in....
~Luke
On Apr 28, 12:35 pm, Ondrej Certik wrote:
> On Tue, Apr 28, 2009 at 12:32 PM, Ondrej Certik wrote:
> > On Tue, Apr
Traceback (most recent call last)
/home/luke/Documents/PythonDynamics/ in ()
/var/lib/python-support/python2.6/sympy/solvers/solvers.pyc in
solve(f, *symbols, **flags)
73
74 if any(not s.is_Symbol for s in symbols):
---> 75 raise TypeError('not a Symbol&
I'll work on it in the next week or so, I think should be able to get
something that does the job.
~Luke
On May 11, 11:06 pm, Ondrej Certik wrote:
> On Mon, May 11, 2009 at 9:23 PM, Luke wrote:
>
> > Would there be any reason that the following should not be implemented:
to tackle
this together, let me know and we could figure out a reasonable
approach.
Thanks,
~Luke
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send emai
worth considering. Before investing in a lot of coding time, it would
nice to be sure that a good algorithm is being used, although I must
say their comparisons with the other popular packages out there seem
favorable.
~Luke
On May 20, 7:50 am, Alan Bromborsky wrote:
> Luke wrote:
> > Las
within ipython?
Thanks,
~Luke
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to sympy@googlegroups.com
To unsubscribe from this group, send email to symp
able to solve equation(s) for both
Symbol objects and Function objects.
It makes the most sense to me that it should only support lists and tuples.
~Luke
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"sympy&
Chris,
You're right, who knows when that functionality may be useful. And
it isn't a problem to deal with all three easily, so we should leave
it in there.
~Luke
On May 22, 3:32 am, smichr wrote:
> On May 22, 4:23 am, Luke wrote:> Does anybody use
> solve() by passing
1) in diff() of sympy/core/basic.py
2) in Derivative of sympy/core/function.py
It seems to me option 1 is the right choice but I'd like to hear input
on this. Maybe it doesn't matter or maybe it could another place?
Thanks,
~Luke
--~--~-~--~~~---~--~~
Yo
it doesn't like
it, as you pointed out. I'm not sure why this would happen, it seems
like integrate should parse each additive term and try to integrate
it, if this were the case, the above example should work like
Matlab.
Additionally, it doesn't seem that the results are the sa
ics
automatically is in place, but there is definitely more to do in
regards to how to deal with constraints, definitions of generalized
speeds, etc...
What sort of systems do you use Kane's method to study? My own area
of research is two wheeled vehicle (bicycle/motorcycle) dynamics and
co
least in 2008a).
I'll file it under the issues.
~Luke
In [9]: res.subs({X: 2.})
Out[9]: 4*3**(1/2) + 14*I*3**(1/2)
On May 23, 7:31 am, Oyster wrote:
> that is a bad news :(
> I have thought to use py+sympy in my research work, but think I'd
> better turn to matlab now.
>
>
to the existing matchers tuple?
I'm kind of thinking out loud right now and trying to figure out the
next step to take
~Luke
On May 21, 7:42 am, Akshay Srinivasan
wrote:
> Luke wrote:
> > I tried both of those options and had no luck :(
>
> > Have you looked
enough to recognize
arguments of the following form:
x+/- n*pi
and then return the correct result based upon some rule based lookup?
Or would it better to require the user to call trigsimp(sin(n*pi +/-
x)) to return the simplified result?
Thoughts?
~Luke
o me that if something is NumberSymbol, it should also be
a Number (or number), but this isn't how pi currently is.
I'm guessing this part is a work in progress with the assumptions
system, but I'm not sure.
~Luke
--~--~-~--~~~---~--~~
You received this message
Ok, that makes more sense now. Thanks for the clarification.
~Luke
On May 25, 1:05 pm, Abderrahim Kitouni wrote:
> On Mon, 25 May 2009 12:48:09 -0700 (PDT)Luke wrote:
>
> > 1) Why are there both 'is_Number' and a 'is_number' methods, and why
>
ere another simpler approach, or am
I missing something fundamental here?
Thanks,
~Luke
On May 25, 4:07 pm, "Aaron S. Meurer" wrote:
> On May 25, 2009, at 11:56 AM, Luke wrote:
>
>
>
>
>
> > Here is the link for the Maxima trigsimp() code. It was written in
&
t;> e1.match(a*pi + b)
> {a_: 1, b_: x}
> >>> b = Wild('b', exclude=[pi])
> >>> e2.match(a*pi + b)
> {b_: -x, a_: 1}
> >>> e3.match(a*pi + b)
> {b_: x, a_: -1}
> >>> e4.match(a*pi + b)
> {b_: -x, a_: -1}
>
> just as you ex
I get the same behavior on my machine. It seems like a bug to me.
Not sure if the bug is in integrate or in simplify, but could you file
this in the issues?
Thanks,
~Luke
On May 26, 12:16 pm, Neal Becker wrote:
> Out[80]: (-2*s**2*w**2 + w**4)/(s**4 + w**4)
>
> In [81]: _.subs(s
is being a problem is that people might not always
be using Symbol instances, they may instead want to use a Function
that is implicitly dependent upon one or more other variables (case in
point, generalized coordinates in classical mechanics).
Ondrej, I'm told you are the only one who understan
a, (f, 0, infty)))
---
NameError Traceback (most recent call
last)
/home/luke/lib/python/sympy/ in ()
NameError: name 'infty' is not defined
In [6]: simplify(integrate(ia, (f, 0, oo)))
Out[6]: 0
In [10]: oo.
*Pi^4*x^4 + w^4), x] ==
(w*(-6*ArcTan[1 - (2*Sqrt[2]*Pi*x)/w] + 6*ArcTan[1 + (2*Sqrt[2]*Pi*x)/
w] + Log[-w^2 + 2*Sqrt[2]*Pi*w*x - 4*Pi^2*x^2] - Log[w^2 + 2*Sqrt[2]
*Pi*w*x + 4*Pi^2*x^2]))/ (8*Sqrt[2]*Pi)
They don't let you do definite integrals there. And the computation
timed out on Wol
That happens to be what I'm working on,
and maybe other people might find this functionality useful, or maybe
not.
I guess it might just be as simple as subclassing Symbol and adding
the functionality I just described, but hopefully this would still
allow it to retain the ability to wor
of x, D(x(t), t) instead of x' (or
something similar). But maybe it could still be done without
subclassing?
The other approach would be to make everything in Sympy work equally
well with Function, Derivative, and Symbol. I don't know if this is a
good idea or not, but it also seems l
ndant of x, or something like this) so
that it can be used in all the functions that work well with Symbol.
This sort of behavior would make many things extremely easy and for
the stuff I'm doing, would let one focus on the problem, not on the
syntax.
Thoughts?
~Luke
On May 27, 11:53 am
of it there, and then
use the second approach for the auto substitution stuff.
~Luke
On May 27, 4:49 pm, Ondrej Certik wrote:
> We discuss this on IRC with Luke and Fabian. Now I understand -- Luke
> wants the result of differentiating not to be instances of
> Derivative() class, but r
I'm a little unclear about a few things with regards to how to
properly subclass StrPrinter.
On May 27, 5:08 pm, Ondrej Certik wrote:
> On Wed, May 27, 2009 at 6:05 PM, Luke wrote:
>
> > I like the first way for the fact that it just has 'x' instead of 'x
>
at would show their subclassing of StrPrinter, as well as
the code inside their cusstom class, and any other relevant code as a
complete example of how to properly customize the printing?
Thanks,
~Luke
On May 28, 3:23 pm, Luke wrote:
> I'm a little unclear about a few things with regards t
(expr))
File "/var/lib/python-support/python2.6/sympy/printing/printer.py",
line 132, in _print
res = getattr(expr, self.printmethod)()
File "/home/luke/lib/python/pydy/pydy.py", line 266, in _sympystr_
xsym('*') + k._sympystr_()
UnicodeDecodeError: 'a
ce I get to the point of understand how it works, but I'm
not there yet.
Thanks,
~Luke
On May 28, 4:00 pm, Sebastian wrote:
> Hi Luke,
>
> I think all your questions are answered in the docstring of
> printing/printer.py. There it tells you in which order it is tried to
> pri
sym('*') + k.__str__()
It gives me an error because of the xsym('*') part:
s += print_pydy(e.dict[k]) + xsym('*') + k.__str__()
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position
11: ordinal not in range(128)
Any suggestions on h
Sebastian,
Thanks again for the responses, I really appreciate it. I was a
little confused in your second example, see below.
On May 28, 5:17 pm, Sebastian wrote:
> Luke wrote:
> > Sebastian,
> > Thanks for the reply. I have read printer.py, str.py, and repr.py,
> >
Ok, thanks.
Any ideas regarding the xsym("*") error?
Thanks,
~Luke
On May 28, 6:26 pm, Sebastian wrote:
> Luke wrote:
> > Sebastian,
> > Thanks again for the responses, I really appreciate it. I was a
> > little confused in your second example, see
instead it generates the
UnicodeDecodeError.
I know my terminal is unicode enabled, the error is something else, I
just don't know how to fix it.
~Luke
On May 28, 6:34 pm, Sebastian wrote:
> Luke wrote:
> > Ok, thanks.
>
> > Any ideas regarding the xsym("*") error?
>
&
__()
i += 1
else:
And here is the error I'm getting:
File "t.py", line 56, in
print 'print A[1]', Vector((1+sin(q1))*A[1])
File "/home/luke/lib/python/pydy/pydy.py", line 254, in __str__
return pr
1 - 100 of 144 matches
Mail list logo