!********************************************** BASIC GEOMETRY MODULE calwsurf( REF hull_id >"@t16 Select hull surface !"); !* Calculation of wetted surface. !* !* Calculates and stores: !* !* not up-to-date! See file "Datatypes". !* HULLAREA(2) = Wetted surface !* !* See file "Datatypes" for further information. !* !* (C)Microform AB, J.Kjellander !* Stephan Helma !* !********************************************** !FIXME: This module calculates the whole(!) surface ! of the hull and not just the wetted area. INT status; FLOAT k(2); REF stern_id; STRING s*132; BEGINMODULE !* !***Global ID of hull surface. !* hull_id:=global_ref(hull_id,9); !* !***Stern surface ID. !* s:=rstr(hull_id); stern_id:=rval(s+"#50"); !* !***Hull + stern area. !* psh_pmt("Calculating hull + stern area !"); k(1):=surface_area(hull_id); k(2):=0; ! surface_area(stern_id); status:=deldat_gm("HULLAREA"); status:=putdat_gm("HULLAREA",2,k); pop_pmt(); ENDMODULE !*****************************************************