Jump to content

Errors compiling script with UDF


Recommended Posts

  • Developers

That could be, but did you actually read the Warning (not Error)?

Jos

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

  • Developers

Well, the $ret[] array is not defined in the snippet you have posted,  so what about you define it before use as a local variable?
... and you have an local array $arr defined for which purpose?

Jos

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

I tried fixing it but the UDF just kept giving me issues so i just made the function myself\

In case someone in the future needs to make a arcsinh heres how:

Log($x+(Sqrt($x^2+1))/Log(2.71828182845904523536028747135266249775724709369995))

 

Edited by ----
Link to comment
Share on other sites

As Jos said, you declared $arr you didn't declare $ret your code should look like:

Func ConchoiidCurve($a, $theta)
    Local $ret[2]
    Local $r = sec($theta)+$a*Cos($theta)
    $ret[0] = Cos($theta)*$r
    $ret[1] = Sin($theta)*$r
    Return $ret
EndFunc

Func SemicubicalParabolaCurve($a, $t)
    Local $ret[2]
    $ret[0] = $t^2
    $ret[1] = $a*$t^3
    Return $ret
EndFunc

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...