For context, I am developing an entity that calculates the solar radiation by hour over an entire year. In calculating the zenith angle, I need to use the Acos function (inverse cosine). The user guide indicates that it is available. However, I have incurred an error:
Source Description
Auxiliary "zenith angle" Unrecognized element 'Acos' in Expression: Model.degrees per radian*Acos(cos(solar declination in radians)*Cos(latitude/Model.degrees per radian)*Cos(hour angle/Model.degrees per radian)+Sin(solar declination in radians)*Sin(latitude/Model.degrees per radian))
I am using version 4.5 of Ventity.
Do you know how I can resolve this error please.
Missing function: Acos
Re: Missing function: Acos
I see what you mean. We'll fix.
A workaround might be to put a table of values in a lookup.
A workaround might be to put a table of values in a lookup.
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Missing function: Acos
Here's a macro version, based on Abramowitz & Stegun:
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Missing function: Acos
Awesome, thanks! I will probably implement my project as a series of macros too.