The research belongs to the field of Maths teaching, specifically to the learning of trigonometry at E.S.O. and Bachillerato. The main objective of this investigation is to make a diagnosis at different moments of the learning process of trigonometry to obtain information to improve the aforementioned process in the compulsory education (E.S.O.), Bachillerato and the transition from E.S.O. to Bachillerato. In order to achieve this objective, the following specific objectives have been formulated: typify the errors and difficulties in concepts, procedures and competences, problem solving which students encounter before and after the teaching-learning process of trigonometry in 4º E.S.O. and 1º de Bachillerato, analyse the errors and difficulties in the learning of trigonometry in the transition from E.S.O. to Bachillerato and identify the obstacles regarding trigonometry problem solving in these courses. The thesis employs a mixed methodology with the usage of quantitative and qualitative data. The data have been obtained from four questionnaires which have allowed to analyse the trigonometry learning process before and after the topic has been dealt with in 4º E.S.O. and 1º de Bachillerato in two schools: a public school and a state school. The sample consists of 165 students who have been monitored for two years. The errors made by the students have been analysed and an interpretation of the possible reasons has been made. This interpretation completes the main corpus data, constituted by the four questionnaires mentioned before, interviews made to the teachers teaching the trigonometry lessons so as to know the differences between the Maths taught in the two levels and the approach on trigonometry. This analysis of successes and errors has allowed us to indentify the differences between the results obtained in the questionnaires. Therefore, a comparative between the initial and the final tests has been made in 4º E.S.O. and 1º Bachillerato. This analysis allows us to draw conclusions about the knowledge of trigonometry had by E.S.O. and Bachillerato students and what happens in the transition from 4º E.S.O. to Bachillerato. The results obtained in the investigation confirm that most of the errors made by the students at 4º ESO and Bachillerato and the difficulties presented when working with the trigonometry topic are a consequence of not having assimilated the previous knowledge needed to deal successfully with this unit: measurement aspects, geometry, calculus and algebra. Some mistakes are due to the fact that students only interiorise the calculations, memorise situations and do not assimilate the mathematical concepts involved. It has been confirmed that some of the mistakes have become an obstacle at geometry and trigonometry (similarity, Pythagorean theorem, ratios and trygonometric formulas), at calculus and algebra (numerical calculations with and without calculator, simplification of mathematical expressions, equation solving) and at problem solving (diagram elaboration in the trigonometry problems). Finally, a series of recommendations that should be taken into account before initiating the trigonometry topic, (regarding timing, organizational sequence, topic building, typology of activities and resources), during its teaching (regarding classroom management and adaptation of the contents to the students’ necessities) and after dealing with it (regarding evaluation) is presented.