[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [TRNSYS-users] Dividing by Zero



Hello, Amir.

When you want to calculate A/B, write gt(B,1E-8)*A/Max(B,1E-9).  The error will
disappear.

Best Regards
Chun Kwong LEE
City University of Hong Kong

Quoting Amir Nashed <a.nashed@unsw.edu.au>:

> Dear Users
> 
> I am facing a problem where whenever I insert an equation and divide by
> something, it receive an error that I am dividing by zero.
> 
> I made sure that all initial conditions are not zero and I even plotted the
> value of the variable and it does not equal zero.
> 
> I even put a condition that the division only occur if the denominator is >0
> but still the same.
> 
> Does anyone know what's causing this?
> 
> Thank you
> 
> Regards,
> Amir Nashed
> PhD Candidate
> School of Renewable Energy and Photovoltaic Engineering
> University of New South Wales
> Phone:+61405979282
> Email:.a.nashed@unsw.edu.au
> 
>