Re: Output x/y position of a knuckle line at a given station
› DELFTship forum › Hull modeling › Output x/y position of a knuckle line at a given station › Re: Output x/y position of a knuckle line at a given station
Dear Bryan,
are you familiar with MSEXCEL?
Then you could try this:
Put stations (View>Intersections), click on the left most icon, where you want to know the knuckle points. In “Display” switch on only the stations. Then File>Export>DXF 2D Polylines, MARK Create individual files.
Use edit to read and understand what is written in these files.
The DXFformat is readable for humans even if it is very lengthy…
Write a short Basic, Pascal, Java or whatever you like program to convert the DXFFile into a *.TXT having only the coordinate information in x,y,z always in one line.
Import this into an EXCELtable. So f.i. you will have xvalues in Col A, yvalues in column B, zvalues in column C.
In Column E calculate the successive differences of column A. I.e. in E1 you write
=A2A1, in E2 you write =A3A2 and FILL the column E downward as longs as there a numbers in columns A,B,C. Then copy Column E to F and to G.
What you have done then is to calculate the tangent vector to your station.
Knuckle point have a JUMP in the tangent, haven’t they?
Now do a similar procedure in column I: I1 contains =E2E1, I2 contains =E3E2;
Simply copy column E to I, J and K.
Now you have sort of the second derivative of A,B,C in columns I,J,K.
In column M write the following: In M1 =sqrt(I1^2+J^+2+K1^2). Fill downwards to the end of all numbers. This is the absolute value of the curvature of your station, and it must be big at knuckles and quite small in between.
So column M gives a MARK every where in A,B,C is a knuckle point.
Actually you can also write a second Basic, Pascal or Java program reading in the *.TXT file line by line and forgetting nearly collinear points writing only knuckle points to a new *.txt file: Thats what you would prefer, I guess.
Try it and don’t hesitate to ask for more help if necessary.
Kind regards
michaelf
Your account
Recent Topics

CAD Interface
by Peter Mitchell
2 days, 5 hours ago

Deck and Bulkhead layers changing Hydrostatics ?
by orfoz
1 week, 5 days ago

Waterlines problem
by RaulPB
1 week, 6 days ago

how to avoid plate development breaking apart
by Flash
1 week, 6 days ago

Download Problems
by William Boebert
1 month, 2 weeks ago

Developable surface (wrong orientation)
by Hrvoje
2 months, 1 week ago

Modelling a flat bottom chine tug hull (WWII TID)
by Paul
2 months, 1 week ago

Need OSV, AHTS,PSV Vessel hull bodylines plans
by jacksparrow1912
2 months, 2 weeks ago

Can’t figure out how to model the back
by Tidexon
2 months, 3 weeks ago

Critical Program Error
by Allan Russell
2 months, 3 weeks ago