HN user

deadsy

65 karma
Posts0
Comments44
View on HN
No posts found.

I wrote this (in golang) to satisfy my need to generate STLs for 3d printing.

https://github.com/deadsy/sdfx

In general I like to write code to define objects, but there are some situations where a graphical editing UI would be nice. ie- Curve and polygon design.

You can sort of imagine a hybrid approach where you could crack open a mini editor to design a curve and then use it to generate code (table of numbers) which you could then extrude/sweep/loft or whatever.

SDF = signed distance function. A function mapping a 2d/3d coordinate onto a scalar. The scalar is the shortest distance from that point to the surface of the object. (+ve outside, -ve inside)

CSG = constructive solid geometry: Take primitive 3d shapes and do unions, differences, intersections on them to build more complex shapes.

Fairly obviously the union of 2 sdf functions is going to be the minimum of those values. That pretty simple.

Intersections and differences are not much more complex....

See: https://iquilezles.org/www/articles/distfunctions/distfuncti...

for some quick examples.

Gears 6 years ago

I wrote a CAD package in Go that has a function for it.

https://github.com/deadsy/sdfx

  func InvoluteGear(
   numberTeeth int, // number of gear teeth
   gearModule float64, // pitch circle diameter / number of gear teeth
   pressureAngle float64, // gear pressure angle (radians)
   backlash float64, // backlash expressed as per-tooth distance at pitch circumference
   clearance float64, // additional root clearance
   ringWidth float64, // width of ring wall (from root circle)
   facets int, // number of facets for involute flank
  )

You sequence the motor, get a pick up from the light sensor and then turn it into a note trigger. It'd be simpler to sequence an array rather than a motor and generate a trigger based on array content.

But sure. Art. It's a piece of kinetic sculpture....

Right - they statically link which means that you typically don't have to worry about shared object dependencies when moving the binary around. You just have big binaries. If you use cgo (integration with C-code and C based libraries) then you are back to *.so versioning problems.

Premise: It's more important to be productive than to have fast code. Conclusion: Use Python. Is the premise true? For many cases- yes, but it depends. If you are running an application on the cloud and your metric is $/user/year and you have many users then saving some compute resources for each user gets attractive and you don't want to just throw another VM at it.

Is the conclusion true? Garbage collection gives big productivity gains. Other languages have GC. It's not nice to see your Python code die after a few days because you messed up the type passed to a function. Other languages fix that at compile time. Multicore is now. Other languages are built with better multicore awareness.

As an engineer hiring engineers, if a candidate gives me a guthub url then I'm going to take a look. There are too many people coming through the door who are marginal coders, so if I can get a sense of what they do for something other than a white board problem then that's a good thing.

Even something seemingly simple such as saying "is point C to the left or right of the line A->B" is very hard in floating point.

Is it? ie - construct a normal and take a dot product. That'll work the vast majority of the time. Near the line you'll start running into the FP precision limits. With 64 (...or even 32) bit floats that sort of distance is likely way smaller than anything that represents a practical distance, so just call it and say you are on the line. Of late I've been messing about with problems of this nature and I can't say it's been all that difficult. https://github.com/deadsy/sdfx

Gear Generator 11 years ago

There are other tooth forms that also satisfy the fundamental law of gearing (constant ratio of angular velocity). E.g. cycloid gearing used typically in mechanical clocks. The involute is popular because its easy to manufacture. It can be auto-generated on a gear hobbing machine- probably less important now with CNC machines, but very important in a pre-digital machine era. The involute is also less sensitive to gear center to center spacing.

Paternoster 11 years ago

When I was in Stuttgart I made a point of visiting the one they have in the Rathaus. It's an interesting mechanical design, but definitely assumes some personal responsibility on the part of the user. Keep your hands to yourself as you go around the top and bottom...

I'd been curious about this one since it was released in the early 80's. I wrote an emulation in python to satisfy my curiosity. (https://github.com/deadsy/py_z80) My general conclusion was that the hardware wasn't good enough (monochrome competing with the ZX Spectrum's color) and that Forth didn't offer enough advantages over BASIC to warrant significant usage. It's an interesting design though, and it's good to see how they built their Forth system in an 8K ROM.

The Tensilica guys took this thing an extra step. ie- profile real code to find out what constants are most typically used, enumerate the top n constants, encode the constant with 0..n-1 in the immediate instruction - the immediate value is a hardware based lookup. You can still do arbitrary immediates with longer instructions but you can apparently get some nice code size reductions using this technique.

On the off chance that you are not just trolling...

You seem to have this retrospective view of technology creation where anything that didn't pan out or doesn't connect to current technology was therefore a waste of time and effort. The problem is that at the present nobody knows what's going to work out- you just have to try. Some ideas will work, some will not, some ideas will be lost and then re-discovered. It's a messy process. I'm sure there are robotics researchers who are wasting their time in dead end technologies. But I don't know which ones they are, and neither do you. I have opinions, but I'm not prescient.

I'm not sure what the big deal is. Individuals have been smithing guns since their invention. Hillbillies in the Ozarks could make rifled barrels. People with a manual or cnc mill in their garage are making ar15 lower receivers from billet aluminum. The 3d printing technique takes a lot of the skill out of it, but at the moment all you are getting is a low quality plastic gun. As a practical matter I don't think the swapping of gun part cad files is a significant vector for the creation of guns that are used to do bad things.

Atheism is a disbelief in god(s) and doesn't say anything about life after death. To the extent that an atheist might take an evidence based approach to belief they may also disbelieve in life after death. Given what we know about consciousness and brain function it's not unreasonable to say that we know there is no life after death because there is no known mechanism for it. ie - no brain, no electrical activity, no sense of self. That the belief in life after death remains so prevalent indicates a prodigious ability for wishful thinking.

Not an expert, but I'd be worried about those hull windows around the bow getting broken as you plowed through waves. Maybe the boat is more of an Apple III than an iPhone.

... and often the specialised hw doesn't go far enough. ie- i2c and spi hw that doesn't have enough buffering to be left on its own. Either we babysit the interface or we can leave it to do its own thing until we get an interrupt for completion. Do a halfway job on the hw and we revert to the babysit case. Not bitter, just ranting.

Kill Math 14 years ago

Brett Victor is very accomplished. I'm pretty sure he understands math. Personally speaking if Brett Victor had a different opinion about something than me than I'd pay careful attention, because I'm probably missing something.

>given the privileges corporations receive (like limited liability)

Corporations don't receive limited liability. The owners of a corporation have limited liability.

A patent is a finite time period monopoly on the use/practice/sale of an invention. To innovate means to introduce something new. The two concepts aren't the same. E.g. You can patent something economically useless, you can patent something and not build it. As a practical matter its not clear to me if you can or should require patents to be linked to innovations.

Where in the claims did you see adaptive encoding? It seems to be describing any sort of load balancing of media servers based on network throughput to the client. Do bit-torrent clients do that? Or do they just throttle their own response to a peer based on the p2p throughput? In any case claim 1 is overly broad and is obvious. I hope someone digs up prior art and gets it invalidated.

Filing a patent doesn't mean anything at all. If the patent issues AND the claims read against your practice AND the filing date predates your practice of the invention then he could reasonably claim infringement. Sending an email to someone simply because you have filed is amateurish. The guy sounds like an idiot.

>but this article isn't factually based

There's more than one article and there's lot's of facts in them.

>If Prop 13 is such a hindrance why is California in the top 5 highest taxing states across the board?

I don't understand your question or the point you are trying to make.

>So California's problems are not because of direct democracy.

I'm sure it can be argued that CAs problems are not the initiative process, but you haven't begun to do that.

>they are (by their own admission) a left-leaning publication

Source? "free trade, free markets" - doesn't sound left leaning. They claim to be centrist. Unless there is some other proof that they are in cahoots with CA democrats it seems pretty unlikely that they ran the articles to help them.