## 65 Reputation

11 years, 91 days

## Syntax for the seq function with units...

Maple 2021

So all I'm trying to do is a simple sequence like seq(i^2, i=1..10, 1) but with units.  The seq function is part of the Units:-Standard and Units:-Simple packages.  I couldn't find any examples with units in the help system.  For my first attempt, I tried to create a simple sequence of values with units using what is, to me, a logical syntax.  I have included the Maple input below.  I bolded the input.

with(Units:-Standard);
[*, +, -, /, <, <=, <>, =, Im, Re, ^, abs, add, arccos, arccosh, arccot, arccoth, arccsc, arccsch, arcsec, arcsech, arcsin,

arcsinh, arctan, arctanh, argument, ceil, collect, combine, conjugate, cos, cosh, cot, coth, csc, csch, csgn, diff, eval,

evalc, evalr, exp, expand, factor, floor, frac, int, ln, log,  log10, log2, max, min, mul, normal, polar, root, round, sec,

sech, seq, shake, signum, simplify, sin, sinh, sqrt, surd, tan,   tanh, trunc, type, verify]

seq(ii, ii = 1.0*Unit('m') .. 10.0*Unit('m'), 1.0*Unit('m'));

Error, (in Units:-Standard:-seq) wrong number (or type) of parameters in function seq

Can anyone show me the correct syntax for this?  Is there something in the help?  I tried it in 2021 and 2022 with the same result.

## Is it possible to open and execute Maple...

Maple 2021 , Maple Flow

Is it possible to open or import, and execute Maple Flow documents in Maple 2021?

## I can't find the Thermal Fluid Flow Port...

I'm trying to create a custom component in MapleSim 2021, and I want to use Thermal Fluid Flow Ports. However, they don't show up as a type of port in the port Type dropdown.  How can I create a thermal fluid flow port using the Custom Component Template?

## I can't get an if then statement to exec...

Maple

I have a procedure for calculating flow through a control valve and part of the calculatiion requires an interative solution if the Reynolds number is less than 10000.  I wrote a little proc in Maple to house the calculation and then I am trying to call it from fsolve.  One of the conditions in the calculation is hat if the Re >= 10000 then just exit and return the input since no correction is necessary.  However, I can't get the Reynolds number to evaluate in the condition Reynolds >= 10000 it keeps returning this error.

Error, (in ValveLaminarMassFlow_proc) cannot determine if this expression is true or false: 10000.0 <= 8848.331994*x

where x is an input parameter in the procedure call.

I have tried everything I could think of and I just have to give up and I would appreciate any help with this.

fsolve_if_then_not_evaluating_in_proc.mw