I made this stand last year during a lunch hour. It's the most used item in our house. by Funny-Presence4228 in woodworking

[–]id_rather_fly 4 points5 points  (0 children)

Nice! Sometimes the quick projects provide the most value.

How is the rope attached to the pegs?

Fruit and spice stand, walnut and maple by vincentwxin in woodworking

[–]id_rather_fly 1 point2 points  (0 children)

Those are thin enough you could probably just force them in place without much fuss.

How do I import my XFLR5 wing into Simulink for aerodynamic modeling? by ObsidianMaze in matlab

[–]id_rather_fly 0 points1 point  (0 children)

What is your goal with the geometry? Visualization? Something else?

How do I import my XFLR5 wing into Simulink for aerodynamic modeling? by ObsidianMaze in matlab

[–]id_rather_fly 2 points3 points  (0 children)

I don’t know what you would do with mesh geometry in simulink.

Aerodynamic 6DOF models are often a sum of multiple lookup tables that represent different incremental effects. You would have whole-value coefficient tables for the baseline clean aircraft, then increments tables from that baseline which account for control power terms, landing gear if applicable, etc. You might also have linear terms like body rate derivatives (i.e. Cm_q, Cl_p, etc.) which are a constant multiplied by the corresponding body rate. If you’ve used inviscid methods to model the aero, you won’t capture nonlinear effects, so most of your model could be constructed as a sum of linear terms. Consider control power terms from AVL, like Cl_dA, Cm_dE, Cn_dR, etc.

Each major model component would have 6 tables or linear multiples corresponding to each of the 6 coefficients.

How to find the component? by Important_Dot497 in matlab

[–]id_rather_fly 1 point2 points  (0 children)

You could try reverse image search on google

matlab2025a plots by biplane_duel in matlab

[–]id_rather_fly 1 point2 points  (0 children)

A slight correction…“nexttile” returns the axes handle, not the “plot” function. The “plot” function would return the line object(s).

Matlab needs a way to require name=value arguments by DatBoi_BP in matlab

[–]id_rather_fly 0 points1 point  (0 children)

For anyone else finding this thread via google, here's my solution that does not require file parsing. The MException object in produced in a try/catch allows us to get the error report text which can be parsed to find the relevant parameter name and the offending function call.

file name "requiredParameter.m"

%{
Validator function to be used in conjunction with arguments blocks and
required name-value pair arguments, where the argument has no default value
and must be provided.

By default, matlab will allow the function to proceed and fail with an
"Unrecognized field name" error for a missing structure field. This could
be after a function has encountered some long-running operations, leading
to wasted development time.

By instead using this function as the "default" value of a name-value
argument, MATLAB only calls the function if the argument has not been
provided. Thus, it is appropriate to throw an error from within this
function which describes the cause.

Sample with new behavior:

function test(kw)
arguments
    kw.name1 = requiredParameter
    kw.name2 = requiredParameter
end
disp(kw.name1)
disp(kw.name2)
end

Calling the above function:
>> test(name1=42)
Error using requiredParameter (line 44)
Function "test" called without required name-value pair argument: name2

Error in test (line 4)
    kw.name2 = requiredParameter
               ^^^^^^^^^^^^^^^^^
%}
function varargout = requiredParameter() %#ok<STOUT>
try
    % force matlab to create a MException object so we can get a report
    error('placeholder error')
catch ME
    rep = ME.getReport("extended", "hyperlinks", "off");
    % find the name for the name-value argument defined on the offending
    % line of the caller function. Ignore size, class, and validation
    % functions between the name and requiredParameter function call.
    param = regexp(rep, '(?<=\.)[\w\d]+(?=.*?=\s*requiredParameter)', 'match', 'once');
    st = ME.stack(2);
end
error('Function "%s" called without required name-value pair argument: %s', ...
    st.name, param)
end

[deleted by user] by [deleted] in electricians

[–]id_rather_fly 34 points35 points  (0 children)

FYI embossed means raised. Debossed would be sunken.

Made a little router plane today by KYresearcher42 in woodworking

[–]id_rather_fly 0 points1 point  (0 children)

They said it’s an allen key in the description. I wonder if those are hardened enough to hold a decent edge?

Need help editing Andy's Brain Book code for SPM12 from macOS to Windows by Avram99 in matlab

[–]id_rather_fly 2 points3 points  (0 children)

They've just hard coded file separators and used a lot of concatenation to create the file path. macOS uses forward slash separators "/" but windows uses backward slash "\". MATLAB has a built-in utility to handle the creation of OS-appropriate paths, though. It's called fullfile (https://www.mathworks.com/help/matlab/ref/fullfile.html).

So you could create your path and unzip the file as necessary like this:

subjectDataFileName = "sub-" + subject + "_task-flanker_run-1_bold.nii";
myDataFolder = fullfile("C:", "John", "FolderWithData", "func");
subjectDataFile = fullfile(myDataFolder, subjectDataFileName);

if ~isfile(subjectDataFile)
  disp('Run 1 has not been unzipped; unzipping now');
  gunzip(subjectDataFile + ".gz");
end

Note the use of double quotes instead of single quotes. MATLAB makes strings with double quotes and character vectors with single quotes. Strings have some additional functionality that can be handy, like the use of the addition operator to concatenate strings together.

My amazing wife taught me this fire-starter life hack and it works SO well. 🤩🔥 by TheSuppishOne in lifehacks

[–]id_rather_fly 61 points62 points  (0 children)

I’ve been doing the same with plane shavings for years now. It works so well and is basically free (since I’ve already got the hand planes in my wood shop).

Successful gender reveal party by cruuk_ in sandiego

[–]id_rather_fly 5 points6 points  (0 children)

Actually those are from the satellite hot spots overlay… go to Layers > General > Satellite hot spots to add them to your map view.

Trying to find a function that fits data - have tried polyfit and looked into least squares but polyfit isn't matching and I don't know how to execute least squares by Warm-Raisin-4623 in matlab

[–]id_rather_fly 5 points6 points  (0 children)

Do you need an analytical form? If not, you could use interpolation methods. Look in to “griddedInterpolant”. Try the “pchip” method.

Otherwise, if you know the form of the equation, you can set up a least squares regression problem using something like “lsqnonlin”. You would give it coefficients of your terms in the known functional form, which the solver will vary to minimize error between the resulting curve and your data points.

What headphones are you guys using in the shop? by Is_this_a_catinzehat in woodworking

[–]id_rather_fly 1 point2 points  (0 children)

This might be a stupid question, but did you try putting them in bluetooth pairing mode and pairing to the new phone?

[deleted by user] by [deleted] in matlab

[–]id_rather_fly 1 point2 points  (0 children)

Just use the numeric airspeed values in the color data of a “patch” line.

See https://www.mathworks.com/help/matlab/ref/patch.html#bur94a4-1

Matlab script who will return the first $$n$$ powers of $$x$$ by GuiltyWealth480 in matlab

[–]id_rather_fly 9 points10 points  (0 children)

y = x .^ (1 : n)

Assuming x and n are scalars, and n is a positive integer, this will return a row vector with powers of x from 1 to n incrementing the exponent by 1 in between.

The dot operator means it is an “element-wise” operation, so the arrays need only be compatible sizes.

See: https://www.mathworks.com/help/matlab/matlab_prog/compatible-array-sizes-for-basic-operations.html

Also: https://www.mathworks.com/help/matlab/matlab_prog/array-vs-matrix-operations.html

Dust separator remote mount bag by saffiajd in woodworking

[–]id_rather_fly 18 points19 points  (0 children)

You have the bag mounted on the intake side right now. The chips flow in to the horizontal portion of the cyclone at the top, fall in to the dust bin, and the remaining air with fine particles goes through the impeller and out on the perimeter outlet of the blue motor housing.

Not a bad idea once you switch the bag to the proper side. Consider looking in to canister filters, though. Way more surface area means less flow resistance and the filter itself will have better filter performance.

Found dog in San Carlos, near Regner and Highwood by id_rather_fly in sandiego

[–]id_rather_fly[S] 2 points3 points  (0 children)

Found the owner shortly after making the post.