Undefined function 'int' for input arguments of type 'double'.

Hello Every Body .. I am anew matlab user and i have an error on my code i hope to solve it
This My Code :
EDIT: Mostfa Abd El-Aziz's "Answer" moved here and code uploaded as a file:
that is my complete code
code describtion : i want to embed cipher text data in dct coefficients of an image using dct based embeded method

9 件のコメント

madhan ravi
madhan ravi 2019 年 4 月 30 日
Nobody’s going to help unless you post the actual code.
Mostfa Abd El-Aziz
Mostfa Abd El-Aziz 2019 年 4 月 30 日
i have post ascreen shot of my code in which part i have an error
what you mean dear madhan ravi ?
Raj
Raj 2019 年 4 月 30 日
Share the code. It is difficult to make out anything with the screenshot you have posted.
Stephen23
Stephen23 2019 年 4 月 30 日
編集済み: Stephen23 2019 年 4 月 30 日
@Mostfa Abd El-Aziz: what do you expect int of two numerics to return?
Did you read the int documenation? Are you supplying input arguments of classes that int supports? (hint: no).
Mostfa Abd El-Aziz
Mostfa Abd El-Aziz 2019 年 4 月 30 日
i have read int documentation but i cant employee it with my specific code
whats your advice to me to do ?
thanks alot for your response
Daniel
Daniel 2019 年 4 月 30 日
Is 'int' a user-defined function within your Matlab search path or your current working directory?
You can find that out using the 'which' command.
which int
If this returns a script within your Matlab directory, you're using the built-in Matlab function 'int', which does not work on two numeric inputs hence the error message.
So either you're trying to use a Matlab function that doesn't exist in Matlab or has a different name, or your user-defined function is not found by Matlab.
Stephen23
Stephen23 2019 年 4 月 30 日
編集済み: Stephen23 2019 年 4 月 30 日
"i have read int documentation..."
Good.
"...but i cant employee it with my specific code"
Possibly true.
"whats your advice to me to do ?"
You have not given any explanation what you are trying to achieve or written any comments in your code. Nor did you answer my question. So I have no idea what you are trying to do. If you explain what you are trying to do, then you are likely to get help.
Also, as madhan ravi already wrote, posting your code as text rather than pretty-but-useless screenshot would help us. Best would be simply to upload it by clicking the paperclip button.
Mostfa Abd El-Aziz
Mostfa Abd El-Aziz 2019 年 4 月 30 日
編集済み: Mostfa Abd El-Aziz 2019 年 4 月 30 日
i have run which int in command window and the result is :
>> which int
C:\Program Files\MATLAB\MATLAB Production Server\R2015a\toolbox\signal\signa\@filtstates\int.m % filtstates method
What does it mean ?
Stephen23
Stephen23 2019 年 4 月 30 日
編集済み: Stephen23 2019 年 4 月 30 日
"What does it mean ?"
That int is a method of a class in a specific toolbox, and that class just happens to have the very same name as the function that you uploaded. Is that just a coincidence? Did you copy a MATLAB toolbox function/class and try to make changes to it? Why does this class have exactly the same name as your function?
Your usage of int (with four output arguments) does not match the syntax any function named int that I can find. Daniel's assessment is likely correct. But as you still have not answered my very first question, I cannot guess what you are trying to do on that line.
By the way, get rid of clear all (which is totally pointless at the start of a function) and close all from the start of your function (which is totally unrelated to the functionality of your code). They really do not help you (no matter how much beginners love them):

サインインしてコメントする。

回答 (1 件)

KSSV
KSSV 2019 年 4 月 30 日

0 投票

What you are using int is to find the integral for the given sybolic function. I think you need to have a look on int16, int32.

カテゴリ

質問済み:

2019 年 4 月 30 日

編集済み:

2019 年 4 月 30 日

Community Treasure Hunt

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

Start Hunting!

Translated by