[Jprogramming] newbie help: how to avoid division by zero
Raul Miller
rauldmiller at gmail.com
Tue May 21 18:11:21 UTC 2013
On Tue, May 21, 2013 at 12:49 PM, P T <pthimmapuram at gmail.com> wrote:
> I am almost close to finishing an initial version. But, I don't know how to
> write a verb P(ij) = (phase(i) - phase(j))/lineReactance(ij) where
Without looking at your data, this smells like:
Pij=: -/~@[ % ]
which you use as:
phase Pij lineReactance
Here, phase is assumed to be 1 dimensional and lineReactance two
dimensional and square. And phase -:&# lineReactance should always be
true.
I did not try this on your example data since I do not know what the
result would be.
I will note that you are dividing by zero, which is worrying.
--
Raul
More information about the Programming
mailing list