Easy Matlab program with simple animations

2 ビュー (過去 30 日間)
yuval baruch
yuval baruch 2014 年 11 月 3 日
回答済み: Image Analyst 2014 年 11 月 3 日
Im having trouble with a program that Im working on nowadaays. The program includes three squares and a button.
Square A goes downward by a push of the button. Square B goes right simulteiniesly when square A goes down. Square C goes up after square B stops.
I need the whole program asap please.
Thank you
  1 件のコメント
Geoff Hayes
Geoff Hayes 2014 年 11 月 3 日
Yuval - please attach the code that you have been working on so that we can get an idea of what you have tried so far. Indicate what problems you are experiencing with the code, including desired behaviour versus observed behaviour.

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

回答 (1 件)

Image Analyst
Image Analyst 2014 年 11 月 3 日
You forgot to include any code. I'm sure you've looked up square or rectangle in the help and must have stumbled across the rectangle() function . So I'm sure you must have 3 calls to that in your button's callback function - one for each square. But you didn't include that code so I don't know how to fix it. Are you having trouble getting the current coordinates of the rectangle each time you click the button? Just show what you have in your button callback. Is this homework?
If you don't even know how to create a button, then see this: http://blogs.mathworks.com/videos/category/gui-or-guide/

カテゴリ

Help Center および File ExchangeGravitation, Cosmology & Astrophysics についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by