Solved

Matkab ,draw line in 3d

Posted on 2013-02-01
2
491 Views
Last Modified: 2016-03-02
I need to draw a line in 3d using Matlab ,the reason for this is that I need to draw a model for
a line penetrating a surface ,for my students.

I just need to demonstrate to them how to find the angle between a line and a surface.
So how to do this using mesh() and meshgrid() ?

THNX
0
Comment
Question by:aboo_s
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 15

Accepted Solution

by:
yuk99 earned 500 total points
ID: 38843389
Use plot3 function:
If you need a line together with surface put 'hold on' before print3 statement and 'hold off' after that not to start a new figure.
Alternatively you can use line function with X,Y,Z vectors as parameters.
0
 
LVL 10

Author Closing Comment

by:aboo_s
ID: 38862555
Thanks it worked!
0

Featured Post

Optimize your web performance

What's in the eBook?
- Full list of reasons for poor performance
- Ultimate measures to speed things up
- Primary web monitoring types
- KPIs you should be monitoring in order to increase your ROI

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Having just graduated from college and entered the workforce, I don’t find myself always using the tools and programs I grew accustomed to over the past four years. However, there is one program I continually find myself reverting back to…R.   So …
This article will show, step by step, how to integrate R code into a R Sweave document
This video teaches viewers about errors in exception handling.
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…

632 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question