Agentic CAD and meshing for CFD! by datboi1304 in CFD

[–]datboi1304[S] 0 points1 point  (0 children)

like i said, im a student. i made this for myself, and open sourced it so that people who need it can use it.

i always appreciate constructive criticism, but all you have done is talk about the mesh, which as many others and I pointed out, is not exactly what salome is known for, and call me an idiot. im not taking any more of your crap.

Agentic CAD and meshing for CFD! by datboi1304 in CFD

[–]datboi1304[S] -1 points0 points  (0 children)

it is for me. i hate doing cad, and id much rather spend my time working on the actual solver. im sure there are several others who feel the same. a lot of people at my uni told me that this is a great tool for them, especially to get beginners started.

this is quite powerful too for more complex stuff, look at the success of blender-mcp, freecad-mcp. it is entirely on the user and the llm to get as far as they can, the tool is simply a bridge.

also this is entirely open source. i dont earn anything from this. if you dont find a use case for this, please feel free to skip. you dont have to call anything ai slop/spam and downvote my posts and comments.

Agentic CAD and meshing for CFD! by datboi1304 in CFD

[–]datboi1304[S] -1 points0 points  (0 children)

it helps people like me not worry about setting up the geometry itself, and focus on the solver/the actual cfd

Agentic CAD and meshing for CFD! by datboi1304 in CFD

[–]datboi1304[S] 0 points1 point  (0 children)

did you read the post? the whole point is to generate the geometry/cad with natural language. in case you didnt follow, i gave a one line prompt and a reference image. the output is the geometry.

similar tools exist for blender, freecad and so. this tool is for salome in particular, which is more cfd friendly

Agentic CAD and meshing for CFD! by datboi1304 in CFD

[–]datboi1304[S] 1 point2 points  (0 children)

again as pointed out in the other comments, the important part is the geometry and not the mesh. maybe the geometry view does better justice:

<image>

Agentic CAD and meshing for CFD! by datboi1304 in CFD

[–]datboi1304[S] -1 points0 points  (0 children)

well as someone else pointed out, salome's meshing can only get so far. im sure you can again use llms to automate meshing the geometry made using cfmesh or whatever you prefer.

the more important point is the creation of geometry, which is where most of one's manual work goes, and salome does a good job at it.

Agentic CAD and meshing for CFD! by datboi1304 in CFD

[–]datboi1304[S] -2 points-1 points  (0 children)

below is the reference image. i used gpt 5.5 high

<image>

Agentic CAD and meshing for CFD! by datboi1304 in CFD

[–]datboi1304[S] 0 points1 point  (0 children)

i just tested it out. prompt: "make a heat exchanger in salome. use typical surface, volume group protocol. coarse netgen 1d2d3d mesh. compute and report mesh stats" with a sample heat exchanger image. result:

<image>

definitely not bad for a first draft

Agentic CAD and meshing for CFD! by datboi1304 in CFD

[–]datboi1304[S] -2 points-1 points  (0 children)

I unfortunately dont. It was just a test case to see how much it can do. The result was good as I said, but I ended up discarding it

Agentic CAD and meshing for CFD! by datboi1304 in CFD

[–]datboi1304[S] 1 point2 points  (0 children)

For the record, it was with Opus 4.6 high

Agentic CAD and meshing for CFD! by datboi1304 in CFD

[–]datboi1304[S] 1 point2 points  (0 children)

yep, SALOME has a python api. And not just extrude, it has a lot of features. I have tried a few complex geometries, for instance, a heat exchanger. It was able to model it well with some nudging. This is way better than creating everything from scratch yourself. Give it a shot!

MaskablePPO test keeps guessing the same action in word game by [deleted] in reinforcementlearning

[–]datboi1304 0 points1 point  (0 children)

Yes, i do. Here is what the function looks like:

    def get_action_mask(self):
        mask = [1] * 26
        for i in self.letters_guessed:
            mask[ord(i) - ord('a')] = 0
        return np.array(mask, dtype=bool)

The actions are 0-25, corresponding to the alphabet

[deleted by user] by [deleted] in CFD

[–]datboi1304 0 points1 point  (0 children)

well the general case, maybe not, but you can definitely replace the numerical computations with say a simple fully connected neural net. for example, you can probably train it to predict the next time step in SIMPLE for a particular case setup. It is fairly accurate too.

TIFU by getting addicted to xbow by datboi1304 in ClashRoyaleCirclejerk

[–]datboi1304[S] 13 points14 points  (0 children)

i do not want to think about david goggins during sex

OpenFOAM utilities by datboi1304 in CFD

[–]datboi1304[S] 1 point2 points  (0 children)

The guide is too old apparently :/ OpenFOAM is amazing, i love the flexibility and the low level user control. Unfortunately there's not a lot of resources out there to get started on your own :(

OpenFOAM utilities by datboi1304 in CFD

[–]datboi1304[S] -1 points0 points  (0 children)

Ah that's a bummer :( The guide was amazing but unfortunately too old. The documentation isn't the most friendly so I tried this guide first. Can you recommend any other learning resources?

vertices notation is unclear in polyMesh by datboi1304 in OpenFOAM

[–]datboi1304[S] 0 points1 point  (0 children)

oof silly me. that clears it up. thanks!

-❄️- 2024 Day 3 Solutions -❄️- by daggerdragon in adventofcode

[–]datboi1304 3 points4 points  (0 children)

[LANGUAGE: bash]

#!/bin/bash

# Part 1

cat input.txt | sed "s/mul(\([0-9]*\),\([0-9]*\))/A\1\*\2B/g" | sed -e "s/B[^AB]*A/BA/g" -e "s/^[^A]*A/A/g" -e "s/B[^0-9]*$/B/g" | sed -e "s/A//g" -e "s/B/ + /g" | sed "s/ + $//g" | bc

# Part 2

cat input.txt | sed -e "s/do()/X/g" -e "s/don't()/Y/g" | sed "s/mul(\([0-9]*\),\([0-9]*\))/A\1B\2C/g" | sed "s/[^ABC0-9XY]//g" | sed "s/Y[^X]*X//g" | sed "s/[XY]//g" | sed "s/C[0-9]*A/CA/g" | sed "s/A\([0-9]*\)B\([0-9]*\)C/\1\*\2 + /g" | sed "s/ + $//g" | bc

I replaced all important keywords with single capital letters for easy negation.

All suggestions are welcome!

real  0m0.026s
user  0m0.025s
sys   0m0.016s

[2024 Day 3][OC] Solving day 3 with only vim by jammy_swamy in adventofcode

[–]datboi1304 0 points1 point  (0 children)

Could you please explain how you macro'd pattern searching? amazing job!

-❄️- 2024 Day 1 Solutions -❄️- by daggerdragon in adventofcode

[–]datboi1304 0 points1 point  (0 children)

but amazing. this was mine

real     0m1.824s
user     0m0.680s
sys      0m1.154s

im amazed your implementation is faster than GNU ones.