Link to home
Start Free TrialLog in
Avatar of rmtogether
rmtogether

asked on

dot calculation

Hi, experts

I am kind of confuse about the syntax in matlab below
p ./ numel(I) --> there is a dot after p
p / numel(I) --> no dot after p

what is the difference between those two? I try couple different p matrix, but I don't see the different in answer.
Avatar of MacroLand
MacroLand
Flag of United States of America image

if there is dot between two like A./B then matlab divides the two matrices by their entries like A(i,j)/B(i,j)

if there is no dot between A/B  then matlab takes the inverse of B which is equivalent to A*inv(B)

Regards,
ASKER CERTIFIED SOLUTION
Avatar of MacroLand
MacroLand
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial