Re: [問題] 如何將圓內填滿色彩已回收

看板MATLAB作者 (神無月 孝臣)時間16年前 (2009/06/21 19:30), 編輯推噓4(403)
留言7則, 2人參與, 最新討論串2/2 (看更多)
※ 引述《aifinsrc (henry)》之銘言: : 各位版大: : 如果我現在能畫出一個圓, 現在希望把這圓內的所有面積填滿色彩, 應該如何 : 下指令? : 感謝! 給四個點假設是這樣 . . . . 座標為: x = [ 0 0 1 1 ] y = [ 1 0 0 1 ] 所以plot( x , y )會變這種形狀 . . | | | | .-----. fill( x , y )就是把頭尾兩點再連接起來 然後在封閉區域內塗色 所以可以塗一塊出這樣的形狀 .-----. | | ←塗滿顏色的方形區域 | | .-----. -- Deserves death! I daresay he does. Many that live deserve death. And some die that deserve life. Can you give that to them? Then be not too eager to deal out death in the name of justice, fearing for your own safty. Even the wise cannot see all ends. Gandalf to Frodo -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 220.131.231.141

06/21 19:47, , 1F
fill(x,y,'y') 黃色填滿
06/21 19:47, 1F

06/21 19:51, , 2F
試試極座標~
06/21 19:51, 2F

06/21 20:00, , 3F
話說~G大!那個圖畫出一個叉叉~因為四個點的關系
06/21 20:00, 3F

06/21 20:01, , 4F
順序有關係
06/21 20:01, 4F

06/21 20:02, , 5F
啊,我座標打的錯,y應該是[1 0 0 1],plot也要看順序
06/21 20:02, 5F
※ 編輯: Gwaewluin 來自: 220.131.231.141 (06/21 20:02)

06/21 20:06, , 6F
極座標失敗~
06/21 20:06, 6F

06/21 20:08, , 7F
上一篇元PO的圓~不知道是不是用極作標畫的
06/21 20:08, 7F
文章代碼(AID): #1AFXdQiu (MATLAB)
討論串 (同標題文章)
文章代碼(AID): #1AFXdQiu (MATLAB)