1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Homework Help: Matlab Question: How to assign a new name to an amended matrix

  1. Oct 22, 2012 #1
    I have to replace some matrix columns with some vectors. I am currently copying the original matrix and replacing the column of the matrix I have copied eg:

    matrix_1 = matrix_2
    matrix_2(:,4) = vector_1

    This works fine, but I was wondering if it was possible to maybe amend the original matrix and assign the result a new name?

    something like:

    (matrix_1(:,4) = vector_1) = matrix_2 'I know this is nonsense, I'm just trying to explain what I mean.'

    You can probably tell that I have only just picked up the Matlab book so please bear in mind that my knowledge is very very basic.


  2. jcsd
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook

Can you offer guidance or do you also need help?
Draft saved Draft deleted