RunMat
  • Pricing
RunMat
GitHub
GitHub
Sign inTry in browser
DesktopRuntimePhysicsCADAdministrationAgent

Get RunMat updates

New releases, guides and examples.

Product+
  • Runtime
  • GPU
  • Parallel
  • Compile
  • Interop and MEX
  • Simulation
  • MCAD
  • ECAD
  • Enterprise
  • AI integrations
  • Pricing
  • Download
Math+
  • Signal processing
  • Linear algebra
  • Statistics
  • Curve fitting
  • Differential equations
  • Control systems
  • Optimization
  • Finance
  • Data and tables
  • Plotting
Physics+
  • Simulation overview
  • Structural
  • Thermal
  • Electromagnetic
  • Joule heating
  • Thermal stress
  • Acoustics
  • Fluid flow
  • Conjugate heat transfer
  • Fluid–structure
  • What is FEA
Industries+
  • Aerospace
  • Automotive and transportation
  • Defense
  • Electronics and semiconductors
  • Energy
  • Industrial machinery
  • Life sciences
  • Quantitative finance
Learn+
  • Guides
  • Docs
  • Function reference
  • Language reference
  • Migration guide
  • Changelog
  • MATLAB Online
  • MATLAB AI agent
  • For students
Compare+
  • RunMat vs MATLAB
  • RunMat vs Ansys
  • RunMat vs SOLIDWORKS
  • RunMat vs Altium
  • RunMat vs Cadence
  • RunMat vs COMSOL
  • RunMat vs Python
  • RunMat vs Julia
  • RunMat vs Physics AI
  • RunMat vs Octave
  • Benchmarks
  • MATLAB alternatives
  • All comparisons
Company+
  • About
  • Blog
  • Contact
  • Source code↗
  • License
  • Privacy
  • Terms

Product

  • Runtime
  • GPU
  • Parallel
  • Compile
  • Interop and MEX
  • Simulation
  • MCAD
  • ECAD
  • Enterprise
  • AI integrations
  • Pricing
  • Download

Math

  • Signal processing
  • Linear algebra
  • Statistics
  • Curve fitting
  • Differential equations
  • Control systems
  • Optimization
  • Finance
  • Data and tables
  • Plotting

Physics

  • Simulation overview
  • Structural
  • Thermal
  • Electromagnetic
  • Joule heating
  • Thermal stress
  • Acoustics
  • Fluid flow
  • Conjugate heat transfer
  • Fluid–structure
  • What is FEA

Industries

  • Aerospace
  • Automotive and transportation
  • Defense
  • Electronics and semiconductors
  • Energy
  • Industrial machinery
  • Life sciences
  • Quantitative finance

Learn

  • Guides
  • Docs
  • Function reference
  • Language reference
  • Migration guide
  • Changelog
  • MATLAB Online
  • MATLAB AI agent
  • For students

Compare

  • RunMat vs MATLAB
  • RunMat vs Ansys
  • RunMat vs SOLIDWORKS
  • RunMat vs Altium
  • RunMat vs Cadence
  • RunMat vs COMSOL
  • RunMat vs Python
  • RunMat vs Julia
  • RunMat vs Physics AI
  • RunMat vs Octave
  • Benchmarks
  • MATLAB alternatives
  • All comparisons

Company

  • About
  • Blog
  • Contact
  • Source code↗
  • License
  • Privacy
  • Terms
GitHubXLinkedIn

© Dystr, Inc. · RunMat v0.7.1, Nov 17, 2026

RunMat® is a registered trademark of Dystr, Inc. MATLAB® is a registered trademark of The MathWorks, Inc. RunMat is not affiliated with, endorsed by, or sponsored by The MathWorks, Inc.

/
    • Get started with MCAD
    • MCAD file reference
Docs>CAD>MCAD

Get started with MCAD

RunMat MCAD designs live in a project folder as text files: a .part per part, a .assembly per assembly and a .drawing per drawing. The Desktop edits them in a 3D canvas and a source view side by side; the agent and the command line read and write the same files.

1. A part

Create plate.part in the project folder. The Desktop's New Part command writes the header and an empty part block; the sketch, the extrude and the output can then be drawn on the canvas or typed.

runmat 0.7
std 1

part plate {
    sketch s on origin.xy {
        l1 = line(start = [0 mm, 0 mm], end = [80 mm, 0 mm])
        l2 = line(start = [80 mm, 0 mm], end = [80 mm, 50 mm])
        l3 = line(start = [80 mm, 50 mm], end = [0 mm, 50 mm])
        l4 = line(start = [0 mm, 50 mm], end = [0 mm, 0 mm])
    }
    feature body = extrude(profile = sketch.s, distance = 6 mm)
    output plate = { body = feature.body.body, part_number = "PL-080" }
}
  • sketch s on origin.xy draws a closed rectangle on the XY plane.
  • feature body = extrude(…) makes it 6 mm thick.
  • output plate declares the part: its body and its part number.

The canvas regenerates on every change, and problems show in the source view at the line that causes them. See Checks and diagnostics.

2. Inputs

Inputs make a part a parametric family. Replace the literal sizes with inputs, and every view, configuration, run and sweep can set them:

runmat 0.7
std 1

part tab {
    input width : length = 40 mm
    input height : length = 20 mm
    input thickness : length = 3 mm

    sketch s on origin.xy {
        l1 = line(start = [0 mm, 0 mm], end = [input.width, 0 mm])
        l2 = line(start = [input.width, 0 mm], end = [input.width, input.height])
        l3 = line(start = [input.width, input.height], end = [0 mm, input.height])
        l4 = line(start = [0 mm, input.height], end = [0 mm, 0 mm])
    }
    feature body = extrude(profile = sketch.s, distance = input.thickness)
    output tab = { body = feature.body.body, part_number = "TB-40" }
}

The Properties panel shows each input with its unit; editing one writes the new default into the file.

3. An assembly

Parts in the same folder name each other with no import. A package folder +hardware/ holds shared parts, found from any folder below it:

runmat 0.7
std 1

part standoff {
    sketch s on origin.xy {
        c = circle(center = [0 mm, 0 mm], radius = 3 mm)
    }
    feature body = extrude(profile = sketch.s, distance = 10 mm)
    output standoff = { body = feature.body.body, part_number = "SO-M3-10" }
}
runmat 0.7
std 1

assembly base {
    use part plate as plate
    use part standoff from hardware as post {
        placement = { placement = offset, offset = { translation = [10 mm, 10 mm, 6 mm] } }
    }
    use part tab as tab {
        configuration = { select = inputs, values = { width = 30 mm } }
        placement = { placement = offset, offset = { translation = [40 mm, 20 mm, 6 mm] } }
    }
}

The tab occurrence sets its own width, so the same part file serves two sizes. Mates join parts that move; see Occurrences and mates.

4. Check and export

runmat-design export base.assembly --format step --out exports
runmat-design export plate.part --format dxf --out exports

The agent runs the same tools: ask it to check the assembly, change an input, or export STEP for a study, and it proposes each change as a diff you keep or undo. See Agent tools and the command line.

Next

  • Guides: Model a part, Build an assembly, Make a drawing, Sheet metal and Product families and configurations.
  • MCAD file reference: every statement in .part, .assembly and .drawing files.
  • Features: every modeling operation.
  • Drawing views and annotations: drawings that follow the model.
On this page
  • 1. A part
  • 2. Inputs
  • 3. An assembly
  • 4. Check and export
  • Next