Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #3859

Re: Vectors

From Algis Kabaila <akabaila@pcug.org.au>
Organization PCUG - Users Helping Users
Subject Re: Vectors
Date 2011-04-22 20:58 +1000
References <mailman.625.1303285644.9059.python-list@python.org> <mailman.686.1303370707.9059.python-list@python.org> <91c4q0Fnl4U1@mid.individual.net>
Newsgroups comp.lang.python
Message-ID <mailman.743.1303469897.9059.python-list@python.org> (permalink)

Show all headers | View raw


On Friday 22 April 2011 11:43:26 Gregory Ewing wrote:
> Algis Kabaila wrote:
> > the Vector3 class
> > is available without any prefix euclid:
> > 
> > import euclid
> > v = Vector3(111.., 222.2, 333.3)
> 
> Doesn't work that way for me:
> 
> Python 2.7 (r27:82500, Oct 15 2010, 21:14:33)
> [GCC 4.2.1 (Apple Inc. build 5664)] on darwin
> Type "help", "copyright", "credits" or "license" for more
> information.
> 
>  >>> import euclid
>  >>> Vector3
> 
> Traceback (most recent call last):
>    File "<stdin>", line 1, in <module>
> NameError: name 'Vector3' is not defined
> 
> Are you sure you hadn't previously done 'from euclid import
> Vector3' or 'from euclid import *' in that session?

I've tested it again and it does behave in a "standard" manner.  
I must have imported all as you suspected. Makes me much 
happier, though I do feel sheepish.  As they say, sh... happens.

BTW, I did modify the euclid very slightly to work with Python 3 
- just change the syntax of messages with exception in line with 
syntax changes.

Thanks for sharing your experience with that cute package!

OldAl.
-- 
Algis
http://akabaila.pcug.org.au/StructuralAnalysis.pdf

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Vectors Algis Kabaila <akabaila@pcug.org.au> - 2011-04-20 17:47 +1000
  Re: Vectors Anssi Saari <as@sci.fi> - 2011-04-20 11:07 +0300
    RE: Vectors Andreas Tawn <andreas.tawn@ubisoft.com> - 2011-04-20 15:43 +0200
      Re: Vectors RJB <rbotting@csusb.edu> - 2011-04-20 08:34 -0700
        RE: Vectors Andreas Tawn <andreas.tawn@ubisoft.com> - 2011-04-20 17:49 +0200
        Re: Vectors Algis Kabaila <akabaila@pcug.org.au> - 2011-04-21 17:25 +1000
          Re: Vectors Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2011-04-22 13:43 +1200
            Re: Vectors Algis Kabaila <akabaila@pcug.org.au> - 2011-04-22 20:58 +1000
      Re: Vectors Anssi Saari <as@sci.fi> - 2011-04-21 17:07 +0300
      Re: Vectors Jonathan Hartley <tartley@tartley.com> - 2011-04-25 03:49 -0700
        Re: Vectors Algis Kabaila <akabaila@pcug.org.au> - 2011-04-26 21:26 +1000
  Re: Vectors sturlamolden <sturlamolden@yahoo.no> - 2011-04-22 13:57 -0700
    Re: Vectors Algis Kabaila <akabaila@pcug.org.au> - 2011-04-23 10:32 +1000
      Re: Vectors sturlamolden <sturlamolden@yahoo.no> - 2011-04-22 21:13 -0700
        Re: Vectors Algis Kabaila <akabaila@pcug.org.au> - 2011-04-23 22:26 +1000
          Re: Vectors sturlamolden <sturlamolden@yahoo.no> - 2011-04-23 07:02 -0700
    Re: Vectors Robert Kern <robert.kern@gmail.com> - 2011-04-24 18:49 -0500
      Re: Vectors rusi <rustompmody@gmail.com> - 2011-04-24 19:59 -0700
        Re: Vectors Algis Kabaila <akabaila@pcug.org.au> - 2011-04-25 17:05 +1000

csiph-web