Matlab makes the intersection of space curve

Source: Internet
Author: User

Transfer from http://www.ilovematlab.cn/thread-168239-1-1.html

Bloggers are learning triple points recently, unfortunately the ability to imagine the space is really catching up, had to resort to Matlab.

Online provides a very good program, the line is very clear, really help me a lot.

Post the program:

Clear ALLCLC; [x, Y] = Meshgrid ( -2:0.1:2), Z1 = X.^2-2*Y.^2;Z2 = X.^2+y.^2-5;mesh (X,Y,Z1); hold On;mesh (X,Y,Z2); r0 = (ABS (Z1-Z2) <=0.1 ); zz = R0.*z1;yy = R0.*y;xx = R0.*x;plot3 (xx (r0~=0), yy (r0~=0), ZZ (r0~=0), '-k* '), ColorMap (cool) hold off

  

The time to modify Meshgrid and Z1 Z2 can be, put out a sheet.

Matlab makes the intersection of space curve

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.