Azzera filtri
Azzera filtri

Double Summation For two point correlation

3 visualizzazioni (ultimi 30 giorni)
I have to use the double summation function (attached below) where the phi function is the distance formula in three dimensional space. I have the function I need, but I am not sure how to program it into a double summation on MATLAB.
  1 Commento
Alexandra Harkai
Alexandra Harkai il 3 Mar 2017
What have you tried so far? What are D and R? What arguments does your phi function take?

Accedi per commentare.

Risposte (1)

Darshan Ramakant Bhat
Darshan Ramakant Bhat il 6 Mar 2017
I think the simpler way is to do using two for loops.
for i=1:length(D)
for j=1:length(R)
Additionally you can try to vectorize the process. Following link may help you
Darshan Bhat


Scopri di più su Loops and Conditional Statements in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by