dgilford/tcpyPI

Problem when using pi.py

codesssss opened this issue · 2 comments

I'm trying to use pi() to get the VMAX. According to the comments the arguments P, TC, and R should all be one-dimensional arrays,
But utilities.t_ctok (TC) ,R * 0.001 makes TC, R look like int. I don't know how to use pi (). Can you give me an example data of P,TC,R?
Thanks a lot!

You can use the script run_sample.py as an example.
On the other hand. With numpy arrays operations like R*0.001 will perform the operation on every element if R is a numpy array. Take a look at:

In [1]: import numpy as np

In [2]: a = np.array(range(1,10))

In [3]: a
Out[3]: array([1, 2, 3, 4, 5, 6, 7, 8, 9])

In [4]: a * 1000
Out[4]: array([1000, 2000, 3000, 4000, 5000, 6000, 7000, 8000, 9000])

In [5]: a + 10
Out[5]: array([11, 12, 13, 14, 15, 16, 17, 18, 19])

So no, they are not ints.

Thanks a lot !