How to add code in each cell of the GUI table?

3 ビュー (過去 30 日間)
Dale Janry Serrano
Dale Janry Serrano 2020 年 1 月 17 日
コメント済み: Walter Roberson 2020 年 1 月 19 日
Hi guys I am working a secant method with GUI and I am a total beginner in matlab. I want to ask if it is possible to add code/formula in each cell of the table in GUI? What I want to happen is to automatically solve the linear equation after I press the 'Calculate' push button and the data will be shown on the table below. The picture of the gui is attached here, thanks
  9 件のコメント
Dale Janry Serrano
Dale Janry Serrano 2020 年 1 月 19 日
Hi Walter Roberson, I already did what you have said and made the f(x0), f(x1) and f(x2) to f0, f1, f2. However, when I run the program and clicked the push button 'Calculate' in the GUI there is an error occurring like this.
Error in
matlab.graphics.internal.figfile.FigFile/read>@(hObject,eventdata)equationsecant('calculate_Callback',hObject,eventdata,guidata(hObject))
Error while evaluating UIControl Callback.
Also, the table is working when I replace the formula of x2 as a constant. I will post a photo of my gui and code here that shows that the table is working when x2 is equal to 2. Thank you btw!!
x2.PNG
Walter Roberson
Walter Roberson 2020 年 1 月 19 日
Use the debugger to figure out which line the problem is occurring on.

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

回答 (0 件)

カテゴリ

Help Center および File ExchangeInteractive Control and Callbacks についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by