About 537,000 results
Open links in new tab
  1. function - MathWorks

    function [y1,...,yN] = myfun(x1,...,xM) declares a function named myfun that accepts inputs x1,...,xM and returns outputs y1,...,yN. This declaration statement must be the first executable …

  2. User defined function in MATLAB - GeeksforGeeks

    Aug 20, 2020 · User defined functions are the functions created by the users according to their needs. This article explains how the user defined function in MATLAB is created. Syntax : …

  3. How to Write a User-defined Function in MATLAB - Instructables

    When you use a mathematical function f (x) many times for different variables in a MATLAB program, a user-defined function is beneficial. A user-defined function is a separate file which …

  4. User-Defined FunctionsMATLAB Programming for …

    The first step in creating a user-defined function is to define its inputs and outputs. Notice that not all functions return an output – for example, xlabel , ylabel , and title . There are some …

  5. User-Defined Functions | Introduction To MATLAB Programming ...

    This page includes lecture notes on how to create a user-defined function in MATLAB.

  6. MATLAB:User-defined Function - PrattWiki - Duke University

    Sep 17, 2017 · MATLAB has a feature that lets you create a user-defined function inside a text file. The file itself will determine how many inputs the function can accept, what they are called …

  7. 5.1: User-Defined Functions - Engineering LibreTexts

    Jul 31, 2021 · Here is the syntax that you would type into an editor window: Now save this file as TriangleArea.m. Your file name must exactly match the name of the function (except for the .m …

  8. User-Defined Functions Suppose we want to plot: sin(3*x)+sin(3.1*x) Create user-defined function function r=f(x) r=sin(3*x)+sin(3.1*x) Save as f.m

  9. Matlab user defined function | Learn the Examples of Matlab

    Mar 13, 2023 · Syntax to create a user-defined function: Description of the syntax: Please note that the func_name is required, whereas there can be zero input & output arguments. Also, the …

  10. Matlab Tutorial | User -defined functions in MATLAB: concept …

    Mar 22, 2025 · Let’s create a user-defined function called f that takes two input variables, x and y, and returns a result. We can define the function as follows: u = x * y / z; v = y^2 + 5; w = u * v - …

  11. Some results have been removed
Refresh