expression that changes if a condition is true
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Valeria Leto
le 15 Mai 2020
Commenté : Ameer Hamza
le 15 Mai 2020
Hi! I know it's a silly question but I don't remember how to write an expression like that
theta=psi+pi*(condition:x<0)
and I want -theta=psi if the condition is false
-theta=psi+pi if the condition is true
thanks!
0 commentaires
Réponse acceptée
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Loops and Conditional Statements dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!