Azzera filtri
Azzera filtri

How can i imlpement a 2D function on. Matlab

2 visualizzazioni (ultimi 30 giorni)
I want to implement the following function on matlab, how can i do it, can you help me?. Thanks in advance
  1 Commento
Stephen23
Stephen23 il 7 Lug 2021
Modificato: Stephen23 il 7 Lug 2021
The logic is inconsistent. The following two conditions are both duplicated:
m = 0, n = -1
m = -1, n = -1

Accedi per commentare.

Risposta accettata

KSSV
KSSV il 7 Lug 2021
m = 1 ; n = 1 ;
if m == 1 && n == -1
h1 = 1 ;
elseif m == 0 && n == -1
h1 = 1 ;
elseif
.
.
.
.
end
Add your other cases.
  2 Commenti
Deniz Bozdogan
Deniz Bozdogan il 7 Lug 2021
it always returns h1 as -1 since m=1 n=1
KSSV
KSSV il 7 Lug 2021
Modificato: KSSV il 7 Lug 2021
Why? You don't want to change values of m and n?
Write it to a function with m, n as inputs and h1 as output.

Accedi per commentare.

Più risposte (0)

Categorie

Scopri di più su Get Started with MATLAB in Help Center e File Exchange

Prodotti


Release

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by