MATLAB Answers

eulergamma throwing an 'Undefined function or variable' error

5 views (last 30 days)
Cassandra Carrick
Cassandra Carrick on 5 Apr 2020
Answered: Walter Roberson on 12 Jan 2021
I need to compute the Cin integral (documentation here https://en.wikipedia.org/wiki/Trigonometric_integral) for some fourier series coefficients, which has the Euler-Mascheroni constant as part of it's definition. There is a function eulergamma from the symbolic math toolbox which computes this number. I have this toolbox and have v2019a of MATLAB installed on my computer. I have copied and pasted every example from the Matlab documentation about the eulergamma function into my command window and I just get the error 'Undefined function or variable 'eulergamma''.
What could I possibly be doing wrong?

  6 Comments

Show 3 older comments
Cassandra Carrick
Cassandra Carrick on 5 Apr 2020
At first it did not, so I updated MATLAB and now it does. Now the eulergamma function is there, but when I try to use it, it throws a whole new slew of errors.
>> eulergamma
Undefined variable "sym" or class "sym.convertStrings".
Error in sympref (line 88)
varargin = sym.convertStrings(varargin);
Error in symengine
Error in eulergamma (line 17)
y = feval(symengine,'EULER');
Warning: Failed to initialize symbolic preferences.
> In symengine
In eulergamma (line 17)
Error using sym (line 186)
Invalid MEX-file 'C:\Program Files\MATLAB\R2019a\toolbox\maple\maplemex.mexw64': Missing
dependent shared libraries:
'maplecr.dll' required by 'C:\Program Files\MATLAB\R2019a\toolbox\maple\maplemex.mexw64'
'icudt61.dll' required by 'C:\Program Files\MATLAB\R2019a/bin/win64\icuuc61.dll->C:\Program
Files\MATLAB\R2019a/bin/win64\icuin61.dll->C:\Program
Files\MATLAB\R2019a/bin/win64\libmwi18n.dll->C:\Program
Files\MATLAB\R2019a/bin/win64\libmwfl.dll->C:\Program
Files\MATLAB\R2019a/bin/win64\libmex.dll->C:\Program
Files\MATLAB\R2019a\toolbox\maple\maplemex.mexw64'
Error in mupadengine/evalin (line 127)
[res,status] = mupadmex(statement,output_type{:});
Error in mupadengine/feval (line 190)
[S,err] = evalin(engine,stmt,'message');
Error in eulergamma (line 17)
y = feval(symengine,'EULER');
>>
Walter Roberson
Walter Roberson on 5 Apr 2020
You have the Maple symbolic toolbox interface to matlab installed. You need to uninstall that interface or remove it from your MATLAB path.
Cassandra Carrick
Cassandra Carrick on 5 Apr 2020
I removed it from the MATLAB path, and now everything is working. Thank you very much!!

Sign in to comment.

Answers (1)

Walter Roberson
Walter Roberson on 12 Jan 2021
[Moving down from comment]
You have the Maple symbolic toolbox interface to matlab installed. You need to uninstall that interface or remove it from your MATLAB path.

  0 Comments

Sign in to comment.

Products


Release

R2019a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by