MatLab matrix splitting Watch

Like_A_G6
Badges: 19
Rep:
?
#1
Report Thread starter 5 years ago
#1
Hey guys, I need help with MatLab matrix splitting.

I have a binary matrix which is of size 1600 x 100 which I need to split into several matrices depending on measurable parameters.

I have a parameter called no_of_regions which corresponds to the number of regions I want to split a matrix into. Each region is a region where I suspect there to be a node in a standing wave. no_of_regions = ceil(height/half_wavelength) where height is measured and an input parameter, and half_wavelength is calculated using c/(2*f) where frequency, f, is input.

So, how can I split the matrix into a series of (1600/no_of_regions) x 100 matrices which are stored under letters in order? So if no_of_regions came out to be 10 i'd have the following:

A = rows 1-160 x 100 matrix
B = rows 161-320 x 100 matrix
C = rows 321-480 x 100 matrix
...all the way to:
J = rows 1441-1600 x 100 matrix

My best attempt is as follows but it doesn't work:

alphabet = ('A' 'B' 'C' 'D' 'E' 'F' 'G' 'H' 'I' 'J' 'K' 'L' 'M' 'N' 'O' ...
'P' 'Q' 'R' 'S' 'T' 'U' 'V' 'W' 'X' 'Y' 'Z');

for i = 1:no_of_regions
while i<=26
alphabet(i) = ige2((half_wavelength_pixel_y)*( i-1): (half_wavelength_pixel_y)*i,: );
end
end

...where ige2 is my 1600 x 100 matrix and half_wavelength_pixel_y = y/no_of_regions where [x,y] = size(ige2) so y = 1600.
0
reply
TSR Learn Together
  •  Official Rep
Badges: 9
Rep:
?
#2
Report 5 years ago
#2
Hi there,

While you're waiting for an answer, did you know we have 300,000 study resources that could answer your question in TSR's Learn together section?

We have everything from Teacher Marked Essays to Mindmaps and Quizzes to help you with your work. Take a look around.

If you're stuck on how to get started, try creating some resources. It's free to do and can help breakdown tough topics into manageable chunks. Get creating now.

Thanks!

Not sure what all of this is about? Head here to find out more.
0
reply
X

Quick Reply

Attached files
Write a reply...
Reply
new posts
Latest
My Feed

See more of what you like on
The Student Room

You can personalise what you see on TSR. Tell us a little about yourself to get started.

Personalise

University open days

  • Arts University Bournemouth
    Art and Design Foundation Diploma Further education
    Sat, 25 May '19
  • SOAS University of London
    Postgraduate Open Day Postgraduate
    Wed, 29 May '19
  • University of Exeter
    Undergraduate Open Day - Penryn Campus Undergraduate
    Thu, 30 May '19

How did your AQA GCSE Physics Paper 1 go?

Loved the paper - Feeling positive (197)
30.21%
The paper was reasonable (264)
40.49%
Not feeling great about that exam... (110)
16.87%
It was TERRIBLE (81)
12.42%

Watched Threads

View All