Creating a coordinate basis with equally spaced points?

2 Ansichten (letzte 30 Tage)
matlabkid602
matlabkid602 am 28 Jul. 2017
Kommentiert: matlabkid602 am 28 Jul. 2017
Hi. I am trying to create a coordinate basis that has dimensions in x and y axis from 0 to 30.
I am looking for a piece of code that given a number N, will create an X-Y data column of length N of equally spaced points?
How can I do this?
  2 Kommentare
John D'Errico
John D'Errico am 28 Jul. 2017
What have you tried? Have you looked at meshgrid (or ndgrid)? Would that get you a good part of the way there?
matlabkid602
matlabkid602 am 28 Jul. 2017
I've tried creating linspace vectors but the way my function works is, I need the coordinates in a vector table structure not a meshgrid.

Melden Sie sich an, um zu kommentieren.

Akzeptierte Antwort

Steven Lord
Steven Lord am 28 Jul. 2017
I believe the linspace and meshgrid functions will be of use to you.

Weitere Antworten (0)

Kategorien

Mehr zu Resizing and Reshaping Matrices finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by